diff --git a/src/drivers/Quartz/Fl_Quartz_Graphics_Driver.H b/src/drivers/Quartz/Fl_Quartz_Graphics_Driver.H index 0afc7369e..803151ae5 100644 --- a/src/drivers/Quartz/Fl_Quartz_Graphics_Driver.H +++ b/src/drivers/Quartz/Fl_Quartz_Graphics_Driver.H @@ -98,6 +98,7 @@ protected: int not_clipped(int x, int y, int w, int h) FL_OVERRIDE; void restore_clip() FL_OVERRIDE; void end_points() FL_OVERRIDE; + void end_loop() FL_OVERRIDE; void end_line() FL_OVERRIDE; void end_polygon() FL_OVERRIDE; void end_complex_polygon() FL_OVERRIDE; diff --git a/src/drivers/Quartz/Fl_Quartz_Graphics_Driver_vertex.cxx b/src/drivers/Quartz/Fl_Quartz_Graphics_Driver_vertex.cxx index 16c6c6c29..4629c1c5f 100644 --- a/src/drivers/Quartz/Fl_Quartz_Graphics_Driver_vertex.cxx +++ b/src/drivers/Quartz/Fl_Quartz_Graphics_Driver_vertex.cxx @@ -33,6 +33,13 @@ void Fl_Quartz_Graphics_Driver::end_points() { } } +void Fl_Quartz_Graphics_Driver::end_loop() { + CGContextSaveGState(gc_); + CGContextSetLineCap(gc_, kCGLineCapSquare); + Fl_Graphics_Driver::end_loop(); + CGContextRestoreGState(gc_); +} + void Fl_Quartz_Graphics_Driver::end_line() { if (n < 2) { end_points();