Project: SWT
Bug 12178 StyledText - move StyledTextRenderer#bidiTextWidth to DisplayRenderer
Reported: 2002-03-22 18:00:37 | Status: resolved fixed

build 20020321 bidiTextWidth is used by the StyledTextRenderer to calculate the line start location on bidi platforms. This is important for display rendering because of the bidi caret inset. For printing however there is no need for a bidi caret inset. The current method should be moved to DisplayRenderer, made abstract in StyledTextRenderer and just return 0 in the PrintRenderer. StyledTextRenderer#getLastCaretDirection could then also be moved to PrintRenderer and removed completely in StyledTextRenderer.

Files changed in fix:
bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/DisplayRenderer.java bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/PrintRenderer.java bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/StyledText.java bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/StyledTextRenderer.java