Revision: 16614
          http://sourceforge.net/p/skim-app/code/16614
Author:   hofman
Date:     2026-10-05 17:09:08 +0000 (Mon, 05 Oct 2026)
Log Message:
-----------
set controlPoint to start point of curve after break as the SkimNotesPath would 
do, no need to doule point at start of curve

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

Modified: trunk/SKPDFView.m
===================================================================
--- trunk/SKPDFView.m   2026-10-05 16:27:59 UTC (rev 16613)
+++ trunk/SKPDFView.m   2026-10-05 17:09:08 UTC (rev 16614)
@@ -4309,7 +4309,7 @@
             if (bezierPath == nil) {
                 bezierPath = [NSBezierPath bezierPath];
                 [bezierPath moveToPoint:point];
-            } else if (wantsBreak && NO == NSEqualPoints(point, [bezierPath 
associatedPointForElementAtIndex:[bezierPath elementCount] - 2])) {
+            } else if (wantsBreak && [bezierPath elementCount] > 1 && NO == 
NSEqualPoints(point, [bezierPath associatedPointForElementAtIndex:[bezierPath 
elementCount] - 2])) {
                 [PDFAnnotation addPoint:point toSkimNotesPath:bezierPath];
             }
             
@@ -4318,11 +4318,8 @@
             if (isOption && wantsBreak == NO) {
                 NSInteger eltCount = [bezierPath elementCount];
                 NSPoint points[3] = {point, point, point};
-                if (NSCurveToBezierPathElement == [bezierPath 
elementAtIndex:eltCount - 1]) {
+                if (NSCurveToBezierPathElement == [bezierPath 
elementAtIndex:eltCount - 1])
                     points[0] = [bezierPath 
associatedPointForElementAtIndex:eltCount - 2];
-                    points[0].x += ( point.x - points[0].x ) / 3.0;
-                    points[0].y += ( point.y - points[0].y ) / 3.0;
-                }
                 [bezierPath setAssociatedPoints:points atIndex:eltCount - 1];
             } else {
                 [PDFAnnotation addPoint:point toSkimNotesPath:bezierPath];

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