Community
Participate
Working Groups
Testcase: - turn StyledText widget's word wrap on in a simple editor - open a file with 30 lines (for example), where two of the line are very long - line number ruler shows 1 - 30, but text widget has 32 lines
SWT.WRAP is currently not supported. See also bug 47280
Even SWT.WRAP is not going to be supported, could be fixed with: --- LineNumberRulerColumn.java Fri Oct 20 07:25:18 2006 +++ LineNumberRulerColumn_Fixed.java Tue Feb 27 21:25:30 2007 @@ -659,7 +657,9 @@ if (widgetLine == -1) continue; - int lineHeight= fCachedTextWidget.getLineHeight(fCachedTextWidget.getOffsetAtLine(widgetLine)); + // FIXED: For wrapped text widgets + int lineHeight= fCachedTextWidget.getLinePixel(widgetLine+1) - fCachedTextWidget.getLinePixel(widgetLine);
In our case this issue causes scrolling problems in an editor using the StyledText widget with SWT.WRAP. If the text is wrapped and you try to get to the next row by pressing "arrow down" (when the cursor is at the beginning of the line) this does not work. There are also some drawing problems which seem to occur when rich text is wrapped and such wrapped lines are deleted. To reproduce this issue, paste a text that exceeds the total height of the widget and has long lines that are wrapped in the editor. If some lines are deleted then and you scroll down using the scroll bar you get some strange display errors like in the attached screenshot.
Created attachment 83528 [details] Drawing problems using SWT.WRAP
Please report the drawing problems directly to SWT.
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. As such, we're closing this bug. If you have further information on the current state of the bug, please add it and reopen this bug. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant. -- The automated Eclipse Genie.