Sfoglia il codice sorgente

PDFViewer(ios) - 接入sdk

dengkang 2 anni fa
parent
commit
8be6e16e27
73 ha cambiato i file con 4483 aggiunte e 11 eliminazioni
  1. BIN
      ComPDFKit.framework/ComPDFKit
  2. BIN
      ComPDFKit.framework/DroidSansFallback.ttf
  3. 30 0
      ComPDFKit.framework/Headers/CPDFAction.h
  4. 188 0
      ComPDFKit.framework/Headers/CPDFAnnotation.h
  5. 103 0
      ComPDFKit.framework/Headers/CPDFBackground.h
  6. 20 0
      ComPDFKit.framework/Headers/CPDFBates.h
  7. 41 0
      ComPDFKit.framework/Headers/CPDFBookmark.h
  8. 47 0
      ComPDFKit.framework/Headers/CPDFBorder.h
  9. 77 0
      ComPDFKit.framework/Headers/CPDFButtonWidgetAnnotation.h
  10. 48 0
      ComPDFKit.framework/Headers/CPDFChoiceWidgetAnnotation.h
  11. 34 0
      ComPDFKit.framework/Headers/CPDFCircleAnnotation.h
  12. 76 0
      ComPDFKit.framework/Headers/CPDFDestination.h
  13. 549 0
      ComPDFKit.framework/Headers/CPDFDocument.h
  14. 39 0
      ComPDFKit.framework/Headers/CPDFFreeTextAnnotation.h
  15. 40 0
      ComPDFKit.framework/Headers/CPDFGoToAction.h
  16. 77 0
      ComPDFKit.framework/Headers/CPDFHeaderFooter.h
  17. 28 0
      ComPDFKit.framework/Headers/CPDFInkAnnotation.h
  18. 83 0
      ComPDFKit.framework/Headers/CPDFKit.h
  19. 235 0
      ComPDFKit.framework/Headers/CPDFKitConfig.h
  20. 39 0
      ComPDFKit.framework/Headers/CPDFKitPlatform.h
  21. 80 0
      ComPDFKit.framework/Headers/CPDFLineAnnotation.h
  22. 38 0
      ComPDFKit.framework/Headers/CPDFLinkAnnotation.h
  23. 58 0
      ComPDFKit.framework/Headers/CPDFMarkupAnnotation.h
  24. 22 0
      ComPDFKit.framework/Headers/CPDFMovieAnnotation.h
  25. 42 0
      ComPDFKit.framework/Headers/CPDFNamedAction.h
  26. 104 0
      ComPDFKit.framework/Headers/CPDFOutline.h
  27. 192 0
      ComPDFKit.framework/Headers/CPDFPage.h
  28. 90 0
      ComPDFKit.framework/Headers/CPDFRedactAnnotation.h
  29. 22 0
      ComPDFKit.framework/Headers/CPDFResetFormAction.h
  30. 54 0
      ComPDFKit.framework/Headers/CPDFSelection.h
  31. 21 0
      ComPDFKit.framework/Headers/CPDFSignatureAnnotation.h
  32. 21 0
      ComPDFKit.framework/Headers/CPDFSignatureWidgetAnnotation.h
  33. 25 0
      ComPDFKit.framework/Headers/CPDFSoundAnnotation.h
  34. 34 0
      ComPDFKit.framework/Headers/CPDFSquareAnnotation.h
  35. 78 0
      ComPDFKit.framework/Headers/CPDFStampAnnotation.h
  36. 20 0
      ComPDFKit.framework/Headers/CPDFTextAnnotation.h
  37. 39 0
      ComPDFKit.framework/Headers/CPDFTextWidgetAnnotation.h
  38. 36 0
      ComPDFKit.framework/Headers/CPDFURLAction.h
  39. 22 0
      ComPDFKit.framework/Headers/CPDFUtilities.h
  40. 330 0
      ComPDFKit.framework/Headers/CPDFView.h
  41. 167 0
      ComPDFKit.framework/Headers/CPDFWatermark.h
  42. 50 0
      ComPDFKit.framework/Headers/CPDFWidgetAnnotation.h
  43. 57 0
      ComPDFKit.framework/Headers/ComPDFKit.h
  44. BIN
      ComPDFKit.framework/Info.plist
  45. 6 0
      ComPDFKit.framework/Modules/module.modulemap
  46. 1062 0
      ComPDFKit.framework/_CodeSignature/CodeResources
  47. BIN
      ComPDFKit.framework/formsign_tag.png
  48. BIN
      ComPDFKit.framework/formsign_tag@2x.png
  49. BIN
      ComPDFKit.framework/loupe-hi.png
  50. BIN
      ComPDFKit.framework/loupe-lo.png
  51. BIN
      ComPDFKit.framework/loupe-mask.png
  52. BIN
      ComPDFKit.framework/magnifier-ranged-hi.png
  53. BIN
      ComPDFKit.framework/magnifier-ranged-lo.png
  54. BIN
      ComPDFKit.framework/magnifier-ranged-mask.png
  55. BIN
      ComPDFKit.framework/popup_note.png
  56. BIN
      ComPDFKit.framework/popup_note@2x.png
  57. BIN
      ComPDFKit.framework/quick_bookmark.png
  58. BIN
      ComPDFKit.framework/quick_bookmark~ipad.png
  59. BIN
      ComPDFKit.framework/recoding_on.png
  60. BIN
      ComPDFKit.framework/recoding_on@2x.png
  61. BIN
      ComPDFKit.framework/recoding_play.png
  62. BIN
      ComPDFKit.framework/recoding_play@2x.png
  63. BIN
      ComPDFKit.framework/sRGB2014.icc
  64. BIN
      ComPDFKit.framework/viewer_dragDontBack.png
  65. BIN
      ComPDFKit.framework/viewer_dragDontBack@2x.png
  66. BIN
      ComPDFKit.framework/viewer_dragDontFront.png
  67. BIN
      ComPDFKit.framework/viewer_dragDontFront@2x.png
  68. 30 0
      PDFViewer.xcodeproj/project.pbxproj
  69. BIN
      PDFViewer.xcodeproj/project.xcworkspace/xcuserdata/kdan.xcuserdatad/UserInterfaceState.xcuserstate
  70. 3 0
      PDFViewer/AppDelegate.m
  71. 23 11
      PDFViewer/Controller/CPDFController.m
  72. 2 0
      PDFViewer/SceneDelegate.m
  73. 1 0
      PDFViewer/ViewController.m

BIN
ComPDFKit.framework/ComPDFKit


BIN
ComPDFKit.framework/DroidSansFallback.ttf


+ 30 - 0
ComPDFKit.framework/Headers/CPDFAction.h

@@ -0,0 +1,30 @@
+//
+//  CPDFAction.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFKitPlatform.h>
+
+/**
+ * An action that is performed when, for example, a PDF annotation is activated or an outline item is clicked.
+ *
+ * @discussion A CPDFAction object represents an action associated with a PDF element, such as an annotation or a link, that the viewer application can perform. See the Adobe PDF Specification for more about actions and action types.
+ * CPDFAction is an abstract superclass of the following concrete classes: CPDFGoToAction, CPDFURLAction, CPDFNamedAction, CPDFResetFormAction.
+ */
+@interface CPDFAction : NSObject
+
+/**
+ * Returns the type of the action.
+ *
+ * @discussion Type based on the Adobe PDF Specification (1.7), Table 8.48: Action types.
+ */
+@property (nonatomic,readonly) NSInteger type;
+
+@end

+ 188 - 0
ComPDFKit.framework/Headers/CPDFAnnotation.h

@@ -0,0 +1,188 @@
+//
+//  CPDFAnnotation.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFKitPlatform.h>
+#import <ComPDFKit/CPDFPage.h>
+#import <ComPDFKit/CPDFBorder.h>
+
+/**
+ * A set of flags specifying various characteristics of the annotation.
+ * ComPDFKit doesn't support all of those flag settings.
+ */
+typedef NS_OPTIONS(NSInteger, CPDFAnnotationFlags) {
+    /* [IGNORED] If set, ignore annotation AP stream if there is no handler available. */
+    CPDFAnnotationFlagInvisible = 1,
+    /* If set, do not display or print the annotation or allow it to interact with the user. */
+    CPDFAnnotationFlagHidden = 1 << 1,
+    /* [IGNORED] If set, print the annotation when the page is printed. */
+    CPDFAnnotationFlagPrint = 1 << 2,
+    /* [IGNORED] If set, don't scale the annotation’s appearance to match the magnification of the page. */
+    CPDFAnnotationFlagNoZoom = 1 << 3,
+    /* [IGNORED] If set, don't rotate the annotation’s appearance to match the rotation of the page. */
+    CPDFAnnotationFlagNoRotate = 1 << 4,
+    /* [IGNORED] If set, don't display the annotation on the screen. (But printing might be allowed) */
+    CPDFAnnotationFlagNoView = 1 << 5,
+    /**
+     * If set, don’t allow the annotation to be deleted or its properties to be modified, including `contents`.
+     * This is ignored for widget annotations (form elements).
+     * For widget annotations the `isReadOnly` property of the associated form field should be used instead.
+     * This flag only restricts the ComPDFKit UI and does not impact programmatic modification of the annotation.
+     */
+    CPDFAnnotationFlagReadOnly = 1 << 6,
+    /* If set, don’t allow the annotation to be deleted or its properties to be modified, except for `contents`. */
+    CPDFAnnotationFlagLocked = 1 << 7,
+    /* [IGNORED] If set, invert the interpretation of the `.noView` flag for certain events. */
+    CPDFAnnotationFlagToggleNoView = 1 << 8,
+    /* [IGNORED] If set, don't allow the `contents` of the annotation to be modified by the user. */
+    CPDFAnnotationFlagLockedContents = 1 << 9
+};
+
+/**
+ * An annotation in a PDF document.
+ *
+ * @discussion In addition to its primary textual content, a PDF file can contain annotations that represent links, form elements, highlighting circles, textual notes, and so on.
+ * Each annotation is associated with a specific location on a page and may offer interactivity with the user.
+ *
+ * This is the base class for all annotations. A CPDFAnnotation object by itself is not useful, only subclasses (like CPDFCircleAnnotation, CPDFTextAnnotation) are interesting.
+ * In parsing a PDF however, any unknown or unsupported annotations will be represented as this base class.
+ */
+@interface CPDFAnnotation : NSObject
+
+#pragma mark - Initializers
+
+/**
+ * Initializes a PDF annotation object.
+ *
+ * @discussion Subclasses of CPDFAnnotation should use this method to initialize annotation instances.
+ * Invoking initWithDocument: directly on a CPDFAnnotation object creates an illegal NULL type.
+ */
+- (instancetype)initWithDocument:(CPDFDocument *)document;
+
+#pragma mark - Accessors
+
+/**
+ * Returns the page that the annotation is associated with (may return nil if annotation not associated with a page).
+ *
+ * @discussion The addAnnotation: method in the CPDFPage class lets you associate an annotation with a page.
+ */
+@property (nonatomic,readonly) CPDFPage *page;
+
+/**
+ * Returns the type of the annotation. Examples include: "Text", "Link", "Line", etc.
+ *
+ * @discussion The type of the annotation. Types include Line, Link, Text, and so on, referring to the CPDFAnnotation subclasses.
+ * In the Adobe PDF Specification, this attribute is called Subtype, and the common “type” for all annotations in the PDF Specification is Annot.
+ */
+@property (nonatomic,readonly) NSString *type;
+
+/**
+ * Method to get / set the bounding box for the annotation in page space. Required for all annotations.
+ *
+ * @discussion Page space is coordinate system with the origin at the lower-left corner of the current page.
+ */
+@property (nonatomic,assign) CGRect bounds;
+
+/**
+ * Method to get / set the textual content (if any) associated with the annotation.
+ *
+ * @discussion Textual content is typically associated with CPDFTextAnnotation and CPDFFreeTextAnnotation annotations.
+ */
+@property (nonatomic,retain) NSString *contents;
+
+/**
+ * Method to get / set the stroke thickness for the annotation.
+ *
+ * @discussion For the "geometry" annotations (Circle, Ink, Line, Square), the stroke thickness indicates the line width.
+ * CPDFAnnotation markup types (Highlight, Strikethrough, Underline) ignores the stroke thickness.
+ */
+@property (nonatomic,assign) CGFloat borderWidth;
+
+/**
+ * Optional border or border style that describes how to draw the annotation border (if any).
+ * @discussion For the "geometry" annotations (Circle, Ink, Line, Square), the border indicates the line width and whether to draw with a dash pattern or solid pattern.
+ * CPDFAnnotation markup types (Highlight, Strikethrough, Underline) ignores the border.
+ */
+@property (nonatomic,retain) CPDFBorder *border;
+
+/**
+ * Method to get / set the opacity for the annotation.
+ */
+@property (nonatomic,assign) CGFloat opacity;
+
+/**
+ * Method to get / set the color for the annotation.
+ * @discussion For many annotations ("Circle", "Square") the stroke color. Used for other annotations as well.
+ */
+@property (nonatomic,retain) CPDFKitPlatformColor *color;
+
+@property (nonatomic,assign) BOOL isNoRotate;
+
+/**
+ * Returns the modification date of the annotation.
+ */
+- (NSDate *)modificationDate;
+- (void)setModificationDate:(NSDate *)modificationDate;
+
+/**
+ * Returns the name of the user who created the annotation.
+ */
+- (NSString *)userName;
+- (void)setUserName:(NSString *)userName;
+
+/**
+ * Returns the flags of the annotation.
+ *
+ * @see CPDFAnnotationFlags
+ */
+- (CPDFAnnotationFlags)flags;
+/**
+ * Sets the flags of the annotation.
+ *
+ * @see CPDFAnnotationFlags
+ */
+- (void)setFlags:(CPDFAnnotationFlags)flags;
+
+/**
+ * This is a convenience property that checks for `CPDFAnnotationFlagHidden` in `flags`.
+ */
+- (BOOL)isHidden;
+- (void)setHidden:(BOOL)hidden;
+
+/**
+ * This is a convenience property that checks for `CPDFAnnotationFlagReadOnly` in `flags`.
+ */
+- (BOOL)isReadOnly;
+- (void)setReadOnly:(BOOL)readOnly;
+
+/**
+ * This is a convenience property that checks for `CPDFAnnotationFlagLocked` in `flags`.
+ */
+- (BOOL)isLocked;
+- (void)setLocked:(BOOL)locked;
+
+/**
+ * Update appearance stream for the annotation.
+ *
+ * @discussion ComPDFKit will update the annotation appearance by default when you modify the annotation properties.
+ * You can also manually update the appearance by calling the updateAppearanceStream method,
+ * but you must call the updateAppearanceStream method manually when you modify the bounds of CPDFTextAnnotation, CPDFStampAnnotation, CPDFSignatureAnnotation annotations.
+ */
+- (void)updateAppearanceStream;
+
+#pragma mark - Drawing
+
+/**
+ * Draw method. Draws in page-space relative to origin of "box" passed in and to the given context.
+ */
+- (void)drawWithBox:(CPDFDisplayBox)box inContext:(CGContextRef)context;
+
+@end

+ 103 - 0
ComPDFKit.framework/Headers/CPDFBackground.h

@@ -0,0 +1,103 @@
+//
+//  CPDFBackground.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFKitPlatform.h>
+
+typedef NS_ENUM(NSInteger, CPDFBackgroundType) {
+    CPDFBackgroundTypeColor = 0,
+    CPDFBackgroundTypeImage
+};
+
+/**
+ * Adds and removes the background.
+ */
+@interface CPDFBackground : NSObject
+
+#pragma mark - Accessors
+
+/**
+ * Method to get / set the type of the background.
+ *
+ * @see CPDFBackgroundType
+ */
+@property (nonatomic,assign) CPDFBackgroundType type;
+
+/**
+ * Method to get / set the color of the background.
+ */
+@property (nonatomic,retain) CPDFKitPlatformColor *color;
+
+/**
+ * Method to get / set the scale of the background.
+ */
+@property (nonatomic,assign) CGFloat scale;
+
+/**
+ * Method to get / set the rotation angle of the background.
+ */
+@property (nonatomic,assign) CGFloat rotation;
+
+/**
+ * Method to get / set the opacity of the background.
+ */
+@property (nonatomic,assign) CGFloat opacity;
+
+/**
+ * Method to get / set the page range of the background by string, such as "0,3,5-7".
+ */
+@property (nonatomic,retain) NSString *pageString;
+
+/**
+ * Method to get / set the vertical alignment of the background.
+ */
+@property (nonatomic,assign) NSUInteger verticalAlignment;
+
+/**
+ * Method to get / set the horizontal offset of the background.
+ */
+@property (nonatomic,assign) NSUInteger horizontalAlignment;
+
+/**
+ * Method to get / set the horizontal offset of the background.
+ */
+@property (nonatomic,assign) CGFloat xOffset;
+
+/**
+ * Method to get / set the vertical offset of the background.
+ */
+@property (nonatomic,assign) CGFloat yOffset;
+
+/**
+ * Method to get / set whether to support the background to be displayed.
+ */
+@property (nonatomic,assign) BOOL isAllowsView;
+
+/**
+ * Method to get / set whether to support the background to be printed.
+ */
+@property (nonatomic,assign) BOOL isAllowsPrint;
+
+/**
+ * Sets the image of the background.
+ */
+- (void)setImage:(CPDFKitPlatformImage *)image;
+
+/**
+ * Updates the background.
+ */
+- (void)update;
+/**
+ * Removes the background.
+ */
+- (void)clear;
+
+@end

+ 20 - 0
ComPDFKit.framework/Headers/CPDFBates.h

@@ -0,0 +1,20 @@
+//
+//  CPDFBates.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFHeaderFooter.h>
+
+/**
+ * Adds and removes the bates numbers.
+ */
+@interface CPDFBates : CPDFHeaderFooter
+
+@end

+ 41 - 0
ComPDFKit.framework/Headers/CPDFBookmark.h

@@ -0,0 +1,41 @@
+//
+//  CPDFBookmark.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFKitPlatform.h>
+
+@class CPDFDocument;
+
+@interface CPDFBookmark : NSObject
+
+#pragma mark - Accessors
+
+/**
+ * Returns the document with which the bookmark is associated.
+ */
+@property (nonatomic,readonly) CPDFDocument *document;
+
+/**
+ * Returns the page index that the bookmark refers to.
+ */
+@property (nonatomic,readonly) NSInteger pageIndex;
+
+/**
+ * Method to get / set the label for the bookmark.
+ */
+@property (nonatomic,retain) NSString *label;
+
+/**
+ * Method to get / set the date for the bookmark.
+ */
+@property (nonatomic,retain) NSDate *date;
+
+@end

+ 47 - 0
ComPDFKit.framework/Headers/CPDFBorder.h

@@ -0,0 +1,47 @@
+//
+//  CPDFBorder.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFKitPlatform.h>
+
+/**
+ * Style in which CPDFBorder is displayed.
+ */
+typedef NS_ENUM(NSInteger, CPDFBorderStyle) {
+    CPDFBorderStyleSolid = 0,
+    CPDFBorderStyleDashed = 1,
+    CPDFBorderStyleBeveled = 2,
+    CPDFBorderStyleInset = 3,
+    CPDFBorderStyleUnderline = 4
+};
+
+@interface CPDFBorder : NSObject
+
+- (instancetype)initWithStyle:(CPDFBorderStyle)style lineWidth:(CGFloat)lineWidth dashPattern:(NSArray *)dashPattern;
+
+/**
+ * Whether border is drawn solid, dashed etc.
+ *
+ * @see CPDFBorderStyle
+ */
+@property (nonatomic,readonly) CPDFBorderStyle style;
+
+/**
+ * Width of line used to stroke border.
+ */
+@property (nonatomic,readonly) CGFloat lineWidth;
+
+/**
+ * Array of floats specifying the dash pattern.
+ */
+@property (nonatomic,readonly) NSArray *dashPattern;
+
+@end

+ 77 - 0
ComPDFKit.framework/Headers/CPDFButtonWidgetAnnotation.h

@@ -0,0 +1,77 @@
+//
+//  CPDFButtonWidgetAnnotation.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFWidgetAnnotation.h>
+
+typedef NS_ENUM(NSInteger, CPDFWidgetControlType) {
+    CPDFWidgetUnknownControl = -1,
+    CPDFWidgetPushButtonControl = 0,
+    CPDFWidgetRadioButtonControl = 1,
+    CPDFWidgetCheckBoxControl = 2
+};
+
+@class CPDFAction;
+
+/**
+ * A CPDFButtonWidgetAnnotation object provides user interactivity on a page of a PDF document. There are three types of buttons available: push button, radio button, and checkbox.
+ *
+ * @discussion CPDFButtonWidgetAnnotation inherits general annotation behavior from the CPDFWidgetAnnotation class.
+ */
+@interface CPDFButtonWidgetAnnotation : CPDFWidgetAnnotation
+
+/**
+ * Initializes CPDFButtonWidgetAnnotation object.
+ *
+ * @see CPDFWidgetControlType
+ */
+- (instancetype)initWithDocument:(CPDFDocument *)document controlType:(CPDFWidgetControlType)controlType;
+
+/**
+ * Returns the type of the control.
+ *
+ * @see CPDFWidgetControlType
+ */
+- (CPDFWidgetControlType)controlType;
+
+/**
+ * Returns the state of the control.
+ *
+ * @discussion Applies to CPDFWidgetRadioButtonControl or CPDFWidgetCheckBoxControl only.
+ */
+- (NSInteger)state;
+/**
+ * Sets the state of the control.
+ *
+ * @discussion Applies to CPDFWidgetRadioButtonControl or CPDFWidgetCheckBoxControl only.
+ */
+- (void)setState:(NSInteger)value;
+
+/**
+ * Returns the text of the label on a push button control.
+ *
+ * @discussion This method applies only to the label drawn on a control of type CPDFWidgetPushButtonControl.
+ */
+- (NSString *)caption;
+/**
+ * Sets the text of the label on a push button control.
+ *
+ * @discussion This method applies only to the label drawn on a control of type CPDFWidgetPushButtonControl.
+ */
+- (void)setCaption:(NSString *)name;
+
+- (CPDFAction *)action;
+- (void)setAction:(CPDFAction *)action;
+
+- (BOOL)isTick;
+- (void)setIsTick:(NSInteger)isTick;
+
+@end

+ 48 - 0
ComPDFKit.framework/Headers/CPDFChoiceWidgetAnnotation.h

@@ -0,0 +1,48 @@
+//
+//  CPDFChoiceWidgetAnnotation.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFWidgetAnnotation.h>
+
+@interface CPDFChoiceWidgetItem : NSObject
+
+@property (nonatomic,retain) NSString *value;
+@property (nonatomic,retain) NSString *string;
+
+@end
+
+/**
+ * A CPDFChoiceWidgetAnnotation object provides user interactivity on a page of a PDF document, in the form of pop-up menus and lists.
+ *
+ * @discussion CPDFButtonWidgetAnnotation inherits general annotation behavior from the CPDFWidgetAnnotation class.
+ */
+@interface CPDFChoiceWidgetAnnotation : CPDFWidgetAnnotation
+
+/**
+ * Initializes CPDFChoiceWidgetAnnotation object.
+ */
+- (instancetype)initWithDocument:(CPDFDocument *)document listChoice:(BOOL)isListChoice;
+
+/**
+ * Returns a Boolean value indicating whether the widget annotation is a list.
+ *
+ * @discussion There are two flavors of Choice widget annotations, lists and pop-up menus. These methods allow you to differentiate.
+ */
+@property (nonatomic,readonly) BOOL isListChoice;
+
+/**
+ * Returns an array of CPDFChoiceWidgetItem that represent the items available in the list or pop-up menu of the choice widget annotation.
+ */
+@property (nonatomic,retain) NSArray<CPDFChoiceWidgetItem *> *items;
+
+@property (nonatomic,assign) NSInteger selectItemAtIndex;
+
+@end

+ 34 - 0
ComPDFKit.framework/Headers/CPDFCircleAnnotation.h

@@ -0,0 +1,34 @@
+//
+//  CPDFCircleAnnotation.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFAnnotation.h>
+
+/**
+ * A CPDFCircleAnnotation object displays an ellipse on a page.
+ *
+ * @discussion Circle annotations are like square annotations (instances of the CPDFSquareAnnotation class) apart from the shape.
+ * The setBorderWidth: method of the CPDFAnnotation class determines the stroke thickness.
+ * The setColor: method of the CPDFAnnotation class determines the stroke color.
+ */
+@interface CPDFCircleAnnotation : CPDFAnnotation
+
+/**
+ * Method to get / set the fill opacity used for drawing the annotation.
+ */
+@property (nonatomic,assign) CGFloat interiorOpacity;
+
+/**
+ * Method to get / set the fill color used for drawing the annotation.
+ */
+@property (nonatomic,retain) CPDFKitPlatformColor *interiorColor;
+
+@end

+ 76 - 0
ComPDFKit.framework/Headers/CPDFDestination.h

@@ -0,0 +1,76 @@
+//
+//  CPDFDestination.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFKitPlatform.h>
+
+@class CPDFDocument;
+
+/**
+ * A CPDFDestination object describes a point on a PDF page.
+ *
+ * @discussion In typical usage, you do not initialize CPDFDestination objects but rather get them as either attributes of CPDFLinkAnnotation or CPDFOutline objects,
+ * or in response to the CPDFView method currentDestination.
+ */
+@interface CPDFDestination : NSObject
+
+#pragma mark - Initializers
+
+/**
+ * Initializes the destination.
+ *
+ * @discussion Specify point in page space. Typically, there’s no need to initialize destinations. Instead, you get them from CPDFLinkAnnotation, CPDFOutline, or CPDFView objects.
+ * @param document The document with which the destination is associated.
+ * @param pageIndex The page index of the destination.
+ */
+- (instancetype)initWithDocument:(CPDFDocument *)document
+                       pageIndex:(NSInteger)pageIndex;
+
+/**
+ * Initializes the destination.
+ *
+ * @discussion Specify point in page space. Typically, there’s no need to initialize destinations. Instead, you get them from CPDFLinkAnnotation, CPDFOutline, or CPDFView objects.
+ * Page space is a coordinate system with the origin at the lower-left corner of the current page.
+ * @param document The document with which the destination is associated.
+ * @param pageIndex The page index of the destination.
+ * @param point The point of the destination, in page space.
+ * @param zoom The zoom of the destination.
+ */
+- (instancetype)initWithDocument:(CPDFDocument *)document
+                       pageIndex:(NSInteger)pageIndex
+                         atPoint:(CGPoint)point
+                            zoom:(CGFloat)zoom;
+
+#pragma mark - Accessors
+
+/**
+ * Returns the document with which the destination is associated.
+ */
+@property (nonatomic,readonly) CPDFDocument *document;
+
+/**
+ * Returns the page index that the destination refers to.
+ */
+@property (nonatomic,readonly) NSInteger pageIndex;
+
+/**
+ * Returns the point, in page space, that the destination refers to.
+ *
+ * @discussion Page space is a coordinate system with the origin at the lower-left corner of the current page.
+ */
+@property (nonatomic,readonly) CGPoint point;
+
+/**
+ * Returns the scale factor the PDF viewer should assume for this destination.
+ */
+@property (nonatomic,readonly) CGFloat zoom;
+
+@end

+ 549 - 0
ComPDFKit.framework/Headers/CPDFDocument.h

@@ -0,0 +1,549 @@
+//
+//  CPDFDocument.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFKitPlatform.h>
+
+extern NSNotificationName const CPDFDocumentDidUnlockNotification;
+
+extern NSErrorDomain const CPDFDocumentErrorDomain;
+
+NS_ERROR_ENUM(CPDFDocumentErrorDomain) {
+    CPDFDocumentUnknownError  = 1,  // Unknown error.
+    CPDFDocumentFileError     = 2,  // File not found or could not be opened.
+    CPDFDocumentFormatError   = 3,  // File not in PDF format or corrupted.
+    CPDFDocumentPasswordError = 4,  // Password required or incorrect password.
+    CPDFDocumentSecurityError = 5,  // Unsupported security scheme.
+    CPDFDocumentPageError     = 6   // Page not found or content error.
+};
+
+/**
+ * An enumeration that specifies document permissions status.
+ */
+typedef NS_ENUM(NSInteger, CPDFDocumentPermissions) {
+    /** The status that indicates no document permissions. */
+    CPDFDocumentPermissionsNone = 0,
+    /** The status that indicates user document permissions. */
+    CPDFDocumentPermissionsUser,
+    /** The status that indicates owner document permissions. */
+    CPDFDocumentPermissionsOwner
+};
+
+typedef NS_OPTIONS(NSInteger, CPDFSearchOptions) {
+    CPDFSearchCaseInsensitive = 0,
+    /** If not set, it will not match case by default. */
+    CPDFSearchCaseSensitive = 1,
+    /** If not set, it will not match the whole word by default. */
+    CPDFSearchMatchWholeWord = 2,
+    /** If not set, it will skip past the current match to look for the next match. */
+    CPDFSearchConsecutive = 4
+};
+
+/**
+ * PDF/A conformance levels.
+ */
+typedef NS_ENUM(NSInteger, CPDFType) {
+    CPDFTypePDF = 0,
+    /** PDF/A-1a */
+    CPDFTypePDFA1a,
+    /** PDF/A-1b */
+    CPDFTypePDFA1b,
+    /** PDF/A-2a */
+    CPDFTypePDFA2a,
+    /** PDF/A-2u */
+    CPDFTypePDFA2u,
+    /** PDF/A-2b */
+    CPDFTypePDFA2b,
+    /** PDF/A-3a */
+    CPDFTypePDFA3a,
+    /** PDF/A-3u */
+    CPDFTypePDFA3u,
+    /** PDF/A-3b */
+    CPDFTypePDFA3b
+};
+
+typedef NSString *CPDFDocumentAttribute NS_STRING_ENUM;
+
+extern CPDFDocumentAttribute const CPDFDocumentTitleAttribute;             // NSString containing document title.
+extern CPDFDocumentAttribute const CPDFDocumentAuthorAttribute;            // NSString containing document author.
+extern CPDFDocumentAttribute const CPDFDocumentSubjectAttribute;           // NSString containing document title.
+extern CPDFDocumentAttribute const CPDFDocumentCreatorAttribute;           // NSString containing name of app that created document.
+extern CPDFDocumentAttribute const CPDFDocumentProducerAttribute;          // NSString containing name of app that produced PDF data.
+extern CPDFDocumentAttribute const CPDFDocumentKeywordsAttribute;          // NSString containing document keywords.
+extern CPDFDocumentAttribute const CPDFDocumentCreationDateAttribute;      // NSString representing document creation date.
+extern CPDFDocumentAttribute const CPDFDocumentModificationDateAttribute;  // NSString representing last document modification date.
+
+typedef NSString *CPDFDocumentWriteOption NS_STRING_ENUM;
+
+extern CPDFDocumentWriteOption const CPDFDocumentOwnerPasswordOption;      // NSString for the owner's password.
+extern CPDFDocumentWriteOption const CPDFDocumentUserPasswordOption;       // NSString for the user's password.
+
+extern CPDFDocumentWriteOption const CPDFDocumentAllowsPrintingOption;
+extern CPDFDocumentWriteOption const CPDFDocumentAllowsHighQualityPrintingOption;
+extern CPDFDocumentWriteOption const CPDFDocumentAllowsCopyingOption;
+extern CPDFDocumentWriteOption const CPDFDocumentAllowsDocumentChangesOption;
+extern CPDFDocumentWriteOption const CPDFDocumentAllowsDocumentAssemblyOption;
+extern CPDFDocumentWriteOption const CPDFDocumentAllowsCommentingOption;
+extern CPDFDocumentWriteOption const CPDFDocumentAllowsFormFieldEntryOption;
+
+@class CPDFPage, CPDFOutline, CPDFBookmark, CPDFWatermark, CPDFHeaderFooter, CPDFBates, CPDFBackground, CPDFSelection;
+@protocol CPDFDocumentDelegate;
+
+/**
+ * An object that represents a PDF file and defines methods for writing, searching, and selecting PDF data.
+ *
+ * @discussion The other utility classes are either instantiated from methods in CPDFDocument, as are CPDFPage and CPDFOutline; or support it, as do CPDFWatermark and CPDFDestination.
+ * You initialize a CPDFDocument object with a URL to a PDF file. You can then ask for the page count, add or delete pages, perform a find, or parse selected content into an NSString object.
+ */
+@interface CPDFDocument : NSObject
+
+#pragma mark - Initializers
+
+/**
+ * Initializes a CPDFDocument object with new PDF.
+ */
+- (instancetype)init;
+
+/**
+ * Initializes a CPDFDocument object with the contents at the specified URL.
+ */
+- (instancetype)initWithURL:(NSURL *)url;
+
+#pragma mark - Accessors
+
+/**
+ * The object acting as the delegate for the CPDFDocument object.
+ *
+ * @see CPDFDocumentDelegate
+ */
+@property (nonatomic,assign) id<CPDFDocumentDelegate> delegate;
+
+/**
+ * The URL for the document.
+ *
+ * @discussion May return NULL if the document was created from an new object.
+ */
+@property (nonatomic,readonly) NSURL *documentURL;
+
+/**
+ * The password for the document.
+ *
+ * @discussion May return NULL if the document is not an encrypted document.
+ */
+@property (nonatomic,readonly) NSString *password;
+
+/**
+ * Error message for the document loading.
+ *
+ * @discussion To determine the error type, use the code to obtain error of type CPDFDocumentErrorDomain.
+ * Except for the CPDFDocumentPasswordError error, other errors cannot open the document.
+ * If CPDFDocumentPasswordError, reading the document requires a password.
+ */
+@property (nonatomic,readonly) NSError *error;
+
+/**
+ * A Boolean value specifying whether the document is encrypted.
+ *
+ * @discussion Whether the PDF is encrypted. With the right password, a PDF can be unlocked - nonetheless, the PDF still indicates that it is encrypted - just no longer locked.
+ * Some PDF's may be encrypted but can be unlocked with the empty string. These are unlocked automatically.
+ */
+@property (nonatomic,readonly) BOOL isEncrypted;
+
+/**
+ * A Boolean value indicating whether the document is locked.
+ *
+ * @discussion Only encrypted documents can be locked. Use the unlockWithPassword: method to unlock a document using a password.
+ */
+@property (nonatomic,readonly) BOOL isLocked;
+
+/**
+ * Attempts to unlock an encrypted document.
+ *
+ * @discussion If the password is correct, this method returns YES, and a CPDFDocumentDidUnlockNotification notification is sent.
+ * Once unlocked, you cannot use this function to relock the document.
+ * @param password The password to unlock an encrypted document (you cannot lock an unlocked PDF document by using an incorrect password).
+ */
+- (BOOL)unlockWithPassword:(NSString *)password;
+
+/**
+ * The major version of the document.
+ *
+ * @discussion PDF version of the PDF file (example: major version = 1; PDF v1.4).
+ */
+@property (nonatomic,readonly) NSInteger majorVersion;
+/**
+ * The minor version of the document.
+ *
+ * @discussion PDF version of the PDF file (example: minor version = 4; PDF v1.4).
+ */
+@property (nonatomic,readonly) NSInteger minorVersion;
+
+/**
+ * The permissions status of the PDF document.
+ *
+ * @discussion Returns the permissions status of the PDF document. You have CPDFDocumentPermissionsNone status for an encrypted
+ * document that you have not supplied either a valid user or owner password. For a document with no encryption, you automatically have CPDFDocumentPermissionsUser status.
+ * @see CPDFDocumentPermissions
+ */
+@property (nonatomic,readonly) CPDFDocumentPermissions permissionsStatus;
+
+/**
+ * A Boolean value indicating whether the document allows printing.
+ */
+@property (nonatomic,readonly) BOOL allowsPrinting;
+/**
+ * A Boolean value indicating whether the document allows printing in high fidelity.
+ */
+@property (nonatomic,readonly) BOOL allowsHighQualityPrinting;
+/**
+ * A Boolean value indicating whether the document allows copying of content to the Pasteboard.
+ */
+@property (nonatomic,readonly) BOOL allowsCopying;
+/**
+ * A Boolean value indicating whether you can modify the document contents except for document attributes.
+ */
+@property (nonatomic,readonly) BOOL allowsDocumentChanges;
+/**
+ * A Boolean value indicating whether you can manage a document by inserting, deleting, and rotating pages.
+ */
+@property (nonatomic,readonly) BOOL allowsDocumentAssembly;
+/**
+ * A Boolean value indicating whether you can create or modify document annotations, including form field entries.
+ */
+@property (nonatomic,readonly) BOOL allowsCommenting;
+/**
+ * A Boolean value indicating whether you can modify form field entries even if you can't edit document annotations.
+ */
+@property (nonatomic,readonly) BOOL allowsFormFieldEntry;
+
+#pragma mark - Save
+
+/**
+ * A Boolean value indicating whether the document has been modified.
+ */
+- (BOOL)isModified;
+
+/**
+ * Writes the document to a location specified by the passed-in URL.
+ */
+- (BOOL)writeToURL:(NSURL *)url;
+
+/**
+ * Writes the document to the specified URL with the specified options.
+ *
+ * @discussion Set the password to the document by setting options.
+ * @param options CPDFDocumentOwnerPasswordOption, CPDFDocumentUserPasswordOption.
+ */
+- (BOOL)writeToURL:(NSURL *)url withOptions:(NSDictionary<CPDFDocumentWriteOption, id> *)options;
+
+/**
+ * Writes the document to the specified URL after flattening.
+ */
+- (BOOL)writeFlattenToURL:(NSURL *)url;
+
+/**
+ * Writes the document to the specified URL after removing annotions and form field entries.
+ */
+- (BOOL)writeContentToURL:(NSURL *)url;
+
+/**
+ * Writes the document to the specified URL after removing permissions.
+ */
+- (BOOL)writeDecryptToURL:(NSURL *)url;
+
+#pragma mark - Attributes
+
+/**
+ * A dictionary of document metadata.
+ *
+ * @discussion Metadata is optional for PDF documents. The dictionary may be empty, or only some of the keys may have associated values.
+ */
+- (NSDictionary<CPDFDocumentAttribute, id> *)documentAttributes;
+- (void)setDocumentAttributes:(NSDictionary<CPDFDocumentAttribute, id> *)documentAttributes;
+
+#pragma mark - Outline
+
+/**
+ * The document’s root outline to a PDF outline object.
+ *
+ * @discussion When a PDF document is saved, the outline tree structure is written out to the destination PDF file.
+ */
+- (CPDFOutline *)outlineRoot;
+
+/**
+ * Create a root outline for the document.
+ */
+- (CPDFOutline *)setNewOutlineRoot;
+
+#pragma mark - Bookmark
+
+/**
+ * A array of document’s bookmarks.
+ */
+- (NSArray<CPDFBookmark *> *)bookmarks;
+/**
+ * Add a bookmark at the specified index number.
+ *
+ * @discussion Indexes are zero based. This method raises an exception if index is out of bounds.
+ */
+- (BOOL)addBookmark:(NSString *)label forPageIndex:(NSUInteger)pageIndex;
+/**
+ * Remove the bookmark at the specified index number.
+ *
+ * @discussion Indexes are zero based. This method raises an exception if index is out of bounds.
+ */
+- (BOOL)removeBookmarkForPageIndex:(NSUInteger)pageIndex;
+/**
+ * Returns the bookmark at the specified index number.
+ *
+ * @discussion Indexes are zero based. This method raises an exception if index is out of bounds.
+ */
+- (CPDFBookmark *)bookmarkForPageIndex:(NSUInteger)pageIndex;
+
+#pragma mark - Watermark
+
+/**
+ * A array of document’s watermarks.
+ */
+- (NSArray<CPDFWatermark *> *)watermarks;
+/**
+ * Add a watermark.
+ *
+ * @param watermark A PDF watermark object.
+ */
+- (BOOL)addWatermark:(CPDFWatermark *)watermark;
+/**
+ * Remove the watermark.
+ *
+ * @param watermark The PDF watermark object from document’s watermarks.
+ */
+- (BOOL)removeWatermark:(CPDFWatermark *)watermark;
+/**
+ * Update the watermark.
+ *
+ * @param watermark The PDF watermark object from document’s watermarks.
+ */
+- (BOOL)updateWatermark:(CPDFWatermark *)watermark;
+
+#pragma mark - HeaderFooter
+
+/**
+ * Gets the header & footer of the document.
+ */
+- (CPDFHeaderFooter *)headerFooter;
+
+#pragma mark - Bates
+
+/**
+ * Gets the bates numbers of the document.
+ */
+- (CPDFBates *)bates;
+
+#pragma mark - Background
+
+/**
+ * Gets the background of the document.
+ */
+- (CPDFBackground *)background;
+
+#pragma mark - Pages
+
+/**
+ * The number of pages in the document.
+ */
+@property (nonatomic,readonly) NSUInteger pageCount;
+
+/**
+ * Returns the page size at the specified index number.
+ *
+ * @discussion Indexes are zero based. This method raises an exception if index is out of bounds.
+ */
+- (CGSize)pageSizeAtIndex:(NSUInteger)index;
+
+/**
+ * Returns a CPDFPage object representing the page at index.
+ *
+ * @discussion Indexes are zero based. This method raises an exception if index is out of bounds.
+ */
+- (CPDFPage *)pageAtIndex:(NSUInteger)index;
+
+/**
+ * Gets the index number for the specified page.
+ *
+ * @discussion Given a CPDFPage, returns the pages index within the document. Indices are zero-based.
+ */
+- (NSUInteger)indexForPage:(CPDFPage *)page;
+
+/**
+ * Inserts a blank page at the specified index point.
+ *
+ * @discussion Indexes are zero based. The index must lie within bounds, or be equal to the length of bounds.
+ */
+- (BOOL)insertPage:(CGSize)pageSize atIndex:(NSUInteger)index;
+/**
+ * Inserts a blank page with image at the specified index point.
+ *
+ * @discussion Indexes are zero based. The index must lie within bounds, or be equal to the length of bounds.
+ */
+- (BOOL)insertPage:(CGSize)pageSize withImage:(NSString *)imagePath atIndex:(NSUInteger)index;
+/**
+ * Removes page(s) at the specified index set.
+ */
+- (BOOL)removePageAtIndexSet:(NSIndexSet *)indexSet;
+/**
+ * Move one page to another.
+ *
+ * @discussion This method raises an exception if either index value is out of bounds.
+ */
+- (BOOL)movePageAtIndex:(NSUInteger)indexA withPageAtIndex:(NSUInteger)indexB;
+/**
+ * Exchanges one page with another.
+ *
+ * @discussion This method raises an exception if either index value is out of bounds.
+ */
+- (BOOL)exchangePageAtIndex:(NSUInteger)indexA withPageAtIndex:(NSUInteger)indexB;
+/**
+ * Import page(s) from another document at the specified index point.
+ *
+ * @discussion This method raises an exception if either index value is out of bounds.
+ */
+- (BOOL)importPages:(NSIndexSet *)indexSet fromDocument:(CPDFDocument *)document atIndex:(NSUInteger)index;
+
+#pragma mark - Annotations
+
+/**
+ * Export annotation to XFDF document.
+ */
+- (BOOL)exportAnnotationToXFDFPath:(NSString *)xfdfPath;
+/**
+ * Import annotations from XFDF document.
+ */
+- (BOOL)importAnnotationFromXFDFPath:(NSString *)xfdfPath;
+
+/**
+ * Remove all signatures.
+ */
+- (BOOL)removeAllSignature;
+
+/**
+ * A Boolean value indicating whether the document contains annotations.
+ */
+- (BOOL)hasAnnotations;
+
+/**
+ * Reset all forms in PDF document.
+ */
+- (void)resetForm;
+
+#pragma mark - Extract
+
+/**
+ * Extract image at the specified index set.
+ */
+- (NSUInteger)extractImageFromPages:(NSIndexSet *)indexSet toPath:(NSString *)path;
+
+/**
+ * Cancels a extract initiated with extractImageFromPages:toPath:.
+ */
+- (void)cancelExtractImage;
+
+#pragma mark - Summary
+
+- (NSString *)summaryHTML;
+
+#pragma mark - PDF/A
+
+/**
+ * Gets PDF/A conformance levels.
+ *
+ * @see CPDFType
+ */
+- (CPDFType)type;
+
+/**
+ * Converts existing PDF files to PDF/A compliant documents, including PDF/A-1a and PDF/A-1b only.
+ *
+ * @discussion The conversion option analyzes the content of existing PDF files and performs a sequence of modifications in order to produce a PDF/A compliant document.
+ * Features that are not suitable for long-term archiving (such as encryption, obsolete compression schemes, missing fonts, or device-dependent color) are replaced with their PDF/A compliant equivalents.
+ * Because the conversion process applies only necessary changes to the source file, the information loss is minimal.
+ * @see CPDFType
+ */
+- (BOOL)writePDFAToURL:(NSURL *)url withType:(CPDFType)type;
+
+#pragma mark - Find
+
+/**
+ * Returns a Boolean value indicating whether an asynchronous find operation is in progress.
+ */
+@property (nonatomic,readonly) BOOL isFinding;
+
+/**
+ * Synchronously finds all instances of the specified string in the document.
+ *
+ * @discussion Each hit gets added to an NSArray object as a CPDFSelection object. If there are no hits, this method returns an empty array.
+ * Use this method when the complete search process will be brief and when you don’t need the flexibility or control offered by beginFindString:withOptions:.
+ * @see CPDFSearchOptions
+ */
+- (NSArray<NSArray<CPDFSelection *> *> *)findString:(NSString *)string withOptions:(CPDFSearchOptions)options;
+
+/**
+ * Asynchronously finds all instances of the specified string in the document.
+ *
+ * @discussion This method returns immediately. It causes delegate methods to be called when searching begins and ends, on each search hit, and when the search proceeds to a new page.
+ * @see CPDFDocumentDelegate
+ */
+- (void)beginFindString:(NSString *)string withOptions:(CPDFSearchOptions)options;
+
+/**
+ * Cancels a search initiated with beginFindString:withOptions:.
+ */
+- (void)cancelFindString;
+
+#pragma mark - Redact
+
+/**
+ * Applies redaction annotations in the document.
+ */
+- (void)applyRedactions;
+
+@end
+
+/**
+ * The delegate for the CPDFDocument object.
+ */
+@protocol CPDFDocumentDelegate <NSObject>
+
+@optional
+
+/**
+ * Called when the beginFindString:withOptions: or findString:withOptions: method begins finding.
+ */
+- (void)documentDidBeginDocumentFind:(CPDFDocument *)document;
+/**
+ * Called when the beginFindString:withOptions: or findString:withOptions: method returns.
+ */
+- (void)documentDidEndDocumentFind:(CPDFDocument *)document;
+/**
+ * Called when a find operation begins working on a new page of a document.
+ */
+- (void)documentDidBeginPageFind:(CPDFDocument *)document pageAtIndex:(NSUInteger)index;
+/**
+ * Called when a find operation finishes working on a page in a document.
+ */
+- (void)documentDidEndPageFind:(CPDFDocument *)document pageAtIndex:(NSUInteger)index;
+/**
+ * Called when a string match is found in a document.
+ *
+ * @discussion To determine the string selection found, use the selection.
+ */
+- (void)documentDidFindMatch:(CPDFSelection *)selection;
+
+@end

+ 39 - 0
ComPDFKit.framework/Headers/CPDFFreeTextAnnotation.h

@@ -0,0 +1,39 @@
+//
+//  CPDFFreeTextAnnotation.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFAnnotation.h>
+
+/**
+ * A CPDFFreeTextAnnotation object displays text on a page.
+ *
+ * @discussion The CPDFAnnotation class’s contents and setContents: methods let you get and set the textual content for a CPDFFreeTextAnnotation object.
+ */
+@interface CPDFFreeTextAnnotation : CPDFAnnotation
+
+/**
+ * Method to get / set the font used for the annotation’s text field.
+ */
+@property (nonatomic,retain) CPDFKitPlatformFont *font;
+
+/**
+ * Method to get / set the font color used in the text field of the annotation.
+ */
+@property (nonatomic,retain) CPDFKitPlatformColor *fontColor;
+
+/**
+ * Method to get / set the horizontal alignment of text within the bounds of the annotation.
+ *
+ * @discussion Supported values are NSLeftTextAlignment, NSRightTextAlignment, and NSCenterTextAlignment.
+ */
+@property (nonatomic,assign) NSTextAlignment alignment;
+
+@end

+ 40 - 0
ComPDFKit.framework/Headers/CPDFGoToAction.h

@@ -0,0 +1,40 @@
+//
+//  CPDFGoToAction.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFAction.h>
+
+@class CPDFDestination;
+
+/**
+ * CPDFGoToAction, a subclass of CPDFAction, defines methods for getting and setting the destination of a go-to action.
+ *
+ * @discussion A CPDFGoToAction object represents the action of going to a specific location within the PDF document.
+ */
+@interface CPDFGoToAction : CPDFAction
+
+#pragma mark - Initializers
+
+/**
+ * Initializes the go-to action.
+ *
+ * @param destination The destination with which to initialize the go-to action.
+ */
+- (instancetype)initWithDestination:(CPDFDestination *)destination NS_DESIGNATED_INITIALIZER;
+
+#pragma mark - Accessors
+
+/**
+ * Returns the destination associated with the action.
+ */
+- (CPDFDestination *)destination;
+
+@end

+ 77 - 0
ComPDFKit.framework/Headers/CPDFHeaderFooter.h

@@ -0,0 +1,77 @@
+//
+//  CPDFHeaderFooter.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFKitPlatform.h>
+
+/**
+ * Adds and removes the header & footer.
+ */
+@interface CPDFHeaderFooter : NSObject
+
+#pragma mark - Accessors
+
+/**
+ * Method to get / set the page range of the header & footer by string, such as "0,3,5-7".
+ */
+@property (nonatomic,retain) NSString *pageString;
+
+/**
+ * Method to get / set the margins of the header & footer.
+ */
+@property (nonatomic,assign) CPDFKitPlatformEdgeInsets margin;
+
+/**
+ * Gets the text of the header & footer at the specified index.
+ */
+- (NSString *)textAtIndex:(NSUInteger)index;
+/**
+ * Sets the text of the header & footer at the specified index.
+ */
+- (void)setText:(NSString *)text atIndex:(NSUInteger)index;
+
+/**
+ * Gets the font color of the header & footer at the specified index.
+ */
+- (CPDFKitPlatformColor *)textColorAtIndex:(NSUInteger)index;
+/**
+ * Sets the font color of the header & footer at the specified index.
+ */
+- (void)setTextColor:(CPDFKitPlatformColor *)color atIndex:(NSUInteger)index;
+
+/**
+ * Gets the font size of the header & footer at the specified index.
+ */
+- (CGFloat)fontSizeAtIndex:(NSUInteger)index;
+/**
+ * Sets the font size of the header & footer at the specified index.
+ */
+- (void)setFontSize:(CGFloat)fontSize atIndex:(NSUInteger)index;
+
+/**
+ * Gets the font name of the header & footer at the specified index.
+ */
+- (NSString *)fontNameAtIndex:(NSUInteger)index;
+/**
+ * Sets the font name of the header & footer at the specified index.
+ */
+- (void)setFontName:(NSString *)fontName atIndex:(NSUInteger)index;
+
+/**
+ * Updates the header & footer.
+ */
+- (void)update;
+/**
+ * Removes the header & footer.
+ */
+- (void)clear;
+
+@end

+ 28 - 0
ComPDFKit.framework/Headers/CPDFInkAnnotation.h

@@ -0,0 +1,28 @@
+//
+//  CPDFInkAnnotation.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFAnnotation.h>
+
+/**
+ * A CPDFInkAnnotation object displays one or more disjoint paths on a page. This is typically used to represent a freehand jotting or “scribble” of handwritten text.
+ *
+ * @discussion The setBorderWidth: method of the CPDFAnnotation class determines the stroke thickness.
+ * The setColor: method of the CPDFAnnotation class determines the stroke color.
+ */
+@interface CPDFInkAnnotation : CPDFAnnotation
+
+/**
+ * Method to get / set an array containing the points that make up an annotation.
+ */
+@property (nonatomic,retain) NSArray<NSArray *> *paths;
+
+@end

+ 83 - 0
ComPDFKit.framework/Headers/CPDFKit.h

@@ -0,0 +1,83 @@
+//
+//  CPDFKit.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <Foundation/Foundation.h>
+
+typedef NS_ENUM(NSInteger, CPDFKitFeatureType) {
+    CPDFKitFeatureViewerOutline,
+    CPDFKitFeatureViewerBookmark,
+    CPDFKitFeatureViewerRender,
+    CPDFKitFeatureViewerSearch,
+    CPDFKitFeatureAnnotationNote,
+    CPDFKitFeatureAnnotationLink,
+    CPDFKitFeatureAnnotationFreeText,
+    CPDFKitFeatureAnnotationShape,
+    CPDFKitFeatureAnnotationMarkup,
+    CPDFKitFeatureAnnotationStandardStamp,
+    CPDFKitFeatureAnnotationCustomizedStamp,
+    CPDFKitFeatureAnnotationInk,
+    CPDFKitFeatureAnnotationSound,
+    CPDFKitFeatureAnnotationDelete,
+    CPDFKitFeatureAnnotationFlatten,
+    CPDFKitFeatureAnnotationXFDF,
+    CPDFKitFeatureForm,
+    CPDFKitFeatureFormFill,
+    CPDFKitFeatureEditorPage,
+    CPDFKitFeatureEditorExtract,
+    CPDFKitFeatureEditorInfo,
+    CPDFKitFeatureEditorConvert,
+    CPDFKitFeatureSecurityEncrypt,
+    CPDFKitFeatureSecurityDecrypt,
+    CPDFKitFeatureSecurityWatermark,
+    CPDFKitFeatureConversionPDFA
+};
+
+@interface CPDFKit : NSObject
+
+/**
+ * The shared ComPDFKit instance.
+ */
++ (instancetype)sharedInstance;
+
+/**
+ * Activate ComPDFKit with your license key and secret.
+ */
++ (void)setLicenseKey:(NSString *)licenseKey secret:(NSString *)licenseSecret;
+
+/**
+ * Returns the full ComPDFKit product version string. (e.g. "ComPDFKit 1.0.1 for iOS (101)")
+ */
+@property(atomic,readonly) NSString *versionString;
+
+/**
+ * Returns just the framework version. (e.g. 1.0.1)
+ */
+@property(atomic,readonly) NSString *versionNumber;
+
+/**
+ * The internal build number. Increments with every version.
+ */
+@property(atomic,readonly) NSUInteger buildNumber;
+
+/**
+ * Whether to allow to use specified features.
+ *
+ * @see CPDFKitFeatureType
+ */
+- (BOOL)allowsFeature:(CPDFKitFeatureType)type;
+
+/**
+ * Convert files (doc, docx, xls, xlsx, ppt, pptx, txt, jpeg, and png) to PDF.
+ */
+- (void)convertFilePath:(NSString *)filePath toPath:(NSString *)pdfFilePath completion:(void (^)(BOOL result))completion;
+
+@end

+ 235 - 0
ComPDFKit.framework/Headers/CPDFKitConfig.h

@@ -0,0 +1,235 @@
+//
+//  CPDFKitConfig.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <Foundation/Foundation.h>
+#import <ComPDFKit/CPDFKitPlatform.h>
+#import <ComPDFKit/CPDFView.h>
+
+#define CPDFKitShareConfig [CPDFKitConfig sharedInstance]
+
+@interface CPDFKitConfig : NSObject
+
+/**
+ * The shared CPDFKitConfig configuration instance.
+ */
++ (instancetype)sharedInstance;
+
+/**
+ * Get the cache size.
+ */
+- (unsigned long long)cacheSize;
+/**
+ * Clear the cache.
+ */
+- (void)clearCache;
+
+/**
+ * Get the default view mode of CPDFView.
+ * View Mode : Horizontally, Vertically
+ *
+ * @see CPDFDisplayDirection
+ */
+- (CPDFDisplayDirection)displayDirection;
+/**
+ * Set the default view mode of CPDFView.
+ *
+ * @see CPDFDisplayDirection
+ */
+- (void)setDisplayDirection:(CPDFDisplayDirection)displayDirection;
+
+/**
+ * Get the default reading mode of CPDFView.
+ * Reading Mode : Night, Soft, Green, Other
+ *
+ * @see CPDFDisplayMode
+ */
+- (CPDFDisplayMode)displayMode;
+/**
+ * Set the default reading mode of CPDFView.
+ *
+ * @see CPDFDisplayMode
+ */
+- (void)setDisplayMode:(CPDFDisplayMode)displayMode;
+
+/**
+ * Get a custom background color for the rendered mode of CPDFView.
+ */
+- (CPDFKitPlatformColor *)displayModeCustomColor;
+/**
+ * Set a custom background color for the rendered mode of CPDFView.
+ */
+- (void)setDisplayModeCustomColor:(CPDFKitPlatformColor *)displayModeCustomColor;
+
+/**
+ * Get whether to allow to highlight link field in the CPDFView.
+ */
+- (BOOL)enableLinkFieldHighlight;
+/**
+ * Set whether to allow to highlight link field in the CPDFView.
+ */
+- (void)setEnableLinkFieldHighlight:(BOOL)enableLinkFieldHighlight;
+
+/**
+ * Get whether to allow to highlight form field in the CPDFView.
+ */
+- (BOOL)enableFormFieldHighlight;
+/**
+ * Set whether to allow to highlight form field in the CPDFView.
+ */
+- (void)setEnableFormFieldHighlight:(BOOL)enableFormFieldHighlight;
+
+/**
+ * Get whether to allow annotation rotation.
+ */
+- (BOOL)enableAnnotationNoRotate;
+/**
+ * If set, do not rotate the annotation’s appearance to match the rotation of the page.
+ * The upper-left corner of the annotation rectangle shall remain in a fixed location on the page, regardless of the page rotation.
+ */
+- (void)setEnableAnnotationNoRotate:(BOOL)enableAnnotationNoRotate;
+
+/**
+ * Get the default author of annotations.
+ */
+- (NSString *)annotationAuthor;
+/**
+ * Set the default author of annotations.
+ */
+- (void)setAnnotationAuthor:(NSString *)annotationAuthor;
+
+/**
+ * Get whether to allow to add freehand annotation by PencilKit.
+ */
+- (BOOL)enableFreehandPencilKit;
+/**
+ * Set whether to allow to add annotation by PencilKit.
+ */
+- (void)setEnableFreehandPencilKit:(BOOL)enableFreehandPencilKit;
+
+/**
+ * Get the default color of highlight annotations.
+ */
+- (CPDFKitPlatformColor *)highlightAnnotationColor;
+/**
+ * Set the default color of highlight annotations.
+ */
+- (void)setHighlightAnnotationColor:(CPDFKitPlatformColor *)highlightAnnotationColor;
+
+/**
+ * Get the default color of underline annotations.
+ */
+- (CPDFKitPlatformColor *)underlineAnnotationColor;
+/**
+ * Set the default color of underline annotations.
+ */
+- (void)setUnderlineAnnotationColor:(CPDFKitPlatformColor *)underlineAnnotationColor;
+
+/**
+ * Get the default color of strikeout annotations.
+ */
+- (CPDFKitPlatformColor *)strikeoutAnnotationColor;
+/**
+ * Set the default color of strikeout annotations.
+ */
+- (void)setStrikeoutAnnotationColor:(CPDFKitPlatformColor *)strikeoutAnnotationColor;
+
+/**
+ * Get the default color of squiggly annotations.
+ */
+- (CPDFKitPlatformColor *)squigglyAnnotationColor;
+/**
+ * Set the default color of squiggly annotations.
+ */
+- (void)setSquigglyAnnotationColor:(CPDFKitPlatformColor *)squigglyAnnotationColor;
+
+/**
+ * Get the default opacity of markup annotations.
+ */
+- (CGFloat)markupAnnotationOpacity;
+/**
+ * Set the default opacity of markup annotations.
+ */
+- (void)setMarkupAnnotationOpacity:(CGFloat)markupAnnotationOpacity;
+
+/**
+ * Get the default color of shape annotations.
+ */
+- (CPDFKitPlatformColor *)shapeAnnotationColor;
+/**
+ * Set the default color of shape annotations.
+ */
+- (void)setShapeAnnotationColor:(CPDFKitPlatformColor *)shapeAnnotationColor;
+
+/**
+ * Get the default interior color of shape annotations.
+ */
+- (CPDFKitPlatformColor *)shapeAnnotationInteriorColor;
+/**
+ * Set the default interior color of shape annotations.
+ */
+- (void)setShapeAnnotationInteriorColor:(CPDFKitPlatformColor *)shapeAnnotationInteriorColor;
+
+/**
+ * Get the default opacity of shape annotations.
+ */
+- (CGFloat)shapeAnnotationOpacity;
+/**
+ * Set the default opacity of shape annotations.
+ */
+- (void)setShapeAnnotationOpacity:(CGFloat)shapeAnnotationOpacity;
+
+/**
+ * Get the default interior opacity of shape annotations.
+ */
+- (CGFloat)shapeAnnotationInteriorOpacity;
+/**
+ * Set the default interior opacity of shape annotations.
+ */
+- (void)setShapeAnnotationInteriorOpacity:(CGFloat)shapeAnnotationInteriorOpacity;
+
+/**
+ * Get the default border width of shape annotations.
+ */
+- (CGFloat)shapeAnnotationBorderWidth;
+/**
+ * Set the default border width of shape annotations.
+ */
+- (void)setShapeAnnotationBorderWidth:(CGFloat)shapeAnnotationBorderWidth;
+
+/**
+ * Get the default color of freehand annotations.
+ */
+- (CPDFKitPlatformColor *)freehandAnnotationColor;
+/**
+ * Set the default color of freehand annotations.
+ */
+- (void)setFreehandAnnotationColor:(CPDFKitPlatformColor *)freehandAnnotationColor;
+
+/**
+ * Get the default opacity of freehand annotations.
+ */
+- (CGFloat)freehandAnnotationOpacity;
+/**
+ * Set the default opacity of freehand annotations.
+ */
+- (void)setFreehandAnnotationOpacity:(CGFloat)freehandAnnotationOpacity;
+
+/**
+ * Get the default border width of freehand annotations.
+ */
+- (CGFloat)freehandAnnotationBorderWidth;
+/**
+ * Set the default border width of freehand annotations.
+ */
+- (void)setFreehandAnnotationBorderWidth:(CGFloat)freehandAnnotationBorderWidth;
+
+@end

+ 39 - 0
ComPDFKit.framework/Headers/CPDFKitPlatform.h

@@ -0,0 +1,39 @@
+//
+//  CPDFKitPlatform.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#ifndef CPDFKitPlatform_h
+#define CPDFKitPlatform_h
+
+#import <Foundation/Foundation.h>
+#import <CoreGraphics/CoreGraphics.h>
+
+#if TARGET_OS_IPHONE
+
+#import <UIKit/UIKit.h>
+
+#define CPDFKitPlatformColor        UIColor
+#define CPDFKitPlatformImage        UIImage
+#define CPDFKitPlatformFont         UIFont
+#define CPDFKitPlatformEdgeInsets   UIEdgeInsets
+
+#elif TARGET_OS_MAC
+
+#import <Cocoa/Cocoa.h>
+
+#define CPDFKitPlatformColor        NSColor
+#define CPDFKitPlatformImage        NSImage
+#define CPDFKitPlatformFont         NSFont
+#define CPDFKitPlatformEdgeInsets   NSEdgeInsets
+
+#endif
+
+#endif /* CPDFKitPlatform_h */

+ 80 - 0
ComPDFKit.framework/Headers/CPDFLineAnnotation.h

@@ -0,0 +1,80 @@
+//
+//  CPDFLineAnnotation.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFAnnotation.h>
+
+/**
+ * The following constants specify the available line ending styles.
+ */
+typedef NS_ENUM(NSInteger, CPDFLineStyle) {
+    /** No line ending. */
+    CPDFLineStyleNone = 0,
+    /** An open arrowhead line ending, composed from two short lines meeting in an acute angle at the line end. */
+    CPDFLineStyleOpenArrow = 1,
+    /** A closed arrowhead line ending, consisting of a triangle with the acute vertex at the line end and filled with the annotation’s interior color, if any. */
+    CPDFLineStyleClosedArrow = 2,
+    /** A square line ending filled with the annotation’s interior color, if any. */
+    CPDFLineStyleSquare = 3,
+    /** A circular line ending filled with the annotation’s interior color, if any. */
+    CPDFLineStyleCircle = 4,
+    /** A diamond-shaped line ending filled with the annotation’s interior color, if any. */
+    CPDFLineStyleDiamond = 5
+};
+
+/**
+ * A PDFAnnotationLine object displays a single line on a page.
+ *
+ * @discussion The setBorderWidth: method of the CPDFAnnotation class determines the stroke thickness.
+ * The setColor: method of the CPDFAnnotation class determines the stroke color.
+ */
+@interface CPDFLineAnnotation : CPDFAnnotation
+
+/**
+ * Method to get / set the starting point for the line, in page space.
+ *
+ * @discussion Page space is a coordinate system with the origin at the lower-left corner of the current page.
+ */
+@property (nonatomic,assign) CGPoint startPoint;
+/**
+ * Method to get / set the ending point for the line in page space.
+ *
+ * @discussion Page space is a coordinate system with the origin at the lower-left corner of the current page.
+ */
+@property (nonatomic,assign) CGPoint endPoint;
+
+/**
+ * Method to get / set the line ending style for the starting point of the line.
+ *
+ * @see CPDFLineStyle
+ */
+@property (nonatomic,assign) CPDFLineStyle startLineStyle;
+/**
+ * Method to get / set the line ending style for the ending point of the line.
+ *
+ * @see CPDFLineStyle
+ */
+@property (nonatomic,assign) CPDFLineStyle endLineStyle;
+
+/**
+ * Method to get / set the opacity used to fill the ornament at the ends of the line.
+ *
+ * @discussion The ornament at the end of a line is optional (for more information, see the Adobe PDF Specification 1.4).
+ */
+@property (nonatomic,assign) CGFloat interiorOpacity;
+/**
+ * Method to get / set the color used to fill the ornament at the ends of the line.
+ *
+ * @discussion The ornament at the end of a line is optional (for more information, see the Adobe PDF Specification 1.4).
+ */
+@property (nonatomic,retain) CPDFKitPlatformColor *interiorColor;
+
+@end

+ 38 - 0
ComPDFKit.framework/Headers/CPDFLinkAnnotation.h

@@ -0,0 +1,38 @@
+//
+//  CPDFAnnotationLink.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFAnnotation.h>
+
+@class CPDFDestination;
+
+/**
+ * A CPDFLinkAnnotation object represents either a hypertext link to another location in the document (specified as a CPDFDestination object) or a URL.
+ */
+@interface CPDFLinkAnnotation : CPDFAnnotation
+
+/**
+ * Gets the destination for the link when the destination was specified as a CPDFDestination object.
+ *
+ * @discussion Destination for the link. May be nil if no destination associated with link; in this case the -[URL] may be valid.
+ */
+- (CPDFDestination *)destination;
+- (void)setDestination:(CPDFDestination *)destination;
+
+/**
+ * Gets the destination for the link when the destination was specified as a URL.
+ *
+ * @discussion URL for the link. May be nil if no URL action associated with link; in this case the -[destination] may be valid.
+ */
+- (NSString *)URL;
+- (void)setURL:(NSString *)url;
+
+@end

+ 58 - 0
ComPDFKit.framework/Headers/CPDFMarkupAnnotation.h

@@ -0,0 +1,58 @@
+//
+//  CPDFAnnotationMarkup.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFAnnotation.h>
+
+typedef NS_ENUM(NSInteger, CPDFMarkupType) {
+    CPDFMarkupTypeHighlight = 0,
+    CPDFMarkupTypeStrikeOut = 1,
+    CPDFMarkupTypeUnderline = 2,
+    CPDFMarkupTypeSquiggly = 3
+};
+
+/**
+ * A CPDFMarkupAnnotation object appears as highlighting, underlining, strikethrough, or a squiggly style applied to the text of a document.
+ */
+@interface CPDFMarkupAnnotation : CPDFAnnotation
+
+/**
+ * Initializes CPDFMarkupAnnotation object.
+ *
+ * @see CPDFMarkupType
+ */
+- (instancetype)initWithDocument:(CPDFDocument *)document markupType:(CPDFMarkupType)markupType;
+
+/**
+ * Method to get / set the array of quadrilateral points defining the bounds of the markup.
+ *
+ * @discussion Array of (n * 4) NSPoints defining n quadrilaterals in page space where n is the number of quad points.
+ * The points for each quad are ordered in a 'Z' pattern. That is, the first point should represent the upper left point representing the start of the marked-up text,
+ * the next point will be the upper right, the third point will represent the lower left of the text and the last point the lower right.
+ * Page space is a coordinate system with the origin at the lower-left corner of the current page.
+ */
+@property (nonatomic,retain) NSArray *quadrilateralPoints;
+
+/**
+ * Gets the markup style.
+ *
+ * @see CPDFMarkupType
+ */
+- (CPDFMarkupType)markupType;
+
+- (NSString *)markupText;
+- (void)setMarkupText:(NSString *)text;
+
+- (BOOL)popup;
+- (void)createPopup;
+- (void)removePopup;
+
+@end

+ 22 - 0
ComPDFKit.framework/Headers/CPDFMovieAnnotation.h

@@ -0,0 +1,22 @@
+//
+//  CPDFMovieAnnotation.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFAnnotation.h>
+
+/**
+ * A CPDFMovieAnnotation object contains animated graphics and sound to be presented on the computer screen and through the speakers.
+ */
+@interface CPDFMovieAnnotation : CPDFAnnotation
+
+- (NSString *)mediaPath;
+
+@end

+ 42 - 0
ComPDFKit.framework/Headers/CPDFNamedAction.h

@@ -0,0 +1,42 @@
+//
+//  CPDFNamedAction.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFAction.h>
+
+typedef NS_ENUM(NSInteger, CPDFNamedActionName) {
+    CPDFNamedActionNone = 0,
+    CPDFNamedActionNextPage = 1,
+    CPDFNamedActionPreviousPage = 2,
+    CPDFNamedActionFirstPage = 3,
+    CPDFNamedActionLastPage = 4,
+    CPDFNamedActionPrint = 5
+};
+
+/**
+ * CPDFNamedAction defines methods used to work with actions in PDF documents, some of which are named in the Adobe PDF Specification.
+ *
+ * @discussion A CPDFNamedAction object represents an action with a defined name.
+ */
+@interface CPDFNamedAction : CPDFAction
+
+- (instancetype)initWithName:(CPDFNamedActionName)name NS_DESIGNATED_INITIALIZER;
+
+#pragma mark - Accessors
+
+/**
+ * Returns the name of the named action.
+ *
+ * @see CPDFNamedActionName
+ */
+- (CPDFNamedActionName)name;
+
+@end

+ 104 - 0
ComPDFKit.framework/Headers/CPDFOutline.h

@@ -0,0 +1,104 @@
+//
+//  CPDFOutline.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFKitPlatform.h>
+
+@class CPDFDocument, CPDFDestination, CPDFAction;
+
+/**
+ * A CPDFOutline object is an element in a tree-structured hierarchy that can represent the structure of a PDF document.
+ *
+ * @discussion An outline is an optional component of a PDF document, useful for viewing the structure of the document and for navigating within it.
+ * Outlines are created by the document’s author. If you represent a PDF document outline using outline objects, the root of the hierarchy is obtained from the PDF document itself.
+ * This root outline is not visible and serves merely as a container for the visible outlines.
+ */
+@interface CPDFOutline : NSObject
+
+#pragma mark - Accessors
+
+/**
+ * Returns the document with which the outline is associated.
+ */
+@property (nonatomic,readonly) CPDFDocument *document;
+
+/**
+ * Returns the parent outline object of the outline (returns NULL if called on the root outline object).
+ */
+@property (nonatomic,readonly) CPDFOutline *parent;
+
+/**
+ * Returns the number of child outline objects in the outline.
+ */
+@property (nonatomic,readonly) NSUInteger numberOfChildren;
+
+/**
+ * Returns the index of the outline item, relative to its siblings (and from the perspective of the parent).
+ *
+ * @discussion The root outline item (or any item with no parent) is always index 0.
+ */
+@property (nonatomic,readonly) NSUInteger index;
+
+/**
+ * Method to get / set the label for the outline.
+ *
+ * @discussion The root outline serves only as a container for the outlines it owns; it does not have a label.
+ */
+@property (nonatomic,retain) NSString *label;
+
+/**
+ * Method to get / set the destination associated with the outline.
+ *
+ * @discussion The root outline serves only as a container for the outlines it owns; it does not have a destination.
+ * Note that a CPDFOutline object can have either a destination or an action, not both.
+ * This method may return NULL if the outline has an associated action instead of a destination.
+ * Note that if the associated action is a CPDFGoToAction, this method returns the destination from the CPDFGoToAction object.
+ * However, it is better to use the action method for this purpose.
+ */
+@property (nonatomic,retain) CPDFDestination *destination;
+
+/**
+ * Method to get / set the action performed when users click the outline.
+ *
+ * @discussion The root outline serves only as a container for the outlines it owns; it does not have an action.
+ * Note that a CPDFOutline object can have either an action or a destination, not both.
+ * If the CPDFOutline object has a destination, instead of an action, action returns a CPDFGoToAction object (this is equivalent to calling destination on the CPDFOutline object).
+ * For other action types, action returns the appropriate PDF Kit action type object, such as CPDFURLAction.
+ */
+@property (nonatomic,retain) CPDFAction *action;
+
+/**
+ * Returns the child outline object at the specified index.
+ *
+ * @discussion The index is zero-based. This method throws an exception if index is out of range.
+ * A PDFOutline object retains all its children, so childAtIndex: returns the same retained child outline object every time it’s called.
+ * This means that you do not need to retain the object returned by childAtIndex:.
+ */
+- (CPDFOutline *)childAtIndex:(NSUInteger)index;
+
+/**
+ * Create a outline object and inserts the outline object at the specified index.
+ *
+ * @discussion To build a PDF outline hierarchy, use this method to add child outline objects.
+ */
+- (CPDFOutline *)insertChildAtIndex:(NSUInteger)index;
+
+/**
+ * @discussion When moving items around within an outline hierarchy, you should retain the item and call -[removeFromParent] first.
+ */
+- (void)insertChild:(CPDFOutline *)child atIndex:(NSUInteger)index;
+
+/**
+ * Removes the outline object from its parent.
+ */
+- (void)removeFromParent;
+
+@end

+ 192 - 0
ComPDFKit.framework/Headers/CPDFPage.h

@@ -0,0 +1,192 @@
+//
+//  CPDFPage.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFKitPlatform.h>
+
+/**
+ * The following box types may be used with CPDFPage drawing and bounds-setting methods.
+ * See the Adobe PDF Specification for more information on box types, units, and coordinate systems.
+ */
+typedef NS_ENUM(NSInteger, CPDFDisplayBox) {
+    /** A rectangle defining the boundaries of the physical medium for display or printing, expressed in default user-space units. */
+    CPDFDisplayMediaBox = 0,
+    /** A rectangle defining the boundaries of the visible region , expressed in default user-space units. Default value equal to CPDFDisplayMediaBox. */
+    CPDFDisplayCropBox = 1,
+    /** A rectangle defining the boundaries of the clip region for the page contents in a production environment. Default value equal to CPDFDisplayCropBox. */
+    CPDFDisplayBleedBox = 2,
+    /** A rectangle defining the intended boundaries of the finished page. Default value equal to CPDFDisplayCropBox. */
+    CPDFDisplayTrimBox = 3,
+    /** A rectangle defining the boundaries of the page’s meaningful content including surrounding white space intended for display. Default value equal to CPDFDisplayCropBox. */
+    CPDFDisplayArtBox = 4
+};
+
+@class CPDFDocument, CPDFAnnotation, CPDFSelection;
+
+/**
+ * CPDFPage, a subclass of NSObject, defines methods used to render PDF pages and work with annotations, text, and selections.
+ *
+ * @discussion CPDFPage is a logical representation of a PDF document's page. Your application instantiates a CPDFPage object by asking for one from a CPDFDocument object.
+ * For simple display and navigation of PDF documents within your application, you don’t need to use CPDFPage. You need only use CPDFView.
+ */
+@interface CPDFPage : NSObject
+
+#pragma mark - Accessors
+
+/**
+ * Returns the CPDFDocument object with which the page is associated.
+ */
+@property (nonatomic,readonly) CPDFDocument *document;
+
+/**
+ * Returns the label for the page.
+ *
+ * @discussion Typically, the label is “1” for the first page, “2” for the second page, and so on, but nonnumerical labels are also possible (such as “xxi”, “4-1” and so on).
+ */
+@property (nonatomic,readonly) NSString *label;
+
+/**
+ * Returns the bounds for the specified PDF display box.
+ *
+ * @see CPDFDisplayBox
+ */
+- (CGRect)boundsForBox:(CPDFDisplayBox)box;
+
+/**
+ * Sets the bounds for the specified box.
+ *
+ * @discussion If the box does not exist, this method creates it for you.
+ * @see CPDFDisplayBox
+ */
+- (void)setBounds:(CGRect)bounds forBox:(CPDFDisplayBox)box;
+
+/**
+ * Sets the rotation angle for the page in degrees.
+ *
+ * @discussion Rotation on a page. Must be 0, 90, 180 or 270 (negative rotations will be "normalized" to one of 0, 90, 180 or 270).
+ * Some PDF's have an inherent rotation and so -[rotation] may be non-zero when a PDF is first opened.
+ */
+@property (nonatomic,assign) NSInteger rotation;
+
+@property (nonatomic,readonly) CGRect bounds;
+
+/**
+ * Returns the size of page after rotation.
+ */
+@property (nonatomic,readonly) CGSize size;
+
+#pragma mark - Annotations
+
+/**
+ * Returns an array containing the page’s annotations.
+ *
+ * @discussion The elements of the array will most likely be typed to subclasses of the CPDFAnnotation class.
+ */
+@property (nonatomic,readonly) NSArray<CPDFAnnotation *> *annotations;
+
+/**
+ * Adds the specified annotation object to the page.
+ */
+- (void)addAnnotation:(CPDFAnnotation *)annotation;
+/**
+ * Removes the specified annotation from the page.
+ */
+- (void)removeAnnotation:(CPDFAnnotation *)annotation;
+/**
+ * Removes all annotations from the page.
+ */
+- (void)removeAllAnnotations;
+
+/**
+ * Returns the annotation, if there is one, at the specified point.
+ *
+ * @discussion Use this method for hit-testing based on the current cursor position. If more than one annotation shares the specified point,
+ * the frontmost (or topmost) one is returned (the annotations are searched in reverse order of their appearance in the PDF data file). Returns NULL if there is no annotation at point.
+ * Specify the point in page space. Page space is a coordinate system with the origin at the lower-left corner of the current page.
+ */
+- (CPDFAnnotation *)annotationAtPoint:(CGPoint)point;
+- (BOOL)annotation:(CPDFAnnotation *)annotation atPoint:(CGPoint)point;
+
+#pragma mark - Conversion
+
+/**
+ * This transform correctly rotates and offsets based on the given page's rotation property.
+ */
+- (CGAffineTransform)transform;
+
+#pragma mark - Rendering
+
+/**
+ * Convenience function that returns an image of this page, with annotations.
+ */
+- (CPDFKitPlatformImage *)thumbnailOfSize:(CGSize)size;
+
+#pragma mark - Text
+
+/**
+ * Returns the number of characters on the page, including whitespace characters.
+ *
+ * @discussion Number of characters on the page (including linefeeds and spaces inserted).
+ */
+@property (nonatomic,readonly) NSUInteger numberOfCharacters;
+
+/**
+ * Returns the bounds, in page space, of the character at the specified index.
+ *
+ * @discussion In the unlikely event that there is more than one character at the specified index point, only the bounds of the first character is returned.
+ * Page space is a coordinate system with the origin at the lower-left corner of the current page. Note that the bounds returned are not guaranteed to have integer coordinates.
+ */
+- (CGRect)characterBoundsAtIndex:(NSInteger)index;
+
+/**
+ * Returns the character index value for the specified point in page space.
+ *
+ * @discussion Returns the index of the first character if multiple characters are at this point. If there is no character at the specified point, the method returns -1.
+ * Page space is a coordinate system with the origin at the lower-left corner of the current page.
+ */
+- (NSInteger)characterIndexAtPoint:(CGPoint)point;
+
+/**
+ * Returns an NSString object representing the text on the page.
+ *
+ * @discussion String (with linefeeds and in some cases spaces inserted) representing the text on the page.
+ */
+@property (nonatomic,readonly) NSString *string;
+
+/**
+ * Returns the text enclosed within the specified rectangle, expressed in page coordinates.
+ *
+ * @discussion Given a rect in page-space, returns a selection representing enclosed text on page.
+ */
+- (NSString *)stringForRect:(CGRect)rect;
+
+/**
+ * Returns the text enclosed within the specified range.
+ */
+- (NSString *)stringForRange:(NSRange)range;
+
+#pragma mark - Selections
+
+/**
+ * Returns the text contained within the specified range.
+ *
+ * @discussion Given a range, returns a selection representing text within that range. Will clamp any range that goes out of bounds. Will return NULL for an empty selection.
+ */
+- (CPDFSelection *)selectionForRange:(NSRange)range;
+
+#pragma mark - Redact
+
+/**
+ * Applies redaction annotations in the page.
+ */
+- (void)applyRedactions;
+
+@end

+ 90 - 0
ComPDFKit.framework/Headers/CPDFRedactAnnotation.h

@@ -0,0 +1,90 @@
+//
+//  CPDFRedactAnnotation.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFAnnotation.h>
+
+/**
+ * Redaction annotations are used to remove content from a document.
+ */
+@interface CPDFRedactAnnotation : CPDFAnnotation
+
+@property(nonatomic,assign) BOOL drawRedactionsAsRedacted;
+
+/**
+ * Gets the areas that should be covered by the redaction annotation.
+ */
+- (NSArray *)quadrilateralPoints;
+/**
+ * Uses the quadrilateral points property to set the areas that should be covered by the redaction annotation.
+ */
+- (void)setQuadrilateralPoints:(NSArray *)points;
+
+/**
+ * Gets the fill color displayed in the specified area after applying the redaction. The color is drawn on the specified rect. Defaults to black.
+ */
+- (CPDFKitPlatformColor *)interiorColor;
+/**
+ * Sets the fill color displayed in the specified area after applying the redaction. The color is drawn on the specified rect. Defaults to black.
+ */
+- (void)setInteriorColor:(CPDFKitPlatformColor *)color;
+
+/**
+ * Gets the color used for the redaction’s border in its marked state. Defaults to red.
+ */
+- (CPDFKitPlatformColor *)borderColor;
+/**
+ * Sets the color used for the redaction’s border in its marked state. Defaults to red.
+ */
+- (void)setBorderColor:(CPDFKitPlatformColor *)color;
+
+/**
+ * Gets the text font displayed in the specified area after applying the redaction.
+ */
+- (CPDFKitPlatformFont *)font;
+/**
+ * Sets the text font displayed in the specified area after applying the redaction.
+ */
+- (void)setFont:(CPDFKitPlatformFont *)font;
+
+/**
+ * Gets the text color displayed in the specified area after applying the redaction.
+ */
+- (CPDFKitPlatformColor *)fontColor;
+/**
+ * Sets the text color displayed in the specified area after applying the redaction.
+ */
+- (void)setFontColor:(CPDFKitPlatformColor *)fontColor;
+
+/**
+ * Gets the text alignment displayed in the specified area after applying the redaction.
+ */
+- (NSTextAlignment)alignment;
+/**
+ * Sets the text alignment displayed in the specified area after applying the redaction.
+ */
+- (void)setAlignment:(NSTextAlignment)alignment;
+
+/**
+ * Gets the text displayed in the specified area after applying the redaction.
+ */
+- (NSString *)overlayText;
+/**
+ * Sets the text displayed in the specified area after applying the redaction.
+ */
+- (void)setOverlayText:(NSString *)text;
+
+/**
+ * Applies redaction annotation.
+ */
+- (void)applyRedaction;
+
+@end

+ 22 - 0
ComPDFKit.framework/Headers/CPDFResetFormAction.h

@@ -0,0 +1,22 @@
+//
+//  CPDFResetFormAction.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFAction.h>
+
+/**
+ * CPDFResetFormAction, a subclass of CPDFAction, defines methods for getting and clearing fields in a PDF form.
+ *
+ * @discussion A CPDFResetFormAction object represents an action associated with a PDF form.
+ */
+@interface CPDFResetFormAction : CPDFAction
+
+@end

+ 54 - 0
ComPDFKit.framework/Headers/CPDFSelection.h

@@ -0,0 +1,54 @@
+//
+//  CPDFSelection.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFKitPlatform.h>
+
+@class CPDFPage;
+
+/**
+ * A CPDFSelection object identifies a contiguous or noncontiguous selection of text in a PDF document.
+ */
+@interface CPDFSelection : NSObject
+
+#pragma mark - Accessors
+
+/**
+ * Returns the page where the selection is located.
+ */
+@property (nonatomic,readonly) CPDFPage *page;
+
+/**
+ * Returns the bounds of the selection on the page.
+ *
+ * @discussion The selection rectangle is given in page space. Page space is a coordinate system with the origin at the lower-left corner of the current page.
+ */
+@property (nonatomic,readonly) CGRect bounds;
+
+/**
+ * Returns a range of contiguous text on the page.
+ */
+@property (nonatomic,readonly) NSRange range;
+
+/**
+ * Returns an array of selections, one for each line of text covered by the receiver.
+ *
+ * @discussion If you call this method on a CPDFSelection object that represents a paragraph, for example,
+ * selectionsByLine returns an array that contains one CPDFSelection object for each line of text in the paragraph.
+ */
+@property (nonatomic,readonly) NSArray<CPDFSelection *> *selectionsByLine;
+
+/**
+ * Returns an NSString object representing the text contained in the selection (may contain linefeed characters).
+ */
+- (NSString *)string;
+
+@end

+ 21 - 0
ComPDFKit.framework/Headers/CPDFSignatureAnnotation.h

@@ -0,0 +1,21 @@
+//
+//  CPDFSignatureAnnotation.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFAnnotation.h>
+
+@interface CPDFSignatureAnnotation : CPDFAnnotation
+
+- (void)setImage:(CPDFKitPlatformImage *)image;
+
+- (void)signature;
+
+@end

+ 21 - 0
ComPDFKit.framework/Headers/CPDFSignatureWidgetAnnotation.h

@@ -0,0 +1,21 @@
+//
+//  CPDFSignatureWidgetAnnotation.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFWidgetAnnotation.h>
+
+@interface CPDFSignatureWidgetAnnotation : CPDFWidgetAnnotation
+
+- (BOOL)isSigned;
+
+- (void)signWithImage:(CPDFKitPlatformImage *)image;
+
+@end

+ 25 - 0
ComPDFKit.framework/Headers/CPDFSoundAnnotation.h

@@ -0,0 +1,25 @@
+//
+//  CPDFSoundAnnotation.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFAnnotation.h>
+
+/**
+ * A CPDFSoundAnnotation object shall analogous to a text annotation except that instead of a text note, it contains sound recorded from the computer’s microphone or imported from a file.
+ */
+@interface CPDFSoundAnnotation : CPDFAnnotation
+
+@property (nonatomic,assign) BOOL isPlaying;
+
+- (NSString *)mediaPath;
+- (BOOL)setMediaPath:(NSString *)path;
+
+@end

+ 34 - 0
ComPDFKit.framework/Headers/CPDFSquareAnnotation.h

@@ -0,0 +1,34 @@
+//
+//  CPDFSquareAnnotation.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFAnnotation.h>
+
+/**
+ * A CPDFSquareAnnotation object displays a rectangle on a page.
+ *
+ * @discussion Square annotations are like circle annotations (instances of the CPDFCircleAnnotation class) apart from the shape.
+ * The setBorderWidth: method of the CPDFAnnotation class determines the stroke thickness.
+ * The setColor: method of the CPDFAnnotation class determines the stroke color.
+ */
+@interface CPDFSquareAnnotation : CPDFAnnotation
+
+/**
+ * Method to get / set the fill opacity used for drawing the annotation.
+ */
+@property (nonatomic,assign) CGFloat interiorOpacity;
+
+/**
+ * Method to get / set the fill color used for drawing the annotation.
+ */
+@property (nonatomic,retain) CPDFKitPlatformColor *interiorColor;
+
+@end

+ 78 - 0
ComPDFKit.framework/Headers/CPDFStampAnnotation.h

@@ -0,0 +1,78 @@
+//
+//  CPDFStampAnnotation.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFAnnotation.h>
+
+typedef NS_ENUM(NSInteger, CPDFStampType) {
+    CPDFStampTypeStandard = 0,
+    CPDFStampTypeText = 1,
+    CPDFStampTypeImage = 2,
+    CPDFStampTypeDigital = 3
+};
+
+typedef NS_ENUM(NSInteger, CPDFStampStyle) {
+    CPDFStampStyleWhite = 0,
+    CPDFStampStyleRed = 1,
+    CPDFStampStyleGreen = 2,
+    CPDFStampStyleBlue = 3
+};
+
+typedef NS_ENUM(NSInteger, CPDFStampShape) {
+    CPDFStampShapeRectangle = 0,
+    CPDFStampShapeArrowLeft = 1,
+    CPDFStampShapeArrowRight = 2,
+    CPDFStampShapeNone = 3,
+};
+
+/**
+ * A CPDFStampAnnotation object allows you to display a word or phrase in a PDF page.
+ *
+ * @discussion A CPDFStampAnnotation object should have an appearance stream associated with it; otherwise, nothing useful is rendered.
+ */
+@interface CPDFStampAnnotation : CPDFAnnotation
+
+/**
+ * Initializes CPDFStampAnnotation object with image.
+ */
+- (instancetype)initWithDocument:(CPDFDocument *)document image:(CPDFKitPlatformImage *)image;
+
+/**
+ * Initializes CPDFStampAnnotation object with standard type.
+ */
+- (instancetype)initWithDocument:(CPDFDocument *)document type:(NSInteger)type;
+
+/**
+ * Initializes CPDFStampAnnotation object with text.
+ *
+ * @see CPDFStampStyle
+ * @see CPDFStampShape
+ */
+- (instancetype)initWithDocument:(CPDFDocument *)document text:(NSString *)text detailText:(NSString *)detailText style:(CPDFStampStyle)style shape:(CPDFStampShape)shape;
+
+/**
+ * Initializes CPDFStampAnnotation object with digital stamp type.
+ */
+- (instancetype)initWithDocument:(CPDFDocument *)document text:(NSString *)text detailText:(NSString *)detailText dateText:(NSString *)dateText color:(CPDFKitPlatformColor *)color;
+
+/**
+ * Gets the stamp type.
+ *
+ * @see CPDFStampType
+ */
+- (CPDFStampType)stampType;
+
+/**
+ * Gets image for the appearance stream of the stamp annotation.
+ */
+- (CPDFKitPlatformImage *)stampImage;
+
+@end

+ 20 - 0
ComPDFKit.framework/Headers/CPDFTextAnnotation.h

@@ -0,0 +1,20 @@
+//
+//  CPDFTextAnnotation.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFAnnotation.h>
+
+/**
+ * A CPDFTextAnnotation object displays as an icon (such as a “sticky note”) attached to a specified point in the PDF document.
+ */
+@interface CPDFTextAnnotation : CPDFAnnotation
+
+@end

+ 39 - 0
ComPDFKit.framework/Headers/CPDFTextWidgetAnnotation.h

@@ -0,0 +1,39 @@
+//
+//  CPDFTextWidgetAnnotation.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFWidgetAnnotation.h>
+
+/**
+ * A CPDFTextWidgetAnnotation object allows you to manage the appearance and content of text fields.
+ *
+ * @discussion CPDFTextWidgetAnnotation inherits general annotation behavior from the CPDFWidgetAnnotation class.
+ */
+@interface CPDFTextWidgetAnnotation : CPDFWidgetAnnotation
+
+/**
+ * String value associated with text field.
+ */
+@property (nonatomic,retain) NSString *stringValue;
+
+/**
+ * Alignment of text. Supported: NSLeftTextAlignment, NSRightTextAlignment and NSCenterTextAlignment.
+ */
+@property (nonatomic,assign) NSTextAlignment alignment;
+
+/**
+ * Configuring multiline PDF text fields.
+ */
+@property (nonatomic,assign) BOOL isMultiline;
+
+@property (nonatomic,assign) BOOL isDate;
+
+@end

+ 36 - 0
ComPDFKit.framework/Headers/CPDFURLAction.h

@@ -0,0 +1,36 @@
+//
+//  CPDFURLAction.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFAction.h>
+
+/**
+ * CPDFURLAction, a subclass of CPDFAction, defines methods for getting and setting the URL associated with a URL action.
+ */
+@interface CPDFURLAction : CPDFAction
+
+#pragma mark - Initializers
+
+/**
+ * Initializes a URL action with the specified URL.
+ *
+ * @param url The URL to set the action to.
+ */
+- (instancetype)initWithURL:(NSString *)url NS_DESIGNATED_INITIALIZER;
+
+#pragma mark - Accessors
+
+/**
+ * Returns the URL associated with the URL action.
+ */
+- (NSString *)url;
+
+@end

+ 22 - 0
ComPDFKit.framework/Headers/CPDFUtilities.h

@@ -0,0 +1,22 @@
+//
+//  CPDFUtilities.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#ifndef CPDFUtilities_h
+#define CPDFUtilities_h
+
+#define C_Cache_Folder             [NSSearchPathForDirectoriesInDomains(NSCachesDirectory, NSUserDomainMask, YES) firstObject]
+#define CPDFKiC_Cache_Folder       [C_Cache_Folder stringByAppendingPathComponent:@"CPDFKitCache"]
+#define CPDFKit_Cache_Image_Folder [CPDFKiC_Cache_Folder stringByAppendingPathComponent:@"Image"]
+#define CPDFKit_Cache_PDF_Folder   [CPDFKiC_Cache_Folder stringByAppendingPathComponent:@"PDF"]
+#define CPDFKit_Cache_Media_Folder [CPDFKiC_Cache_Folder stringByAppendingPathComponent:@"Media"]
+
+#endif /* CPDFUtilities_h */

+ 330 - 0
ComPDFKit.framework/Headers/CPDFView.h

@@ -0,0 +1,330 @@
+//
+//  CPDFView.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <UIKit/UIKit.h>
+
+typedef NS_ENUM(NSInteger, CPDFDisplayDirection) {
+    CPDFDisplayDirectionVertical = 0,
+    CPDFDisplayDirectionHorizontal = 1,
+};
+
+typedef NS_ENUM(NSInteger, CPDFDisplayMode) {
+    CPDFDisplayModeNormal = 0,
+    CPDFDisplayModeNight = 1,
+    CPDFDisplayModeSoft = 2,
+    CPDFDisplayModeGreen = 3,
+    CPDFDisplayModeCustom = 4
+};
+
+@class CPDFView, CPDFDocument, CPDFPage, CPDFSelection, CPDFDestination, CPDFFreeTextAnnotation, CPDFTextWidgetAnnotation;
+
+@protocol CPDFViewDelegate <NSObject>
+
+@optional
+
+- (void)PDFViewDocumentDidLoaded:(CPDFView *)pdfView;
+
+- (void)PDFViewCurrentPageDidChanged:(CPDFView *)pdfView;
+
+- (void)PDFViewDidClickOnLink:(CPDFView *)pdfView withURL:(NSString *)url;
+
+- (void)PDFViewPerformURL:(CPDFView *)pdfView withContent:(NSString *)content;
+
+- (void)PDFViewPerformUOP:(CPDFView *)pdfView withContent:(NSString *)content;
+
+- (void)PDFViewPerformPrint:(CPDFView *)pdfView;
+
+- (void)PDFViewPerformReset:(CPDFView *)pdfView;
+
+- (void)PDFViewShouldBeginEditing:(CPDFView *)pdfView textView:(UITextView *)textView forAnnotation:(CPDFFreeTextAnnotation *)annotation;
+
+- (void)PDFViewShouldEndEditing:(CPDFView *)pdfView textView:(UITextView *)textView forAnnotation:(CPDFFreeTextAnnotation *)annotation;
+
+- (void)PDFViewShouldBeginEditing:(CPDFView *)pdfView textView:(UITextView *)textView forTextWidget:(CPDFTextWidgetAnnotation *)textWidget;
+
+- (void)PDFViewShouldEndEditing:(CPDFView *)pdfView textView:(UITextView *)textView forTextWidget:(CPDFTextWidgetAnnotation *)textWidget;
+
+- (void)PDFViewDidEndDragging:(CPDFView *)pdfView;
+
+@end
+
+/**
+ * This class is the main view of ComPDFKit you can instantiate a CPDFView that will host the contents of a CPDFDocument.
+ *
+ * @discussion CPDFView may be the only class you need to deal with for adding PDF functionality to your application.
+ * It lets you display PDF data and allows users to select content, navigate through a document, set zoom level, and copy textual content to the Pasteboard.
+ * CPDFView also keeps track of page history. You can subclass CPDFView to create a custom PDF viewer.
+ */
+@interface CPDFView : UIView
+
+#pragma mark - Document
+
+/**
+ * Methods for associating a CPDFDocument with a CPDFView.
+ */
+@property (nonatomic,retain) CPDFDocument *document;
+
+#pragma mark - Accessors
+
+/**
+ * Returns the view’s delegate.
+ *
+ * @see CPDFViewDelegate
+ */
+@property (nonatomic,assign) id<CPDFViewDelegate> delegate;
+
+/**
+ * A Boolean value indicating whether the document displays two pages side-by-side.
+ */
+@property (nonatomic,assign) BOOL displayTwoUp;
+
+/**
+ * Specifies whether the first page is to be presented as a cover and displayed by itself (for two-up modes).
+ */
+@property (nonatomic,assign) BOOL displaysAsBook;
+
+/**
+ * The layout direction, either vertical or horizontal, for the given display mode.
+ *
+ * @discussion Defaults to vertical layout (CPDFDisplayDirectionVertical).
+ * @see CPDFDisplayDirection
+ */
+@property (nonatomic,assign) CPDFDisplayDirection displayDirection;
+
+/**
+ * A Boolean value indicating whether the view is displaying page breaks.
+ *
+ * @discussion Toggle displaying or not displaying page breaks (spacing) between pages. This spacing value is defined by the pageBreakMargins property.
+ * If displaysPageBreaks is NO, then pageBreakMargins will always return { 10.0, 10.0, 10.0, 10.0 }. Default is YES.
+ */
+@property (nonatomic,assign) BOOL displaysPageBreaks;
+
+/**
+ * The spacing between pages as defined by the top, bottom, left, and right margins.
+ *
+ * @discussion If displaysPageBreaks is enabled, you may customize the spacing between pages by defining margins for the top, bottom, left, and right of each page.
+ * Note that pageBreakMargins only allows positive values and will clamp any negative value to 0.0.
+ * By default, if displaysPageBreaks is enabled, pageBreakMargins is { 10.0, 10.0, 10.0, 10.0 } (with respect to top, left, bottom, right), otherwise it is { 0.0, 0.0, 0.0, 0.0 }.
+ */
+@property (nonatomic,assign) UIEdgeInsets pageBreakMargins;
+
+/**
+ * The page render mode, either normal, night, soft, green or custom, for the given display mode.
+ *
+ * @see CPDFDisplayMode
+ */
+@property (nonatomic,assign) CPDFDisplayMode displayMode;
+/**
+ * If displayMode is CPDFDisplayModeCustom, you may customize the color of the page rendering.
+ */
+@property (nonatomic,retain) UIColor *displayModeCustomColor;
+
+/**
+ * A Boolean value indicating whether the view is displaying page crop.
+ *
+ * @discussion Automatically crop out valid content from the page, If there is no content in the page, no cropping will be done.
+ */
+@property (nonatomic,assign) BOOL displayCrop;
+
+/**
+ * A Boolean value that determines whether scrolling is enabled for the document view.
+ */
+@property (nonatomic,assign) BOOL scrollEnabled;
+
+/**
+ * A Boolean value that determines whether scrolling is disabled in the vertical direction for the document view.
+ */
+@property (nonatomic,assign) BOOL directionaHorizontalLockEnabled;
+
+/**
+ * The current scale factor for the view.
+ *
+ * @discussion Method to get / set the current scaling on the displayed PDF document. Default is 1.0.
+ */
+@property (nonatomic,assign) CGFloat scaleFactor;
+
+- (void)setScaleFactor:(CGFloat)scaleFactor animated:(BOOL)animated;
+
+#pragma mark - Draw
+
+@property (nonatomic,readonly) BOOL isDrawing;
+@property (nonatomic,readonly) BOOL isDrawErasing;
+
+- (void)beginDrawing;
+- (void)endDrawing;
+- (void)commitDrawing;
+
+- (void)setDrawErasing:(BOOL)isErasing;
+- (void)drawUndo;
+- (void)drawRedo;
+
+#pragma mark - Annotation
+
+- (void)editAnnotationFreeText:(CPDFFreeTextAnnotation *)freeText;
+- (void)commitEditAnnotationFreeText;
+- (void)setEditAnnotationFreeTextFont:(UIFont *)font;
+- (void)setEditAnnotationFreeTextColor:(UIColor *)color;
+
+#pragma mark - Page
+
+/**
+ * Returns the current page index.
+ */
+@property (nonatomic,readonly) NSInteger currentPageIndex;
+
+/**
+ * Scrolls to the specified page.
+ */
+- (void)goToPageIndex:(NSInteger)pageIndex animated:(BOOL)animated;
+
+/**
+ * Returns a CPDFDestination object representing the current page and the current point in the view specified in page space.
+ */
+@property (nonatomic,readonly) CPDFDestination *currentDestination;
+
+/**
+ * Goes to the specified destination.
+ *
+ * Destinations include a page and a point on the page specified in page space.
+ */
+- (void)goToDestination:(CPDFDestination *)destination animated:(BOOL)animated;
+
+/**
+ * Goes to the specified rectangle on the specified page.
+ *
+ * @discussion This allows you to scroll the CPDFView object to a specific CPDFAnnotation or CPDFSelection object,
+ * because both of these objects have bounds methods that return an annotation or selection position in page space.
+ * Note that rect is specified in page-space coordinates. Page space is a coordinate system with the origin at the lower-left corner of the current page.
+ */
+- (void)goToRect:(CGRect)rect onPage:(CPDFPage *)page animated:(BOOL)animated;
+
+/**
+ * Returns an array of CPDFPage objects that represent the currently visible pages.
+ */
+@property (nonatomic,readonly) NSArray<CPDFPage *> *visiblePages;
+
+#pragma mark - Selection
+
+/**
+ * Enter text selection mode.
+ *
+ * @discussion The scrollEnabled is NO in the text selection mode.
+ */
+@property (nonatomic,assign) BOOL textSelectionMode;
+
+/**
+ * Returns actual instance of the current CPDFSelection object.
+ *
+ * @discussion The view redraws as necessary but does not scroll.
+ */
+@property (nonatomic,readonly) CPDFSelection *currentSelection;
+
+/**
+ * Clears the selection.
+ *
+ * @discussion The view redraws as necessary but does not scroll.
+ */
+- (void)clearSelection;
+
+/**
+ * Goes to the first character of the specified selection.
+ */
+- (void)goToSelection:(CPDFSelection *)selection animated:(BOOL)animated;
+
+/**
+ * The following calls allow you to associate a CPDFSelection with a CPDFView.
+ *
+ * @discussion The selection do not go away when the user clicks in the CPDFView, etc. You must explicitly remove them by passing nil to -[setHighlightedSelection:animated:].
+ * This method allow you to highlight text perhaps to indicate matches from a text search. Commonly used for highlighting search results.
+ */
+- (void)setHighlightedSelection:(CPDFSelection *)selection animated:(BOOL)animated;
+
+#pragma mark - Display
+
+/**
+ * The innermost view used by CPDFView or by your CPDFView subclass.
+ *
+ * @discussion The innermost view is the one displaying the visible document pages.
+ */
+- (UIScrollView *)documentView;
+
+/**
+ * Performs layout of the inner views.
+ *
+ * @discussion The CPDFView actually contains several subviews. Changes to the PDF content may require changes to these inner views,
+ * so you must call this method explicitly if you use PDF Kit utility classes to add or remove a page, rotate a page, or perform other operations affecting visible layout.
+ * This method is called automatically from CPDFView methods that affect the visible layout (such as setDocument:).
+ */
+- (void)layoutDocumentView;
+
+/**
+ * Draw and render of the currently visible pages.
+ */
+- (void)setNeedsDisplayForVisiblePages;
+
+/**
+ * Draw and render of the specified page.
+ */
+- (void)setNeedsDisplayForPage:(CPDFPage *)page;
+
+#pragma mark - Rendering
+
+/**
+ * Draw and render a visible page to a context.
+ *
+ * @discussion For subclasses. This method is called for each visible page requiring rendering. By subclassing you can draw on top of the PDF page.
+ */
+- (void)drawPage:(CPDFPage *)page toContext:(CGContextRef)context;
+
+#pragma mark - Menu
+
+- (NSArray<UIMenuItem *> *)menuItemsAtPoint:(CGPoint)point forPage:(CPDFPage *)page;
+
+#pragma mark - Touch
+
+- (void)touchBeganAtPoint:(CGPoint)point forPage:(CPDFPage *)page;
+- (void)touchMovedAtPoint:(CGPoint)point forPage:(CPDFPage *)page;
+- (void)touchEndedAtPoint:(CGPoint)point forPage:(CPDFPage *)page;
+- (void)touchCancelledAtPoint:(CGPoint)point forPage:(CPDFPage *)page;
+
+#pragma mark - Conversion
+
+/**
+ * Converts a point from view space to page space.
+ *
+ * @discussion Page space is a coordinate system with the origin at the lower-left corner of the current page.
+ * View space is a coordinate system with the origin at the upper-left corner of the current PDF view.
+ */
+- (CGPoint)convertPoint:(CGPoint)point toPage:(CPDFPage *)page;
+/**
+ * Converts a rectangle from view space to page space.
+ *
+ * @discussion Page space is a coordinate system with the origin at the lower-left corner of the current page.
+ * View space is a coordinate system with the origin at the upper-left corner of the current PDF view.
+ */
+- (CGRect)convertRect:(CGRect)rect toPage:(CPDFPage *)page;
+/**
+ * Converts a point from page space to view space.
+ *
+ * @discussion Page space is a coordinate system with the origin at the lower-left corner of the current page.
+ * View space is a coordinate system with the origin at the upper-left corner of the current PDF view.
+ */
+- (CGPoint)convertPoint:(CGPoint)point fromPage:(CPDFPage *)page;
+/**
+ * Converts a rectangle from page space to view space.
+ *
+ * @discussion Page space is a coordinate system with the origin at the lower-left corner of the current page.
+ * View space is a coordinate system with the origin at the upper-left corner of the current PDF view.
+ */
+- (CGRect)convertRect:(CGRect)rect fromPage:(CPDFPage *)page;
+
+@end

+ 167 - 0
ComPDFKit.framework/Headers/CPDFWatermark.h

@@ -0,0 +1,167 @@
+//
+//  CPDFWatermark.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFKitPlatform.h>
+
+typedef NS_ENUM(NSInteger, CPDFWatermarkType) {
+    CPDFWatermarkTypeText = 0,
+    CPDFWatermarkTypeImage
+};
+
+typedef NS_ENUM(NSInteger, CPDFWatermarkVerticalPosition) {
+    CPDFWatermarkVerticalPositionTop = 0,
+    CPDFWatermarkVerticalPositionCenter,
+    CPDFWatermarkVerticalPositionBottom
+};
+
+typedef NS_ENUM(NSInteger, CPDFWatermarkHorizontalPosition) {
+    CPDFWatermarkHorizontalPositionLeft = 0,
+    CPDFWatermarkHorizontalPositionCenter,
+    CPDFWatermarkHorizontalPositionRight
+};
+
+@class CPDFDocument;
+
+/**
+ * Add and delete image and text watermarks.
+ */
+@interface CPDFWatermark : NSObject
+
+#pragma mark - Initializers
+
+/**
+ * Initializes the watermark.
+ *
+ * @param document The document with which the watermark is associated.
+ * @param type The type index of the watermark.
+ * @see CPDFWatermarkType
+ */
+- (instancetype)initWithDocument:(CPDFDocument *)document type:(CPDFWatermarkType)type;
+
+#pragma mark - Accessors
+
+/**
+ * Returns the type for the watermark.
+ *
+ * @see CPDFWatermarkType
+ */
+@property (nonatomic,readonly) CPDFWatermarkType type;
+
+/**
+ * Method to get / set the text for the watermark (image watermark does not work).
+ */
+@property (nonatomic,copy) NSString *text;
+
+/**
+ * Method to get / set the text font for the watermark (image watermark does not work).
+ *
+ * @discussion The text font for the watermark; may return NULL if the watermark was created with image.
+ * Default Font : Helvetica 24
+ */
+@property (nonatomic,retain) CPDFKitPlatformFont *textFont;
+
+/**
+ * Method to get / set the text color for the watermark (image watermark does not work).
+ */
+@property (nonatomic,retain) CPDFKitPlatformColor *textColor;
+
+/**
+ * Method to get / set the image for the watermark (text watermark does not work).
+ */
+@property (nonatomic,retain) CPDFKitPlatformImage *image;
+
+/**
+ * Method to get / set the scale factor for the watermark.
+ *
+ * @discussion Default is 1.0.
+ */
+@property (nonatomic,assign) CGFloat scale;
+
+/**
+ * Method to get / set the rotation for the watermark.
+ *
+ * @discussion Range : 0~360, Default is 0.0.
+ */
+@property (nonatomic,assign) CGFloat rotation;
+
+/**
+ * Method to get / set the opacity for the watermark.
+ *
+ * @discussion Range : 0~1, Default is 1.0.
+ */
+@property (nonatomic,assign) CGFloat opacity;
+
+/**
+ * Method to get / set the page range for the watermark.
+ *
+ * @discussion If not set, default to all pages.
+ */
+@property (nonatomic,assign) NSRange pageRange;
+
+/**
+ * Method to get / set the page range for the watermark by string.
+ *
+ * @discussion A page range string, Such as "0,3,5-7".
+ */
+@property (nonatomic,retain) NSString *pageString;
+
+/**
+ * Method to get / set the vertical position for the watermark.
+ *
+ * @discussion Default is CPDFWatermarkVerticalPositionCenter.
+ * @see CPDFWatermarkVerticalPosition
+ */
+@property (nonatomic,assign) CPDFWatermarkVerticalPosition verticalPosition;
+
+/**
+ * Method to get / set the horizontal position for the watermark.
+ *
+ * @discussion Default is CPDFWatermarkHorizontalPositionCenter.
+ * @see CPDFWatermarkHorizontalPosition
+ */
+@property (nonatomic,assign) CPDFWatermarkHorizontalPosition horizontalPosition;
+
+/**
+ * Method to get / set the horizontal translation for the watermark.
+ *
+ * @discussion The translation relative to the horizontal position.
+ */
+@property (nonatomic,assign) CGFloat tx;
+
+/**
+ * Method to get / set the vertical translation for the watermark.
+ *
+ * @discussion The translation relative to the vertical position.
+ */
+@property (nonatomic,assign) CGFloat ty;
+
+/**
+ * Method to get/set watermark to locate in front of the content.
+ */
+@property (nonatomic,assign) BOOL isFront;
+
+/**
+ * Method to get / set tiled watermark for the page(image watermark does not work).
+ */
+@property (nonatomic,assign) BOOL isTilePage;
+
+/**
+ * Method to get / set the vertical spacing for the tiled watermark.
+ */
+@property (nonatomic,assign) CGFloat verticalSpacing;
+
+/**
+ * Method to get / set the horizontal spacing for the tiled watermark.
+ */
+@property (nonatomic,assign) CGFloat horizontalSpacing;
+
+@end

+ 50 - 0
ComPDFKit.framework/Headers/CPDFWidgetAnnotation.h

@@ -0,0 +1,50 @@
+//
+//  CPDFWidgetAnnotation.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFAnnotation.h>
+
+/**
+ * A CPDFWidgetAnnotation object is a collection of fields for gathering information interactively from the user.
+ */
+@interface CPDFWidgetAnnotation : CPDFAnnotation
+
+/**
+ * Method to get / set the border color used for the form field.
+ */
+@property (nonatomic,retain) CPDFKitPlatformColor *borderColor;
+
+/**
+ * Method to ge t/ set the background color used for the form field.
+ */
+@property (nonatomic,retain) CPDFKitPlatformColor *backgroundColor;
+
+@property (nonatomic,assign) CGFloat backgroundOpacity;
+
+/**
+ * Method to get / set the font used for the form field.
+ */
+@property (nonatomic,retain) CPDFKitPlatformFont *font;
+
+/**
+ * Method to get / set the font color used for the form field.
+ */
+@property (nonatomic,retain) CPDFKitPlatformColor *fontColor;
+
+/**
+ * Internal name for the field.
+ */
+- (NSString *)fieldName;
+- (void)setFieldName:(NSString *)name;
+
+- (void)reset;
+
+@end

+ 57 - 0
ComPDFKit.framework/Headers/ComPDFKit.h

@@ -0,0 +1,57 @@
+//
+//  ComPDFKit.h
+//  ComPDFKit
+//
+//  Copyright © 2014-2022 PDF Technologies, Inc. All Rights Reserved.
+//
+//  THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
+//  AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT.
+//  UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
+//  This notice may not be removed from this file.
+//
+
+#import <ComPDFKit/CPDFKit.h>
+#import <ComPDFKit/CPDFKitPlatform.h>
+#import <ComPDFKit/CPDFKitConfig.h>
+
+#import <ComPDFKit/CPDFDocument.h>
+#import <ComPDFKit/CPDFBookmark.h>
+#import <ComPDFKit/CPDFOutline.h>
+#import <ComPDFKit/CPDFWatermark.h>
+#import <ComPDFKit/CPDFHeaderFooter.h>
+#import <ComPDFKit/CPDFBates.h>
+#import <ComPDFKit/CPDFBackground.h>
+#import <ComPDFKit/CPDFDestination.h>
+
+#import <ComPDFKit/CPDFAction.h>
+#import <ComPDFKit/CPDFGoToAction.h>
+#import <ComPDFKit/CPDFURLAction.h>
+#import <ComPDFKit/CPDFNamedAction.h>
+#import <ComPDFKit/CPDFResetFormAction.h>
+
+#import <ComPDFKit/CPDFPage.h>
+#import <ComPDFKit/CPDFSelection.h>
+
+#import <ComPDFKit/CPDFBorder.h>
+#import <ComPDFKit/CPDFAnnotation.h>
+#import <ComPDFKit/CPDFTextAnnotation.h>
+#import <ComPDFKit/CPDFLinkAnnotation.h>
+#import <ComPDFKit/CPDFFreeTextAnnotation.h>
+#import <ComPDFKit/CPDFLineAnnotation.h>
+#import <ComPDFKit/CPDFSquareAnnotation.h>
+#import <ComPDFKit/CPDFCircleAnnotation.h>
+#import <ComPDFKit/CPDFMarkupAnnotation.h>
+#import <ComPDFKit/CPDFStampAnnotation.h>
+#import <ComPDFKit/CPDFInkAnnotation.h>
+#import <ComPDFKit/CPDFSoundAnnotation.h>
+#import <ComPDFKit/CPDFMovieAnnotation.h>
+#import <ComPDFKit/CPDFSignatureAnnotation.h>
+#import <ComPDFKit/CPDFRedactAnnotation.h>
+
+#import <ComPDFKit/CPDFWidgetAnnotation.h>
+#import <ComPDFKit/CPDFButtonWidgetAnnotation.h>
+#import <ComPDFKit/CPDFChoiceWidgetAnnotation.h>
+#import <ComPDFKit/CPDFTextWidgetAnnotation.h>
+#import <ComPDFKit/CPDFSignatureWidgetAnnotation.h>
+
+#import <ComPDFKit/CPDFView.h>

BIN
ComPDFKit.framework/Info.plist


+ 6 - 0
ComPDFKit.framework/Modules/module.modulemap

@@ -0,0 +1,6 @@
+framework module ComPDFKit {
+  umbrella header "ComPDFKit.h"
+
+  export *
+  module * { export * }
+}

File diff suppressed because it is too large
+ 1062 - 0
ComPDFKit.framework/_CodeSignature/CodeResources


BIN
ComPDFKit.framework/formsign_tag.png


BIN
ComPDFKit.framework/formsign_tag@2x.png


BIN
ComPDFKit.framework/loupe-hi.png


BIN
ComPDFKit.framework/loupe-lo.png


BIN
ComPDFKit.framework/loupe-mask.png


BIN
ComPDFKit.framework/magnifier-ranged-hi.png


BIN
ComPDFKit.framework/magnifier-ranged-lo.png


BIN
ComPDFKit.framework/magnifier-ranged-mask.png


BIN
ComPDFKit.framework/popup_note.png


BIN
ComPDFKit.framework/popup_note@2x.png


BIN
ComPDFKit.framework/quick_bookmark.png


BIN
ComPDFKit.framework/quick_bookmark~ipad.png


BIN
ComPDFKit.framework/recoding_on.png


BIN
ComPDFKit.framework/recoding_on@2x.png


BIN
ComPDFKit.framework/recoding_play.png


BIN
ComPDFKit.framework/recoding_play@2x.png


BIN
ComPDFKit.framework/sRGB2014.icc


BIN
ComPDFKit.framework/viewer_dragDontBack.png


BIN
ComPDFKit.framework/viewer_dragDontBack@2x.png


BIN
ComPDFKit.framework/viewer_dragDontFront.png


BIN
ComPDFKit.framework/viewer_dragDontFront@2x.png


+ 30 - 0
PDFViewer.xcodeproj/project.pbxproj

@@ -7,6 +7,8 @@
 	objects = {
 
 /* Begin PBXBuildFile section */
+		EC3198782922593A008E0889 /* ComPDFKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = EC31987629225931008E0889 /* ComPDFKit.framework */; };
+		EC3198792922593A008E0889 /* ComPDFKit.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = EC31987629225931008E0889 /* ComPDFKit.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
 		EC62978E29220F8300D339EE /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = EC62978D29220F8300D339EE /* AppDelegate.m */; };
 		EC62979129220F8300D339EE /* SceneDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = EC62979029220F8300D339EE /* SceneDelegate.m */; };
 		EC62979429220F8300D339EE /* ViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = EC62979329220F8300D339EE /* ViewController.m */; };
@@ -18,7 +20,22 @@
 		EC6297BD292239C200D339EE /* CPDFController.m in Sources */ = {isa = PBXBuildFile; fileRef = EC6297BC292239C200D339EE /* CPDFController.m */; };
 /* End PBXBuildFile section */
 
+/* Begin PBXCopyFilesBuildPhase section */
+		EC31987529225362008E0889 /* Embed Frameworks */ = {
+			isa = PBXCopyFilesBuildPhase;
+			buildActionMask = 2147483647;
+			dstPath = "";
+			dstSubfolderSpec = 10;
+			files = (
+				EC3198792922593A008E0889 /* ComPDFKit.framework in Embed Frameworks */,
+			);
+			name = "Embed Frameworks";
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+/* End PBXCopyFilesBuildPhase section */
+
 /* Begin PBXFileReference section */
+		EC31987629225931008E0889 /* ComPDFKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = ComPDFKit.framework; sourceTree = "<group>"; };
 		EC62978929220F8300D339EE /* PDFViewer.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = PDFViewer.app; sourceTree = BUILT_PRODUCTS_DIR; };
 		EC62978C29220F8300D339EE /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = "<group>"; };
 		EC62978D29220F8300D339EE /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = "<group>"; };
@@ -42,6 +59,7 @@
 			isa = PBXFrameworksBuildPhase;
 			buildActionMask = 2147483647;
 			files = (
+				EC3198782922593A008E0889 /* ComPDFKit.framework in Frameworks */,
 			);
 			runOnlyForDeploymentPostprocessing = 0;
 		};
@@ -51,6 +69,7 @@
 		EC62978029220F8300D339EE = {
 			isa = PBXGroup;
 			children = (
+				EC31987629225931008E0889 /* ComPDFKit.framework */,
 				EC62978B29220F8300D339EE /* PDFViewer */,
 				EC62978A29220F8300D339EE /* Products */,
 			);
@@ -120,6 +139,7 @@
 				EC62978529220F8300D339EE /* Sources */,
 				EC62978629220F8300D339EE /* Frameworks */,
 				EC62978729220F8300D339EE /* Resources */,
+				EC31987529225362008E0889 /* Embed Frameworks */,
 			);
 			buildRules = (
 			);
@@ -329,6 +349,11 @@
 				ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
 				CODE_SIGN_STYLE = Automatic;
 				DEVELOPMENT_TEAM = 4JF62WQ995;
+				EXCLUDED_ARCHS = arm64;
+				FRAMEWORK_SEARCH_PATHS = (
+					"$(inherited)",
+					"$(PROJECT_DIR)",
+				);
 				INFOPLIST_FILE = PDFViewer/Info.plist;
 				IPHONEOS_DEPLOYMENT_TARGET = 13.0;
 				LD_RUNPATH_SEARCH_PATHS = (
@@ -348,6 +373,11 @@
 				ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
 				CODE_SIGN_STYLE = Automatic;
 				DEVELOPMENT_TEAM = 4JF62WQ995;
+				EXCLUDED_ARCHS = arm64;
+				FRAMEWORK_SEARCH_PATHS = (
+					"$(inherited)",
+					"$(PROJECT_DIR)",
+				);
 				INFOPLIST_FILE = PDFViewer/Info.plist;
 				IPHONEOS_DEPLOYMENT_TARGET = 13.0;
 				LD_RUNPATH_SEARCH_PATHS = (

BIN
PDFViewer.xcodeproj/project.xcworkspace/xcuserdata/kdan.xcuserdatad/UserInterfaceState.xcuserstate


+ 3 - 0
PDFViewer/AppDelegate.m

@@ -5,6 +5,7 @@
 //  Created by kdan on 2022/11/14.
 //
 
+#import <ComPDFKit/ComPDFKit.h>
 #import "AppDelegate.h"
 
 @interface AppDelegate ()
@@ -16,6 +17,8 @@
 
 - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
     // Override point for customization after application launch.
+    [CPDFKit setLicenseKey:@"d2rW7BdT+peaa/hxOm4N/PYo5lotThkuHWjzZs4IXTOdY7Wss9Vk/lZni8H4rKu7t/RMjwDlJIXKIqzwOO0h2IakMBU5cy12KJhwgKRGBL2rBSN7GpOoZTufmlxsrj6RWP60/mQ39ZQiTAjx4eTVL9VwudIk/2Zj7YfhVweCJN0=" secret:@"mG0c3O3Mzeu5dkZJW3gpql8+jBucojBtBSjI3YJz2gAQurxTxGuBlGAhs0P1mD3XKqvsLa4npVLfI/mo45dkJ5QFcNndGDskT70Jc2iwVo5hrp9sGpqfp0B228KI+IMTu4aGVjtYuk+Uxs/kosIBw1367/WkJ00tM7U7tttD6ccsvUiEnSpVC16x66CLYBR9nL4G5ayY1Yw9IbVniEuzaCCVg1bqAdLSXAjS4mxI/QshmpPEP0qS8yPf877NfXnm6gW/UFOMJ5eWQQ5IO+aCVQ=="];
+    
     return YES;
 }
 

+ 23 - 11
PDFViewer/Controller/CPDFController.m

@@ -5,6 +5,7 @@
 //  Created by kdan on 2022/11/14.
 //
 
+#import <ComPDFKit/ComPDFKit.h>
 #import "CPDFController.h"
 #import "CPDFModel.h"
 
@@ -12,7 +13,6 @@
 
 @property (nonatomic,strong) UITableView *tableView;
 @property (nonatomic,strong) NSMutableArray *dataArray;
-@property (nonatomic,strong) NSMutableArray *pathArray;
 
 @end
 
@@ -30,17 +30,21 @@
     if (!_dataArray) {
         
         _dataArray = [NSMutableArray array];
+        
         NSFileManager *defaultManager = [NSFileManager defaultManager];
         NSArray *fileArray = [defaultManager contentsOfDirectoryAtPath:self.path error:nil];
         
-        NSMutableArray *mArray = [NSMutableArray array];
-        
-        for (NSInteger i = 0; i < fileArray.count; ++i) {
+        for (NSInteger i = 1; i < fileArray.count; ++i) {
+            
+            NSString *subFilePath = [[self.path stringByAppendingString:@"/"] stringByAppendingString:fileArray[i]];
+            
             CPDFModel *model = [[CPDFModel alloc] init];
             model.fileName = fileArray[i];
+            model.filePath = subFilePath;
+            
             [_dataArray addObject:model];
+            
         }
-        [self setPathArray:mArray];
     }
     return _dataArray;
 }
@@ -83,7 +87,6 @@
         cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:MyIdentifier];
     }
     
-//    cell.model = self.dataArray[indexPath.row];
     cell.textLabel.text = [self.dataArray[indexPath.row] fileName];
     return cell;
 }
@@ -92,11 +95,20 @@
 
 - (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
     
-//    CPDFViewCell *model = [[CPDFViewCell alloc] init];
-//    model.filePath = self.pathArray[indexPath.row];
-//
-//     *table = [[TableViewController alloc] initWithModel:model];
-//    [self.navigationController pushViewController:table animated:NO];
+    // Get the path of a PDF
+    NSString *pdfPath = [self.dataArray[indexPath.row] filePath];
+    
+    // Initialize a CPDFDocument object with the path to the PDF file
+    NSURL *url = [NSURL fileURLWithPath:pdfPath];
+    CPDFDocument *document = [[CPDFDocument alloc] initWithURL:url];
+    
+    // Initialize a CPDFView object with the size of the entire screen
+    CPDFView *pdfView = [[CPDFView alloc] initWithFrame:self.view.bounds];
+    
+    // Set the document to display
+    pdfView.document = document;
+    
+    [self.view addSubview:pdfView];
 }
 
 @end

+ 2 - 0
PDFViewer/SceneDelegate.m

@@ -5,6 +5,7 @@
 //  Created by kdan on 2022/11/14.
 //
 
+#import <ComPDFKit/ComPDFKit.h>
 #import "SceneDelegate.h"
 #import "CPDFController.h"
 #import "CPDFModel.h"
@@ -20,6 +21,7 @@
     // Use this method to optionally configure and attach the UIWindow `window` to the provided UIWindowScene `scene`.
     // If using a storyboard, the `window` property will automatically be initialized and attached to the scene.
     // This delegate does not imply the connecting scene or session are new (see `application:configurationForConnectingSceneSession` instead).
+    
     [self setWindow:[[UIWindow alloc] initWithWindowScene:(UIWindowScene *)scene]];
     [self.window setBackgroundColor:[UIColor whiteColor]];
     [self.window makeKeyAndVisible];

+ 1 - 0
PDFViewer/ViewController.m

@@ -5,6 +5,7 @@
 //  Created by kdan on 2022/11/14.
 //
 
+#import <ComPDFKit/ComPDFKit.h>
 #import "ViewController.h"
 
 @interface ViewController ()