Browse Source

【2025】【Edit】水印模块补充

niehaoyu 4 months ago
parent
commit
67d83ee1a0

+ 12 - 0
PDF Office/PDF Master/KMClass/KMPDFViewController/PDFImages.xcassets/Watermark/edit_ocapity.imageset/Contents.json

@@ -0,0 +1,12 @@
+{
+  "images" : [
+    {
+      "filename" : "edit_ocapity.pdf",
+      "idiom" : "universal"
+    }
+  ],
+  "info" : {
+    "author" : "xcode",
+    "version" : 1
+  }
+}

+ 91 - 0
PDF Office/PDF Master/KMClass/KMPDFViewController/PDFImages.xcassets/Watermark/edit_ocapity.imageset/edit_ocapity.pdf

@@ -0,0 +1,91 @@
+%PDF-1.7
+
+1 0 obj
+  << >>
+endobj
+
+2 0 obj
+  << /Length 3 0 R >>
+stream
+/DeviceRGB CS
+/DeviceRGB cs
+q
+1.000000 0.000000 -0.000000 1.000000 1.000000 1.000000 cm
+0.250980 0.274510 0.325490 scn
+1.500000 1.499939 m
+1.500000 12.499939 l
+12.500000 12.499939 l
+12.500000 1.499939 l
+1.500000 1.499939 l
+h
+0.000000 12.999939 m
+0.000000 13.552223 0.447715 13.999939 1.000000 13.999939 c
+13.000000 13.999939 l
+13.552284 13.999939 14.000000 13.552223 14.000000 12.999939 c
+14.000000 0.999939 l
+14.000000 0.447655 13.552284 -0.000061 13.000000 -0.000061 c
+1.000000 -0.000061 l
+0.447716 -0.000061 0.000000 0.447655 0.000000 0.999939 c
+0.000000 12.999939 l
+h
+11.000000 10.999939 m
+7.000000 10.999939 l
+7.000000 6.999939 l
+3.000000 6.999939 l
+3.000000 2.999939 l
+7.000000 2.999939 l
+7.000000 6.999939 l
+11.000000 6.999939 l
+11.000000 10.999939 l
+h
+f*
+n
+Q
+
+endstream
+endobj
+
+3 0 obj
+  767
+endobj
+
+4 0 obj
+  << /Annots []
+     /Type /Page
+     /MediaBox [ 0.000000 0.000000 16.000000 15.999939 ]
+     /Resources 1 0 R
+     /Contents 2 0 R
+     /Parent 5 0 R
+  >>
+endobj
+
+5 0 obj
+  << /Kids [ 4 0 R ]
+     /Count 1
+     /Type /Pages
+  >>
+endobj
+
+6 0 obj
+  << /Pages 5 0 R
+     /Type /Catalog
+  >>
+endobj
+
+xref
+0 7
+0000000000 65535 f
+0000000010 00000 n
+0000000034 00000 n
+0000000857 00000 n
+0000000879 00000 n
+0000001052 00000 n
+0000001126 00000 n
+trailer
+<< /ID [ (some) (id) ]
+   /Root 6 0 R
+   /Size 7
+>>
+startxref
+1185
+%%EOF

+ 12 - 0
PDF Office/PDF Master/KMClass/KMPDFViewController/PDFImages.xcassets/Watermark/edit_rotateRight.imageset/Contents.json

@@ -0,0 +1,12 @@
+{
+  "images" : [
+    {
+      "filename" : "edit_rotateRight.pdf",
+      "idiom" : "universal"
+    }
+  ],
+  "info" : {
+    "author" : "xcode",
+    "version" : 1
+  }
+}

+ 83 - 0
PDF Office/PDF Master/KMClass/KMPDFViewController/PDFImages.xcassets/Watermark/edit_rotateRight.imageset/edit_rotateRight.pdf

@@ -0,0 +1,83 @@
+%PDF-1.7
+
+1 0 obj
+  << >>
+endobj
+
+2 0 obj
+  << /Length 3 0 R >>
+stream
+/DeviceRGB CS
+/DeviceRGB cs
+q
+1.000000 0.000000 -0.000000 1.000000 0.849854 1.649902 cm
+0.250980 0.274510 0.325490 scn
+11.142200 7.101053 m
+10.781237 9.422997 8.773140 11.200012 6.350000 11.200012 c
+3.671418 11.200012 1.500000 9.028593 1.500000 6.350012 c
+1.500000 3.671431 3.671418 1.500012 6.350000 1.500012 c
+7.234642 1.500012 8.061850 1.736176 8.774456 2.148396 c
+9.525544 0.849988 l
+8.590780 0.309257 7.505365 0.000012 6.350000 0.000012 c
+2.842992 0.000012 0.000000 2.843004 0.000000 6.350012 c
+0.000000 9.857020 2.842992 12.700012 6.350000 12.700012 c
+9.314274 12.700012 11.804151 10.668878 12.503809 7.922430 c
+12.965594 9.645836 l
+14.414483 9.257607 l
+13.462029 5.703000 l
+13.354823 5.302900 12.943570 5.065464 12.543470 5.172670 c
+8.988863 6.125124 l
+9.377091 7.574013 l
+11.142200 7.101053 l
+h
+f*
+n
+Q
+
+endstream
+endobj
+
+3 0 obj
+  810
+endobj
+
+4 0 obj
+  << /Annots []
+     /Type /Page
+     /MediaBox [ 0.000000 0.000000 16.000000 15.999939 ]
+     /Resources 1 0 R
+     /Contents 2 0 R
+     /Parent 5 0 R
+  >>
+endobj
+
+5 0 obj
+  << /Kids [ 4 0 R ]
+     /Count 1
+     /Type /Pages
+  >>
+endobj
+
+6 0 obj
+  << /Pages 5 0 R
+     /Type /Catalog
+  >>
+endobj
+
+xref
+0 7
+0000000000 65535 f
+0000000010 00000 n
+0000000034 00000 n
+0000000900 00000 n
+0000000922 00000 n
+0000001095 00000 n
+0000001169 00000 n
+trailer
+<< /ID [ (some) (id) ]
+   /Root 6 0 R
+   /Size 7
+>>
+startxref
+1228
+%%EOF

+ 19 - 0
PDF Office/PDF Master/KMClass/KMPDFViewController/RightSideViews/Watermark/New/Views/KMNWatermarkPropertyController.swift

@@ -73,6 +73,25 @@ class KMNWatermarkPropertyController: NSViewController {
         templateButton.properties = ComponentButtonProperty(type: .text_gray, size: .xxs, onlyIcon: true, icon: NSImage(named: "icon_wm_template"))
         
         typeTabs.updateItemProperty([textTabProperty, fileTabProperty])
+        
+        
+        //Text
+        let familyNames = CPDFFont.familyNames
+        
+        fontNameSelect.properties = ComponentSelectProperties(size: .s,
+                                                              state: .normal,
+                                                              text: "")
+        
+        var menuItemArr: [ComponentMenuitemProperty] = []
+        for string in familyNames {
+            let item = ComponentMenuitemProperty(type: .normal, text: string, identifier: string)
+            menuItemArr.append(item)
+        }
+        fontNameSelect.updateMenuItemsArr(menuItemArr)
+        
+        
+        //File
+        
 
         //Appearance
         appearanceLabel.stringValue = KMLocalizedString("Appearance")

+ 42 - 0
PDF Office/PDF Master/KMClass/KMPDFViewController/RightSideViews/Watermark/New/Views/KMNWatermarkPropertyController.xib

@@ -177,8 +177,48 @@
                                         </customView>
                                         <customView translatesAutoresizingMaskIntoConstraints="NO" id="8Kw-R6-WKn">
                                             <rect key="frame" x="0.0" y="152" width="232" height="32"/>
+                                            <subviews>
+                                                <imageView horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="zd3-AF-v6Y">
+                                                    <rect key="frame" x="0.0" y="8" width="16" height="16"/>
+                                                    <constraints>
+                                                        <constraint firstAttribute="height" constant="16" id="gc7-Uk-uhb"/>
+                                                        <constraint firstAttribute="width" constant="16" id="hSK-15-hKf"/>
+                                                    </constraints>
+                                                    <imageCell key="cell" refusesFirstResponder="YES" alignment="left" imageScaling="proportionallyDown" image="edit_rotateRight" id="uNi-b3-wGw"/>
+                                                </imageView>
+                                                <customView translatesAutoresizingMaskIntoConstraints="NO" id="uWb-rG-ugv" customClass="ComponentSelect" customModule="KMComponentLibrary">
+                                                    <rect key="frame" x="20" y="0.0" width="92" height="32"/>
+                                                    <constraints>
+                                                        <constraint firstAttribute="width" constant="92" id="hCV-us-Rru"/>
+                                                        <constraint firstAttribute="height" constant="32" id="pX0-fG-PVs"/>
+                                                    </constraints>
+                                                </customView>
+                                                <imageView horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="ler-kW-KZg">
+                                                    <rect key="frame" x="120" y="8" width="16" height="16"/>
+                                                    <constraints>
+                                                        <constraint firstAttribute="width" constant="16" id="PfS-ma-oBZ"/>
+                                                        <constraint firstAttribute="height" constant="16" id="p1d-zj-sbx"/>
+                                                    </constraints>
+                                                    <imageCell key="cell" refusesFirstResponder="YES" alignment="left" imageScaling="proportionallyDown" image="edit_ocapity" id="j7x-Ee-g05"/>
+                                                </imageView>
+                                                <customView translatesAutoresizingMaskIntoConstraints="NO" id="76y-LT-L3w" customClass="ComponentSelect" customModule="KMComponentLibrary">
+                                                    <rect key="frame" x="140" y="0.0" width="92" height="32"/>
+                                                    <constraints>
+                                                        <constraint firstAttribute="height" constant="32" id="1rN-in-MmY"/>
+                                                        <constraint firstAttribute="width" constant="92" id="Tc1-QW-mEg"/>
+                                                    </constraints>
+                                                </customView>
+                                            </subviews>
                                             <constraints>
+                                                <constraint firstItem="uWb-rG-ugv" firstAttribute="leading" secondItem="zd3-AF-v6Y" secondAttribute="trailing" constant="4" id="BNL-If-0AX"/>
                                                 <constraint firstAttribute="height" constant="32" id="BQe-OW-IxT"/>
+                                                <constraint firstItem="ler-kW-KZg" firstAttribute="centerY" secondItem="8Kw-R6-WKn" secondAttribute="centerY" id="BkV-2V-Ruh"/>
+                                                <constraint firstItem="ler-kW-KZg" firstAttribute="leading" secondItem="uWb-rG-ugv" secondAttribute="trailing" constant="8" id="DHd-F1-IHL"/>
+                                                <constraint firstItem="zd3-AF-v6Y" firstAttribute="leading" secondItem="8Kw-R6-WKn" secondAttribute="leading" id="KlW-Ea-P2H"/>
+                                                <constraint firstItem="76y-LT-L3w" firstAttribute="leading" secondItem="ler-kW-KZg" secondAttribute="trailing" constant="4" id="Ni4-WA-tfL"/>
+                                                <constraint firstItem="76y-LT-L3w" firstAttribute="centerY" secondItem="8Kw-R6-WKn" secondAttribute="centerY" id="Ygu-Qz-5Dd"/>
+                                                <constraint firstItem="zd3-AF-v6Y" firstAttribute="centerY" secondItem="8Kw-R6-WKn" secondAttribute="centerY" id="dQN-9q-JfU"/>
+                                                <constraint firstItem="uWb-rG-ugv" firstAttribute="centerY" secondItem="8Kw-R6-WKn" secondAttribute="centerY" id="u5e-M5-WZP"/>
                                             </constraints>
                                         </customView>
                                         <customView translatesAutoresizingMaskIntoConstraints="NO" id="Gff-0V-jaD" customClass="ComponentCheckBox" customModule="KMComponentLibrary">
@@ -428,6 +468,8 @@
         </customView>
     </objects>
     <resources>
+        <image name="edit_ocapity" width="16" height="16"/>
+        <image name="edit_rotateRight" width="16" height="16"/>
         <image name="tile_spacing_horiz" width="16" height="16"/>
         <image name="tile_spacing_vert" width="16" height="16"/>
     </resources>

+ 2 - 0
PDF Office/PDF Master/KMClass/Settings/SettingsManager.swift

@@ -77,6 +77,8 @@ import Cocoa
      
 }
 
+let APPAppearanceChangedNotificationName       = "APPAppearanceChangedNotificationName"
+
 //General
 let settingsAppearanceKey       = "settingsAppearanceKey"
 let settingsAuthorKey           = "settingsAuthorKey"

BIN
PDF Office/PDF Master/Third Pard Library/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/MacOS/Autoupdate


BIN
PDF Office/PDF Master/Third Pard Library/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/MacOS/fileop