Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,9 @@ public static void main (String [] args) {
return null;
}
};
final ImageGcDrawer imageGcDrawer = gc -> {
gc.drawRectangle(1, 1, 18, 18);
gc.drawLine(3, 3, 17, 17);
final ImageGcDrawer imageGcDrawer = (gc, width, height) -> {
gc.drawRectangle(1, 1, width - 2, height - 2);
gc.drawLine(3, 3, width - 3, height - 3);
};

final Display display = new Display ();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,11 +64,11 @@ public static void main (String [] args) {

final Display display = new Display ();

final ImageGcDrawer imageGcDrawer = gc -> {
final ImageGcDrawer imageGcDrawer = (gc, width, height) -> {
gc.setBackground(display.getSystemColor(SWT.COLOR_RED));
gc.fillRectangle(0, 0, 16, 16);
gc.fillRectangle(0, 0, width, height);
gc.setForeground(display.getSystemColor(SWT.COLOR_YELLOW));
gc.drawRectangle(4, 4, 8, 8);
gc.drawRectangle(4, 4, width - 8, height - 8);
};

final Shell shell = new Shell (display);
Expand Down
Loading