Skip to content

Commit

Permalink
[GTK][HiDpi] Code cleanup for removal of non-cairo scale path.
Browse files Browse the repository at this point in the history
Fixes #1300
  • Loading branch information
deepika-u committed Sep 19, 2024
1 parent f8cdb6a commit bb37696
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -670,7 +670,7 @@ public void draw(GC gc, int x, int y, int selectionStart, int selectionEnd, Colo
if (ascentInPoints != -1 && descentInPoints != -1) {
height = Math.max (height, ascentInPoints + descentInPoints);
}
height += getSpacingInPixels();
height += getSpacing();
int width = (flags & SWT.FULL_SELECTION) != 0 ? 0x7fff : height / 3;
Cairo.cairo_rectangle(cairo, lineX, lineY, width, height);
Cairo.cairo_fill(cairo);
Expand Down Expand Up @@ -701,7 +701,7 @@ public void draw(GC gc, int x, int y, int selectionStart, int selectionEnd, Colo
selectionEnd = translateOffset(selectionEnd);
if (selectionForeground == null) selectionForeground = device.getSystemColor(SWT.COLOR_LIST_SELECTION_TEXT);
if (selectionBackground == null) selectionBackground = device.getSystemColor(SWT.COLOR_LIST_SELECTION);
int yExtent = extent ? getSpacingInPixels() : 0;
int yExtent = extent ? getSpacing() : 0;
boolean fullSelection = selectionStart == 0 && selectionEnd == length - 1;
if (fullSelection) {
long ptr = OS.pango_layout_get_text(layout);
Expand Down

0 comments on commit bb37696

Please sign in to comment.