Revision: 14380
          http://sourceforge.net/p/skim-app/code/14380
Author:   hofman
Date:     2024-07-15 14:09:50 +0000 (Mon, 15 Jul 2024)
Log Message:
-----------
validate auto size note action for circle and square only when there is a text 
selection

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

Modified: trunk/SKMainWindowController_UI.m
===================================================================
--- trunk/SKMainWindowController_UI.m   2024-07-15 09:32:59 UTC (rev 14379)
+++ trunk/SKMainWindowController_UI.m   2024-07-15 14:09:50 UTC (rev 14380)
@@ -1736,7 +1736,7 @@
         return [self interactionMode] != SKPresentationMode && [self 
hasOverview] == NO && [annotation isSkimNote] && [annotation isEditable];
     } else if (action == @selector(autoSizeNote:)) {
         PDFAnnotation *annotation = [pdfView currentAnnotation];
-        return [self interactionMode] != SKPresentationMode && [self 
hasOverview] == NO && [annotation isSkimNote] && ([annotation isResizable] && 
[annotation isLine] == NO);
+        return [self interactionMode] != SKPresentationMode && [self 
hasOverview] == NO && [annotation isSkimNote] && ([annotation isText] || 
(([[annotation type] isEqualToString:SKNCircleString] || [[annotation type] 
isEqualToString:SKNSquareString]) && [[pdfView currentSelection] 
hasCharacters]));
     } else if (action == @selector(alignLeft:) || action == 
@selector(alignRight:) || action == @selector(alignCenter:)) {
         PDFAnnotation *annotation = [pdfView currentAnnotation];
         return [self interactionMode] != SKPresentationMode && [self 
hasOverview] == NO && [annotation isSkimNote] && [annotation isEditable] && 
[annotation isText];

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