Revision: 16810
          http://sourceforge.net/p/skim-app/code/16810
Author:   hofman
Date:     2026-11-25 17:12:52 +0000 (Wed, 25 Nov 2026)
Log Message:
-----------
handle nil border

Modified Paths:
--------------
    trunk/PDFAnnotation_SKExtensions.m

Modified: trunk/PDFAnnotation_SKExtensions.m
===================================================================
--- trunk/PDFAnnotation_SKExtensions.m  2026-11-25 17:11:34 UTC (rev 16809)
+++ trunk/PDFAnnotation_SKExtensions.m  2026-11-25 17:12:52 UTC (rev 16810)
@@ -902,7 +902,7 @@
     CGContextSaveGState(context);
     CGContextSetAlpha(context, [[self color] alphaComponent]);
     CGContextBeginTransparencyLayerWithRect(context, rect, NULL);
-    CGContextSetLineWidth(context, border ? [border lineWidth] : 0.0);
+    CGContextSetLineWidth(context, fmax(1.0, border ? [border lineWidth] : 
0.0));
     if ([border style] == kPDFBorderStyleDashed) {
         NSArray *dashPattern = [border dashPattern];
         NSUInteger i, count = [dashPattern count];
@@ -950,7 +950,7 @@
             NSBezierPath *path = [NSBezierPath bezierPath];
             for (NSBezierPath *aPath in [self paths])
                 [path appendBezierPath:aPath];
-            [path setLineWidth:fmax(1.0, [border lineWidth])];
+            [path setLineWidth:fmax(1.0, border ? [border lineWidth] : 1.0)];
             [path setLineJoinStyle:NSRoundLineJoinStyle];
             if ([border style] == kPDFBorderStyleDashed) {
                 [path setDashPattern:[border dashPattern]];

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.



_______________________________________________
Skim-app-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/skim-app-commit

Reply via email to