diff options
author | fvogel <fvogelnew1@free.fr> | 2017-09-16 08:18:40 (GMT) |
---|---|---|
committer | fvogel <fvogelnew1@free.fr> | 2017-09-16 08:18:40 (GMT) |
commit | d1d338264e13c42787531f48244b432ae55b6fb7 (patch) | |
tree | 674899afb310e42de3daaa5561ecbef4fa2b7a07 /macosx/tkMacOSXDraw.c | |
parent | c0a0d15a19ac54d03dfd622ff61838bb7dccc8fa (diff) | |
parent | da54602493ccf28707320190ca559915a08e3003 (diff) | |
download | tk-bug_d9fdfa435d.zip tk-bug_d9fdfa435d.tar.gz tk-bug_d9fdfa435d.tar.bz2 |
merge core-8-6-branchbug_d9fdfa435d
Diffstat (limited to 'macosx/tkMacOSXDraw.c')
-rw-r--r-- | macosx/tkMacOSXDraw.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/macosx/tkMacOSXDraw.c b/macosx/tkMacOSXDraw.c index 5ca8bfe..d1e67dc 100644 --- a/macosx/tkMacOSXDraw.c +++ b/macosx/tkMacOSXDraw.c @@ -858,6 +858,16 @@ XDrawLines( CGContextAddLineToPoint(dc.context, prevx, prevy); } } + /* + * In the case of closed polylines, the first and last points + * are the same. We want miter or bevel join be rendered also + * at this point, this needs telling CoreGraphics that the + * path is closed. + */ + if ((points[0].x == points[npoints-1].x) && + (points[0].y == points[npoints-1].y)) { + CGContextClosePath(dc.context); + } CGContextStrokePath(dc.context); } TkMacOSXRestoreDrawingContext(&dc); |