Helper and Abstract Classes

  • An object that manages the controls for adding new pages to a document. New pages can be created from blank page templates (e.g. lined, grid, dotted), added from other documents, or created from images.

    See more

    Declaration

    Objective-C

    @interface PTAddPagesManager
        : NSObject <UIImagePickerControllerDelegate, UINavigationControllerDelegate,
                    UIDocumentPickerDelegate>

    Swift

    class PTAddPagesManager : NSObject, UIImagePickerControllerDelegate, UINavigationControllerDelegate, UIDocumentPickerDelegate
  • This class is used to easily add an analytics framework to tools. Events of interest are be passed to (a subclass of) this generic class, and can then passed on to the analytics framework(s) of your choice.

    See more

    Declaration

    Objective-C

    
    @interface PTAnalyticsHandlerAdapter : NSObject

    Swift

    class PTAnalyticsHandlerAdapter : NSObject
  • An object that contains options for a type of annotation.

    See more

    Declaration

    Objective-C

    @interface PTAnnotationOptions : NSObject <NSCopying, NSCoding>

    Swift

    class PTAnnotationOptions : NSObject, NSCopying, NSCoding
  • A PTAnnotationPasteboard instance facilitates annotation copying and pasting on the behalf of a PTPDFViewCtrl or PTToolManager instance. Annotation pasteboards can be shared between multiple PDFViewCtrls, viewers, tabs, etc. to allow annotations to be easily copied between documents.

    See more

    Declaration

    Objective-C

    @interface PTAnnotationPasteboard : NSObject

    Swift

    class PTAnnotationPasteboard : NSObject
  • This class wraps a PTAnnot and is used to store style appearance and property information before the information is saved back to the annotation.

    See more

    Declaration

    Objective-C

    @interface PTAnnotStyle : NSObject <NSCopying, NSCoding>

    Swift

    class PTAnnotStyle : NSObject, NSCopying, NSCoding
  • A utility class for managing user bookmarks. Note the the PDF specification does not account for user bookmarks. Therefore user bookmarks are non-portable between PDF readers. PDFNet for iOS stores the bookmarks in the iOS user preferences.

    The bookmark data is an NSArray of NSDictionary-s. Each NSDictionary represents a bookmark. The NSDictionary entries are: {@“page-number” : NSNumber numberWithInt}, {@“sdf-obj-number” : NSNumber numberWithInt}, {@“name” : NSString}, {@“unique-id” : NSString (a UUID string)}

    See more

    Declaration

    Objective-C

    @interface PTBookmarkUtils : NSObject

    Swift

    class PTBookmarkUtils : NSObject
  • Allows the user to interact with and set values of choice fields (list boxes).

    See more

    Declaration

    Objective-C

    @interface PTChoiceFormViewController
        : UIViewController <UITableViewDelegate, UITableViewDataSource>

    Swift

    class PTChoiceFormViewController : UIViewController, UITableViewDelegate, UITableViewDataSource
  • Used to persist annotion properties to user defaults so that the next annotation of that type that is created can have the same properties.

    See more

    Declaration

    Objective-C

    @interface PTColorDefaults : NSObject

    Swift

    class PTColorDefaults : NSObject
  • A UIDocument subclass backed by a PTPDFDoc object.

    To instantiate a new PTCoordinatedDocument, use initWithFileURL:.

    See more

    Declaration

    Objective-C

    @interface PTCoordinatedDocument : UIDocument

    Swift

    class PTCoordinatedDocument : UIDocument
  • An abstract class that many of the annotation-creating tools derive from.

    See more

    Declaration

    Objective-C

    @interface PTCreateToolBase : PTTool {
      int _pageNumber;
      double _thickness;
    }

    Swift

    class PTCreateToolBase : PTTool
  • The PTDigSigView is used for creating signature path appearances. The view tracks and saves user touches, drawing strokes with the specified color and thickness.

    See more

    Declaration

    Objective-C

    @interface PTDigSigView : UIView

    Swift

    class PTDigSigView : UIView
  • The PTDigSigViewController allows the user to draw a signature or select an image for a signature form field. A certificate can be used for digital signing.

    See more

    Declaration

    Objective-C

    @interface PTDigSigViewController
        : UIViewController <PTOverridable, UIImagePickerControllerDelegate,
                            UINavigationControllerDelegate>

    Swift

    class PTDigSigViewController : UIViewController, PTOverridable, UIImagePickerControllerDelegate, UINavigationControllerDelegate
  • The PTEditToolbar is used while creating certain annotation types and provides buttons for saving or discarding changes, as well as an optional undo/redo interface.

    See more

    Declaration

    Objective-C

    @interface PTEditToolbar : UIToolbar <PTOverridable>

    Swift

    class PTEditToolbar : UIToolbar, PTOverridable
  • The PTFloatingSigViewController allows the user to add signatures anywhere on a document. A default signature can be saved for subsequent use.

    See more

    Declaration

    Objective-C

    @interface PTFloatingSigViewController : UIViewController <PTOverridable>

    Swift

    class PTFloatingSigViewController : UIViewController, PTOverridable
  • This class handles the creation of a UIPresentationController that displays its contents covering a portion of the screen, anchored to the bottom of the screen.

    See more

    Declaration

    Objective-C

    @interface PTHalfModalPresentationManager
        : NSObject <UIViewControllerTransitioningDelegate,
                    UIPopoverPresentationControllerDelegate>

    Swift

    class PTHalfModalPresentationManager : NSObject, UIViewControllerTransitioningDelegate, UIPopoverPresentationControllerDelegate
  • Crops image stamp annotations, created by the PTImageStampCreate tool.

    See more

    Declaration

    Objective-C

    @interface PTImageCropTool : PTTool

    Swift

    class PTImageCropTool : PTTool
  • A view controller that displays and allows editing of an annotation’s popup note.

    See more

    Declaration

    Objective-C

    @interface PTNoteEditController : UIViewController

    Swift

    class PTNoteEditController : UIViewController
  • The PTOverrides class is used to register overridden subclasses of classes defined in the Tools library. Once a class conforming to the PTOverridable protocol has been “overridden”, whenever an instance of the original class would be created the subclass is used instead.

    See more

    Declaration

    Objective-C

    @interface PTOverrides : NSObject

    Swift

    class PTOverrides : NSObject
  • Utility methods for the Tools framework.

    See more

    Declaration

    Objective-C

    @interface PTToolsUtil : NSObject

    Swift

    class PTToolsUtil : NSObject
  • The view for the small resize handles that appear for annotation resizing with a PTSelectionRectContainerView.

    See more

    Declaration

    Objective-C

    @interface PTResizeWidgetView : UIView

    Swift

    class PTResizeWidgetView : UIView
  • Undocumented

    See more

    Declaration

    Objective-C

    @interface PTRubberStampManager : NSObject<PTOverridable>
    
    /**
     * The default light red gradient start color
     */
    @property (nonatomic, class, strong, readonly) UIColor *lightRedStartColor;
    
    /**
     * The default light red gradient end color
     */
    @property (nonatomic, class, strong, readonly) UIColor *lightRedEndColor;
    
    /**
     * The default light red text color
     */
    @property (nonatomic, class, strong, readonly) UIColor *lightRedTextColor;
    
    /**
     * The default light red border color
     */
    @property (nonatomic, class, strong, readonly) UIColor *lightRedBorderColor;
    
    /**
     * The default dark red gradient start color
     */
    @property (nonatomic, class, strong, readonly) UIColor *darkRedStartColor;
    
    /**
     * The default dark red gradient end color
     */
    @property (nonatomic, class, strong, readonly) UIColor *darkRedEndColor;
    
    /**
     * The default dark red text color
     */
    @property (nonatomic, class, strong, readonly) UIColor *darkRedTextColor;
    
    /**
     * The default dark red border color
     */
    @property (nonatomic, class, strong, readonly) UIColor *darkRedBorderColor;
    
    /**
     * The default light green gradient start color
     */
    @property (nonatomic, class, strong, readonly) UIColor *lightGreenStartColor;
    
    /**
     * The default light green gradient end color
     */
    @property (nonatomic, class, strong, readonly) UIColor *lightGreenEndColor;
    
    /**
     * The default light green gradient text color
     */
    @property (nonatomic, class, strong, readonly) UIColor *lightGreenTextColor;
    
    /**
     * The default light green border color
     */
    @property (nonatomic, class, strong, readonly) UIColor *lightGreenBorderColor;
    
    /**
     * The default light blue gradient start color
     */
    @property (nonatomic, class, strong, readonly) UIColor *lightBlueStartColor;
    
    /**
     * The default light blue gradient end color
     */
    @property (nonatomic, class, strong, readonly) UIColor *lightBlueEndColor;
    
    /**
     * The default light blue text color
     */
    @property (nonatomic, class, strong, readonly) UIColor *lightBlueTextColor;
    
    /**
     * The default light blue border color
     */
    @property (nonatomic, class, strong, readonly) UIColor *lightBlueBorderColor;
    
    /**
     * The default yellow gradient start color
     */
    @property (nonatomic, class, strong, readonly) UIColor *yellowStartColor;
    
    /**
     * The default yellow gradient end color
     */
    @property (nonatomic, class, strong, readonly) UIColor *yellowEndColor;
    
    /**
     * The default yellow text color
     */
    @property (nonatomic, class, strong, readonly) UIColor *yellowTextColor;
    
    /**
     * The default yellow border color
     */
    @property (nonatomic, class, strong, readonly) UIColor *yellowBorderColor;
    
    /**
     * The default purple gradient start color
     */
    @property (nonatomic, class, strong, readonly) UIColor *purpleStartColor;
    
    /**
     * The default purple gradient end color
     */
    @property (nonatomic, class, strong, readonly) UIColor *purpleEndColor;
    
    /**
     * The default purple text color
     */
    @property (nonatomic, class, strong, readonly) UIColor *purpleTextColor;
    
    /**
     * The default purple border color
     */
    @property (nonatomic, class, strong, readonly) UIColor *purpleBorderColor;
    
    /**
     * Used to determine the number of standard stamps.
     *
     * @return the number of standard stamps.
     */
    -(NSUInteger)numberOfStandardStamps;
    
    /**
     * An array of standard rubber stamp appearances.
     * This should be an array of `PTCustomStampOption`s
     */
    @property (nonatomic, copy, nullable) NSArray<PTCustomStampOption*> *standardStampOptions;
    
    /**
     *
     * Returns an image of the stamp with a given `PTCustomStampOption` appearance.
     *
     * @param height The desired height of the output image.
     *
     * @param width The desired width of the output image.
     *
     * @param stampOption A `PTCustomStampOption` appearance object.
     *
     * @return A rasterized copy of the signature.
     *
     */
    +(UIImage*)getBitMapForStampWithHeight:(double)height width:(double)width option:(PTCustomStampOption*)stampOption;
    
    @end

    Swift

    class PTRubberStampManager : NSObject, PTOverridable
  • A text selection end bar.

    See more

    Declaration

    Objective-C

    @interface PTSelectionBar : UIView

    Swift

    class PTSelectionBar : UIView
  • A transparent container view for the shaded PTSelectionRectView and the resize widgets.

    See more

    Declaration

    Objective-C

    @interface PTSelectionRectContainerView : UIView

    Swift

    class PTSelectionRectContainerView : UIView
  • For use when editing line and arrow annotations, where the selection rectangle is not shown when the annotation is not being moved, and has a different appearance than other annotation types.

    See more

    Declaration

    Objective-C

    @interface PTSelectionRectView : UIView

    Swift

    class PTSelectionRectView : UIView
  • A cell for use by the PTThumbnailsViewController.

    See more

    Declaration

    Objective-C

    @interface PTThumbnailViewCell : UICollectionViewCell

    Swift

    class PTThumbnailViewCell : UICollectionViewCell
  • A UICollectionViewLayout for use with PTThumbnailsViewController.

    See more

    Declaration

    Objective-C

    @interface PTThumbnailViewLayout : UICollectionViewFlowLayout

    Swift

    class PTThumbnailViewLayout : UICollectionViewFlowLayout
  • The PTTool base class from which all stock tools derive. These tools implement the PTToolSwitching protocol. For documentation on these methods, please see the protocol documentation, available at http://www.pdftron.com

    See more

    Declaration

    Objective-C

    @interface PTTool : UIView <PTOverridable, UIGestureRecognizerDelegate,
                                PTToolSwitching, PTNoteEditControllerDelegate,
                                UIPopoverPresentationControllerDelegate,
                                UIAdaptivePresentationControllerDelegate>

    Swift

    class PTTool : UIView, PTOverridable, UIGestureRecognizerDelegate, PTToolSwitching, PTNoteEditControllerDelegate, UIPopoverPresentationControllerDelegate, UIAdaptivePresentationControllerDelegate
  • The PTToolGroupManager class maintains a list of tool groups, represented by instances of the PTToolGroup class, each of which contain a set of available tools for that mode.

    This class is designed to work in conjuction with the PTToolGroupToolbar class to display the tool groups and provide interactive control over the current tool.

    See more

    Declaration

    Objective-C

    
    @interface PTToolGroupManager : NSObject <NSCoding>

    Swift

    class PTToolGroupManager : NSObject, NSCoding
  • The PTToolManager class is responsbile for forwarding events from the PDFViewCtrl to Tools, and coordinating the control and data flow between tools.

    See more

    Declaration

    Objective-C

    @interface PTToolManager : UIView <PTOverridable, PTPDFViewCtrlToolDelegate,
                                       PTToolEvents, PTToolOptionsDelegate>
  • Creates signatures and manages saved ones.

    See more

    Declaration

    Objective-C

    @interface PTSignaturesManager : NSObject <PTOverridable>

    Swift

    class PTSignaturesManager : NSObject, PTOverridable
  • Creates signatures and manages saved ones.

    See more

    Declaration

    Objective-C

    
    @interface PTStampManager : NSObject
  • Abstract base class for creating text markup annotations, such as highlights, underlines, strikeouts and squigglies.

    See more

    Declaration

    Objective-C

    @interface PTTextMarkupCreate : PTTool

    Swift

    class PTTextMarkupCreate : PTTool
  • Tool for editing existing text markup annotations, such as highlights, underlines, etc. In addition to changing basic properties like colour and opacity, it can change the annotation’s size, and it’s type (e.g. turn a highlight into an underline).

    See more

    Declaration

    Objective-C

    @interface PTTextMarkupEditTool : PTTextSelectTool

    Swift

    class PTTextMarkupEditTool : PTTextSelectTool
  • The loupe that is used during text selection.

    See more

    Declaration

    Objective-C

    @interface PTMagnifierView : UIView

    Swift

    class PTMagnifierView : UIView
  • A user bookmark for a page in a document.

    See more

    Declaration

    Objective-C

    @interface PTUserBookmark : NSObject

    Swift

    class PTUserBookmark : NSObject