summaryrefslogtreecommitdiff
path: root/src/drivers/Xlib/Fl_Xlib_Graphics_Driver_rect.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'src/drivers/Xlib/Fl_Xlib_Graphics_Driver_rect.cxx')
-rw-r--r--src/drivers/Xlib/Fl_Xlib_Graphics_Driver_rect.cxx3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/drivers/Xlib/Fl_Xlib_Graphics_Driver_rect.cxx b/src/drivers/Xlib/Fl_Xlib_Graphics_Driver_rect.cxx
index 689f0eccf..25cb6a285 100644
--- a/src/drivers/Xlib/Fl_Xlib_Graphics_Driver_rect.cxx
+++ b/src/drivers/Xlib/Fl_Xlib_Graphics_Driver_rect.cxx
@@ -228,7 +228,10 @@ void Fl_Xlib_Graphics_Driver::focus_rect(int x, int y, int w, int h) {
}
void Fl_Xlib_Graphics_Driver::rect_unscaled(int x, int y, int w, int h) {
+ void *old = NULL;
+ if (line_width_ == 0) old = change_pen_width(1); // #156, #1052
XDrawRectangle(fl_display, fl_window, gc_, x, y, w, h);
+ if (old) reset_pen_width(old);
}
void Fl_Xlib_Graphics_Driver::rectf_unscaled(int x, int y, int w, int h) {