diff options
author | Felipe Heidrich <fheidric> | 2003-08-12 16:16:09 +0000 |
---|---|---|
committer | Felipe Heidrich <fheidric> | 2003-08-12 16:16:09 +0000 |
commit | 3bde732569054b4c1e566314a1b17223a9f456f9 (patch) | |
tree | 968ebe9e9a41d128a2b430c315f80d82aa0f48bd | |
parent | cde727956f65afa6e5b3ae98db69f599038e7ec2 (diff) | |
download | eclipse.platform.swt-3bde732569054b4c1e566314a1b17223a9f456f9.tar.gz eclipse.platform.swt-3bde732569054b4c1e566314a1b17223a9f456f9.tar.xz eclipse.platform.swt-3bde732569054b4c1e566314a1b17223a9f456f9.zip |
*** empty log message ***
-rw-r--r-- | bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/graphics/GC.java | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/graphics/GC.java b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/graphics/GC.java index bd2d695466..da04471a7b 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/graphics/GC.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/graphics/GC.java @@ -1758,10 +1758,12 @@ public void setForeground(Color color) { */ public void setLineStyle(int lineStyle) { if (handle == 0) SWT.error(SWT.ERROR_GRAPHIC_DISPOSED); + GdkGCValues values = new GdkGCValues(); + OS.gdk_gc_get_values(handle, values); switch (lineStyle) { case SWT.LINE_SOLID: - this.data.lineStyle = lineStyle; - OS.gdk_gc_set_line_attributes(handle, 0, OS.GDK_LINE_SOLID, OS.GDK_CAP_BUTT, OS.GDK_JOIN_MITER); + data.lineStyle = lineStyle; + OS.gdk_gc_set_line_attributes(handle, values.line_width, OS.GDK_LINE_SOLID, OS.GDK_CAP_BUTT, OS.GDK_JOIN_MITER); return; case SWT.LINE_DASH: OS.gdk_gc_set_dashes(handle, 0, new byte[] {6, 2}, 2); @@ -1779,7 +1781,7 @@ public void setLineStyle(int lineStyle) { SWT.error(SWT.ERROR_INVALID_ARGUMENT); } data.lineStyle = lineStyle; - OS.gdk_gc_set_line_attributes(handle, 0, OS.GDK_LINE_ON_OFF_DASH, OS.GDK_CAP_BUTT, OS.GDK_JOIN_MITER); + OS.gdk_gc_set_line_attributes(handle, values.line_width, OS.GDK_LINE_ON_OFF_DASH, OS.GDK_CAP_BUTT, OS.GDK_JOIN_MITER); } /** |