Skip to content

Commit 1042a13

Browse files
committed
[GTK] Remove temporary workaround for LineNumberRulerColumn #2740
The underlying issue for the required workaround on Linux/GTK was located in the GTK implementation of GC#copyArea() when source and target area of a copy operation are overlapping. Since that issue has been fixed, this change removes the temporary workaround in LineNumberRulerColumn. Fixes #2740
1 parent ec4235b commit 1042a13

File tree

1 file changed

+6
-13
lines changed

1 file changed

+6
-13
lines changed

bundles/org.eclipse.jface.text/src/org/eclipse/jface/text/source/LineNumberRulerColumn.java

+6-13
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,6 @@
4242
import org.eclipse.swt.widgets.Control;
4343
import org.eclipse.swt.widgets.Display;
4444

45-
import org.eclipse.core.runtime.Platform.OS;
46-
4745
import org.eclipse.jface.text.BadLocationException;
4846
import org.eclipse.jface.text.IDocument;
4947
import org.eclipse.jface.text.IRegion;
@@ -697,17 +695,12 @@ private void doubleBufferPaint(GC dest) {
697695
}
698696

699697
private void newFullBufferImage(ILineRange visibleLines, Point size) {
700-
if (OS.isLinux()) {
701-
fBuffer= new Image(fCanvas.getDisplay(), size.x, size.y);
702-
doPaint(visibleLines, size);
703-
} else {
704-
ImageGcDrawer imageGcDrawer= (gc, imageWidth, imageHeight) -> {
705-
// We redraw everything; paint directly into the buffer
706-
initializeGC(gc, 0, 0, imageWidth, imageHeight);
707-
doPaint(gc, visibleLines);
708-
};
709-
fBuffer= new Image(fCanvas.getDisplay(), imageGcDrawer, size.x, size.y);
710-
}
698+
ImageGcDrawer imageGcDrawer= (gc, imageWidth, imageHeight) -> {
699+
// We redraw everything; paint directly into the buffer
700+
initializeGC(gc, 0, 0, imageWidth, imageHeight);
701+
doPaint(gc, visibleLines);
702+
};
703+
fBuffer= new Image(fCanvas.getDisplay(), imageGcDrawer, size.x, size.y);
711704
}
712705

713706
private void doPaint(ILineRange visibleLines, Point size) {

0 commit comments

Comments
 (0)