Pārlūkot izejas kodu

【综合】FreeText注释填充色为clear颜色时优化

tangchao 8 mēneši atpakaļ
vecāks
revīzija
e4cb2b0f5c

+ 7 - 0
PDF Office/PDF Master/Class/PDFWindowController/PDFListView/CPDFKitExtensions/CPDFAnnotationExtensions/CPDFAnnotationModel.m

@@ -325,6 +325,13 @@
                 [(CSelfSignAnnotation *)annotation setLineColor:color?:[NSColor clearColor]];
             } else if ([annotation isKindOfClass:[CPDFRedactAnnotation class]]) {
                 [(CPDFRedactAnnotation *)annotation setBorderColor:tColor?:[NSColor blackColor]];
+            } else if ([annotation isKindOfClass:[CPDFFreeTextAnnotation class]]) {
+                if ([color isEqual:NSColor.clearColor]) {
+                    annotation.color = nil;
+                } else {
+                    annotation.color = color;
+                }
+                
             } else {
                 annotation.color = color;
             }