Revision: 15586
http://sourceforge.net/p/skim-app/code/15586
Author: hofman
Date: 2025-07-02 15:29:16 +0000 (Wed, 02 Jul 2025)
Log Message:
-----------
separately add new freehand note or joined freehand note
Modified Paths:
--------------
trunk/SKPDFView.m
Modified: trunk/SKPDFView.m
===================================================================
--- trunk/SKPDFView.m 2025-07-02 14:21:22 UTC (rev 15585)
+++ trunk/SKPDFView.m 2025-07-02 15:29:16 UTC (rev 15586)
@@ -4359,25 +4359,17 @@
[NSEvent setMouseCoalescingEnabled:wasMouseCoalescingEnabled];
if (bezierPath) {
- NSMutableArray *paths = [[NSMutableArray alloc] init];
- if (currentAnnotation)
- [paths addObjectsFromArray:[currentAnnotation pagePaths]];
- [paths addObject:bezierPath];
-
- PDFAnnotation *annotation = [PDFAnnotation newSkimNoteWithPaths:paths];
if (currentAnnotation) {
+ PDFAnnotation *annotation = [PDFAnnotation
newSkimNoteWithPaths:[[currentAnnotation pagePaths]
arrayByAddingObject:bezierPath]];
[annotation setColor:[currentAnnotation color]];
[annotation setBorder:[currentAnnotation border]];
[annotation setString:[currentAnnotation string]];
+ [self removeAnnotation:currentAnnotation];
+ [self addAnnotation:annotation toPage:page select:YES];
+ } else {
+ PDFAnnotation *annotation = [PDFAnnotation
newSkimNoteWithPaths:@[bezierPath]];
+ [self addAnnotation:annotation toPage:page select:([theEvent
modifierFlags] & (NSEventModifierFlagShift | NSEventModifierFlagCapsLock)) !=
0];
}
- [self addAnnotation:annotation toPage:page select:NO];
-
- if (currentAnnotation) {
- [self removeCurrentAnnotation:nil];
- [self setCurrentAnnotation:annotation];
- } else if (([theEvent modifierFlags] & (NSEventModifierFlagShift |
NSEventModifierFlagCapsLock))) {
- [self setCurrentAnnotation:annotation];
- }
} else if (([theEvent modifierFlags] & NSEventModifierFlagCapsLock)) {
[self setCurrentAnnotation:nil];
}
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