Other Constants

The following constants are available globally.

  • In the old legacy file format the default number of PBKDF rounds is 50000. The new default is PSPDFAESDefaultPBKDFNumberOfRounds. (10000)

    Declaration

    Objective-C

    extern const NSUInteger PSPDFDefaultPBKDFNumberOfRounds

    Swift

    class let defaultNumberOfPBKDFRounds: UInt
  • The PSPDFAESCryptoInputStream Error Domain.

    Note

    Used in the PSPDFAESCryptoInputStream -(NSError *)streamError method.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFAESCryptoInputStreamErrorDomain

    Swift

    let PSPDFAESCryptoInputStreamErrorDomain: String
  • The PSPDFAESCryptoOutputStream Error Domain.

    Note

    Used in the PSPDFAESCryptoOutputStream -(NSError *)streamError method.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFAESCryptoOutputStreamErrorDomain

    Swift

    let PSPDFAESCryptoOutputStreamErrorDomain: String
  • Set to @YES in the options dictionary to make links modal.

    Declaration

    Objective-C

    extern const PSPDFActionOption _Nonnull PSPDFActionOptionModalKey

    Swift

    static let modalKey: Action.Option
  • Enable Autoplay if target is a video.

    Declaration

    Objective-C

    extern const PSPDFActionOption _Nonnull PSPDFActionOptionAutoplayKey

    Swift

    static let autoplayKey: Action.Option
  • Enable/Disable controls. (e.g. Browser back/next buttons)

    Declaration

    Objective-C

    extern const PSPDFActionOption _Nonnull PSPDFActionOptionControlsKey

    Swift

    static let controlsKey: Action.Option
  • Loop the video.

    Declaration

    Objective-C

    extern const PSPDFActionOption _Nonnull PSPDFActionOptionLoopKey

    Swift

    static let loopKey: Action.Option
  • Allow fullscreen presentation.

    Declaration

    Objective-C

    extern const PSPDFActionOption _Nonnull PSPDFActionOptionFullscreenKey

    Swift

    static let fullscreenKey: Action.Option
  • Set video offset.

    Declaration

    Objective-C

    extern const PSPDFActionOption _Nonnull PSPDFActionOptionOffsetKey

    Swift

    static let offsetKey: Action.Option
  • Set modal size.

    Declaration

    Objective-C

    extern const PSPDFActionOption _Nonnull PSPDFActionOptionSizeKey

    Swift

    static let sizeKey: Action.Option
  • Show as popover.

    Declaration

    Objective-C

    extern const PSPDFActionOption _Nonnull PSPDFActionOptionPopoverKey

    Swift

    static let popoverKey: Action.Option
  • Show cover, accepts string path.

    Declaration

    Objective-C

    extern const PSPDFActionOption _Nonnull PSPDFActionOptionCoverKey

    Swift

    static let coverKey: Action.Option
  • The target page.

    Declaration

    Objective-C

    extern const PSPDFActionOption _Nonnull PSPDFActionOptionPageKey

    Swift

    static let pageKey: Action.Option
  • Shows a button that activates links.

    Declaration

    Objective-C

    extern const PSPDFActionOption _Nonnull PSPDFActionOptionButtonKey

    Swift

    static let buttonKey: Action.Option
  • Controls if a close button is displayed, when PSPDFActionOptionButtonKey is used. Default will be YES.

    Declaration

    Objective-C

    extern const PSPDFActionOption _Nonnull PSPDFActionOptionCloseButtonKey

    Swift

    static let closeButtonKey: Action.Option
  • Constant to convert PSPDFActionType into NSString and back.

    Note

    The transformer is added in the class initialize phase. Requires PSPDFAnnotation to be accessed at least once.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(actionType) const PSPDFValueTransformerName
        PSPDFActionTypeTransformerName

    Swift

    static let actionType: ValueTransformerName
  • Links and PSPDFKit multimedia extensions.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringLink

    Swift

    static let link: Annotation.Tool
  • Highlight annotation. Can be used to highlight text.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringHighlight

    Swift

    static let highlight: Annotation.Tool
  • Strikeout annotation. Can be used to strikethrough text.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringStrikeOut

    Swift

    static let strikeOut: Annotation.Tool
  • Underline annotation. Can be used to underline text.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringUnderline

    Swift

    static let underline: Annotation.Tool
  • Squiggly annotation. Can be used to squiggly underline text.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringSquiggly

    Swift

    static let squiggly: Annotation.Tool
  • Note annotation.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringNote

    Swift

    static let note: Annotation.Tool
  • Free text annotation.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringFreeText

    Swift

    static let freeText: Annotation.Tool
  • Ink annotation. Drawing. Includes ink signatures.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringInk

    Swift

    static let ink: Annotation.Tool
  • Square annotation.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringSquare

    Swift

    static let square: Annotation.Tool
  • Circle annotation.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringCircle

    Swift

    static let circle: Annotation.Tool
  • Line annotation.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringLine

    Swift

    static let line: Annotation.Tool
  • Polygon annotation.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringPolygon

    Swift

    static let polygon: Annotation.Tool
  • Polyline annotation.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringPolyLine

    Swift

    static let polyLine: Annotation.Tool
  • Signature annotation. This type applies to both signatures added using a certificate (digital signature) and the one added without it which is just a PSPDFAnnotationStringInk underneath.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringSignature

    Swift

    static let signature: Annotation.Tool
  • Stamp annotation.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringStamp

    Swift

    static let stamp: Annotation.Tool
  • Special type of “annotation” that allows you to (partially) erase (ink annotation) drawings.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringEraser

    Swift

    static let eraser: Annotation.Tool
  • Sound annotation. Can be played back and recorded by default, but by default playback and recording will not work when the host app is in the background. If you want to enable background playback and recording, you’ll need to add the “audio” entry to the UIBackgroundModes array in the app’s Info.plist. If you do not add this, then recording will be stopped and playback will be silenced when your app is sent into the background.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringSound

    Swift

    static let sound: Annotation.Tool
  • Image annotation. Is a PSPDFAnnotationStringStamp annotation. UIImagePickerController will be used to pick an image. This will throw a UIApplicationInvalidInterfaceOrientation exception if your app does not include portrait in UISupportedInterfaceOrientations (Info.plist). For landscape only apps, we suggest enabling portrait orientation(s) in your Info.plist and rejecting these in UIViewController’s auto-rotation methods. This way, you can be landscape only for your view controllers and still be able to use UIImagePickerController.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringImage

    Swift

    static let image: Annotation.Tool
  • Redaction annotation.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringRedaction

    Swift

    static let redaction: Annotation.Tool
  • Widget annotation. Includes PDF Forms. Non-writable annotation type.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringWidget

    Swift

    static let widget: Annotation.Tool
  • File attachment. Non-writable annotation type.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringFile

    Swift

    static let file: Annotation.Tool
  • Embedded PDF video. Non-writable annotation type.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringRichMedia

    Swift

    static let richMedia: Annotation.Tool
  • Embedded PDF video. Non-writable annotation type.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringScreen

    Swift

    static let screen: Annotation.Tool
  • Caret annotation. Non-writable annotation type.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringCaret

    Swift

    static let caret: Annotation.Tool
  • Popup annotation. Placeholder. Not yet supported.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringPopup

    Swift

    static let popup: Annotation.Tool
  • Watermark annotation. Placeholder. Not yet supported.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringWatermark

    Swift

    static let watermark: Annotation.Tool
  • TrapNet annotation. Placeholder. Not yet supported.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationStringTrapNet

    Swift

    static let trapNet: Annotation.Tool
  • 3D annotation. Placeholder. Not yet supported.

    Declaration

    Objective-C

    extern const PSPDFAnnotationString _Nonnull PSPDFAnnotationString3D

    Swift

    static let string3D: Annotation.Tool
  • NSValueTransformer to convert between PSPDFAnnotationBorderStyle enum and string value.

    Note

    The transformer is added in the class initialize phase. Requires PSPDFAnnotation to be accessed at least once.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(borderStyle) const PSPDFValueTransformerName
        PSPDFBorderStyleTransformerName

    Swift

    static let borderStyle: ValueTransformerName
  • NSValueTransformer to convert between PSPDFAnnotationBorderEffect enum and string value.

    Note

    The transformer is added in the class initialize phase. Requires PSPDFAnnotation to be accessed at least once.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(borderEffect) const PSPDFValueTransformerName
        PSPDFBorderEffectTransformerName

    Swift

    static let borderEffect: ValueTransformerName
  • NSValueTransformer to convert between PSPDFAnnotation.TriggerEvent enum and string value.

    Note

    The transformer is added in the class initialize phase. Requires PSPDFAnnotation to be accessed at least once.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(annotationTriggerEvent) const PSPDFValueTransformerName
        PSPDFAnnotationTriggerEventTransformerName

    Swift

    static let annotationTriggerEvent: ValueTransformerName
  • Default value for non-fixed-sized annotations

    Declaration

    Objective-C

    extern const CGSize PSPDFAnnotationFixedSizeDisabled

    Swift

    class let fixedSizeDisabled: CGSize
  • Key for attributed string attribute that contains the font size - this is set if the font size is defined.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFFontSizeName

    Swift

    let PSPDFFontSizeName: String
  • Key for vertical text alignment in fontAttributes.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFVerticalAlignmentName

    Swift

    let PSPDFVerticalAlignmentName: String
  • Key for the original font name when a fallback font is used to draw the the annotation’s content.

    When the font specified for an annotation with text contents isn’t available on the device, a fallback font will be used to render that text. In order to preserve this data, even when updating other aspects of the annotation, the original font name will be stored as an NSString under this key in the fontAttributes dictionary of the annotation while the fallback is in effect.

    As PSPDFKit will attempt to load the original font when possible, this value may be cleared later when the font has successfully been downloaded, and display of the annotation updated accordingly.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFOriginalFontNameAttributeName

    Swift

    let PSPDFOriginalFontNameAttributeName: String
  • Constant to convert PSPDFVerticalAlignment into NSString and back.

    Note

    The transformer is added in the class initialize phase. Requires PSPDFAnnotation to be accessed at least once.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(verticalAlignment) const PSPDFValueTransformerName
        PSPDFVerticalAlignmentTransformerName

    Swift

    static let verticalAlignment: ValueTransformerName
  • Pen Ink annotation, with preset styles for pen for drawing.

    Declaration

    Objective-C

    extern const PSPDFAnnotationVariantString _Nonnull PSPDFAnnotationVariantStringInkPen

    Swift

    static let inkPen: Annotation.Variant
  • Highlighter Ink annotation, with customized presets for improved text highlighting.

    Declaration

    Objective-C

    extern const PSPDFAnnotationVariantString _Nonnull PSPDFAnnotationVariantStringInkHighlighter

    Swift

    static let inkHighlighter: Annotation.Variant
  • Magic Ink annotation, which converts the drawn points to a vector shape if possible.

    Declaration

    Objective-C

    extern const PSPDFAnnotationVariantString _Nonnull PSPDFAnnotationVariantStringInkMagic

    Swift

    static let inkMagic: Annotation.Variant
  • Line annotation variant with an arrow at one end of the line.

    Declaration

    Objective-C

    extern const PSPDFAnnotationVariantString _Nonnull PSPDFAnnotationVariantStringLineArrow

    Swift

    static let lineArrow: Annotation.Variant
  • Text annotation variant that defaults to creating callout text annotations.

    Declaration

    Objective-C

    extern const PSPDFAnnotationVariantString _Nonnull PSPDFAnnotationVariantStringFreeTextCallout

    Swift

    static let freeTextCallout: Annotation.Variant
  • Notification posted on the main thread when new annotations are added to the default PSPDFContainerAnnotationProvider. The notification object is an NSArray containing the new PSPDFAnnotations.

    Declaration

    Objective-C

    extern const NSNotificationName _Nonnull PSPDFAnnotationsAddedNotification

    Swift

    static let PSPDFAnnotationsAdded: NSNotification.Name
  • Notification posted on the main thread when annotations are removed from the default PSPDFContainerAnnotationProvider. The notification object is an NSArray containing the removed PSPDFAnnotations.

    Declaration

    Objective-C

    extern const NSNotificationName _Nonnull PSPDFAnnotationsRemovedNotification

    Swift

    static let PSPDFAnnotationsRemoved: NSNotification.Name
  • Internal events to notify the annotation providers when annotations are being changed.

    Warning

    Only send from main thread! Don’t call save during a change notification.

    Note

    The notification’s object property is a PSPDFAnnotation instance.

    Declaration

    Objective-C

    extern const NSNotificationName _Nonnull PSPDFAnnotationChangedNotification

    Swift

    static let PSPDFAnnotationChanged: NSNotification.Name
  • Set to YES to disable handling by views.

    Declaration

    Objective-C

    extern NSString
        *const _Nonnull PSPDFAnnotationChangedNotificationIgnoreUpdateKey

    Swift

    let PSPDFAnnotationChangedNotificationIgnoreUpdateKey: String
  • NSArray of selector names.

    Note

    Properties will be prefixed with ‘is’ in Objective-C. For example, the deleted property becomes isDeleted.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFAnnotationChangedNotificationKeyPathKey

    Swift

    let PSPDFAnnotationChangedNotificationKeyPathKey: String
  • Controls if overlay annotations should be animated. Only applies to overlay. Defaults to YES if not explicitly set to NO.

    Note

    This is defined on the model layer to allow passing through animated: parameters.

    Declaration

    Objective-C

    extern const PSPDFAnnotationOption _Nonnull PSPDFAnnotationOptionAnimateView
  • Prevents the insertion or removal notifications from being sent (use a BOOL NSNumber value).

    Declaration

    Objective-C

    extern const PSPDFAnnotationOption _Nonnull PSPDFAnnotationOptionSuppressNotifications
  • Deprecated

    Deprecated in PSPDFKit 4.3 for macOS. Please use PSPDFAnnotationOptionAnimateView instead.

    Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT PSPDFAnnotationOption const PSPDFAnnotationOptionAnimateViewKey
  • Deprecated

    Deprecated in PSPDFKit 4.3 for macOS. Please use PSPDFAnnotationOptionSuppressNotifications instead.

    Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT PSPDFAnnotationOption const PSPDFAnnotationOptionSuppressNotificationsKey
  • Style key representing the annotation color property.

    Declaration

    Objective-C

    extern const PSPDFAnnotationStyleKey _Nonnull PSPDFAnnotationStyleKeyColor
  • Style key representing the annotation fillColor property.

    Declaration

    Objective-C

    extern const PSPDFAnnotationStyleKey _Nonnull PSPDFAnnotationStyleKeyFillColor
  • Style key representing the annotation alpha property.

    Declaration

    Objective-C

    extern const PSPDFAnnotationStyleKey _Nonnull PSPDFAnnotationStyleKeyAlpha
  • Style key representing the annotation lineWidth property.

    Declaration

    Objective-C

    extern const PSPDFAnnotationStyleKey _Nonnull PSPDFAnnotationStyleKeyLineWidth
  • Style key representing the annotation dashArray property.

    Declaration

    Objective-C

    extern const PSPDFAnnotationStyleKey _Nonnull PSPDFAnnotationStyleKeyDashArray
  • Style key representing the free text annotation lineEnd property (in callout mode).

    Note

    Applicable only to PSPDFFreeTextAnnotation.

    Declaration

    Objective-C

    extern const PSPDFAnnotationStyleKey _Nonnull PSPDFAnnotationStyleKeyLineEnd
  • Style key representing the abstract line annotation lineEnd1 property.

    Note

    Applicable only to PSPDFAbstractLineAnnotation subclasses.

    Declaration

    Objective-C

    extern const PSPDFAnnotationStyleKey _Nonnull PSPDFAnnotationStyleKeyLineEnd1
  • Style key representing the abstract line annotation lineEnd2 property.

    Note

    Applicable only to PSPDFAbstractLineAnnotation subclasses.

    Declaration

    Objective-C

    extern const PSPDFAnnotationStyleKey _Nonnull PSPDFAnnotationStyleKeyLineEnd2
  • Style key representing the annotation fontName property.

    Declaration

    Objective-C

    extern const PSPDFAnnotationStyleKey _Nonnull PSPDFAnnotationStyleKeyFontName
  • Style key representing the annotation fontSize property.

    Declaration

    Objective-C

    extern const PSPDFAnnotationStyleKey _Nonnull PSPDFAnnotationStyleKeyFontSize
  • Style key representing the annotation textAlignment property.

    Declaration

    Objective-C

    extern const PSPDFAnnotationStyleKey _Nonnull PSPDFAnnotationStyleKeyTextAlignment
  • Style key representing the annotation blendMode property.

    Declaration

    Objective-C

    extern const PSPDFAnnotationStyleKey _Nonnull PSPDFAnnotationStyleKeyBlendMode
  • Converting a regular free text annotation to a callout modifies multiple properties. This cannot be controlled with a single property and we use a special key for the change.

    Note

    Applicable only to PSPDFFreeTextAnnotation.

    Declaration

    Objective-C

    extern const PSPDFAnnotationStyleKey _Nonnull PSPDFAnnotationStyleKeyCalloutAction
  • Style key representing the outline color property of redactions.

    Note

    Applicable only to PSPDFRedactionAnnotation.

    Declaration

    Objective-C

    extern const PSPDFAnnotationStyleKey _Nonnull PSPDFAnnotationStyleKeyOutlineColor
  • Style key representing the overlay text property of redactions.

    Note

    Applicable only to PSPDFRedactionAnnotation.

    Declaration

    Objective-C

    extern const PSPDFAnnotationStyleKey _Nonnull PSPDFAnnotationStyleKeyOverlayText
  • Style key representing the property for repeating the overlay text of redactions.

    Note

    Applicable only to PSPDFRedactionAnnotation.

    Declaration

    Objective-C

    extern const PSPDFAnnotationStyleKey _Nonnull PSPDFAnnotationStyleKeyRepeatOverlayText
  • This key will return the last used style.

    Declaration

    Objective-C

    extern const PSPDFAnnotationStyleType _Nonnull PSPDFAnnotationStyleTypeLastUsed

    Swift

    static let lastUsed: AnnotationStyle.Kind
  • This key will mark styles as generic, thus they’ll be returned with all other style types except the last used trait.

    Declaration

    Objective-C

    extern const PSPDFAnnotationStyleType _Nonnull PSPDFAnnotationStyleTypeGeneric

    Swift

    static let generic: AnnotationStyle.Kind
  • Color preset type

    Declaration

    Objective-C

    extern const PSPDFAnnotationStyleType _Nonnull PSPDFAnnotationStyleTypeColorPreset

    Swift

    static let colorPreset: AnnotationStyle.Kind
  • Option for dataProviderForAnnotation:options:. If set, the resulting appearance stream is to be used for a flattened document.

    Declaration

    Objective-C

    extern const PSPDFAppearanceStreamGenerationOption _Nonnull PSPDFAppearanceGenerationFlatten

    Swift

    static let generationFlatten: AppearanceStreamGenerationOption
  • Option for dataProviderForAnnotation:options:. If set, the resulting appearance stream is to be used for printing.

    Declaration

    Objective-C

    extern const PSPDFAppearanceStreamGenerationOption _Nonnull PSPDFAppearanceGenerationPrint

    Swift

    static let generationPrint: AppearanceStreamGenerationOption
  • Policy for Open In.

    Declaration

    Objective-C

    extern const PSPDFPolicyEvent _Nonnull PSPDFPolicyEventOpenIn

    Swift

    static let openIn: PolicyEvent
  • Policy for print.

    Declaration

    Objective-C

    extern const PSPDFPolicyEvent _Nonnull PSPDFPolicyEventPrint

    Swift

    static let print: PolicyEvent
  • Policy for mail.

    Declaration

    Objective-C

    extern const PSPDFPolicyEvent _Nonnull PSPDFPolicyEventEmail

    Swift

    static let email: PolicyEvent
  • Policy for message.

    Declaration

    Objective-C

    extern const PSPDFPolicyEvent _Nonnull PSPDFPolicyEventMessage

    Swift

    static let message: PolicyEvent
  • Policy for Quick Look.

    Declaration

    Objective-C

    extern const PSPDFPolicyEvent _Nonnull PSPDFPolicyEventQuickLook

    Swift

    static let quickLook: PolicyEvent
  • Policy for audio recording.

    Declaration

    Objective-C

    extern const PSPDFPolicyEvent _Nonnull PSPDFPolicyEventAudioRecording

    Swift

    static let audioRecording: PolicyEvent
  • Policy for the camera.

    Declaration

    Objective-C

    extern const PSPDFPolicyEvent _Nonnull PSPDFPolicyEventCamera

    Swift

    static let camera: PolicyEvent
  • Policy for the photo library.

    Declaration

    Objective-C

    extern const PSPDFPolicyEvent _Nonnull PSPDFPolicyEventPhotoLibrary

    Swift

    static let photoLibrary: PolicyEvent
  • Policy for the pasteboard. Includes Copy/Paste.

    Declaration

    Objective-C

    extern const PSPDFPolicyEvent _Nonnull PSPDFPolicyEventPasteboard

    Swift

    static let pasteboard: PolicyEvent
  • Policy for submitting forms.

    Declaration

    Objective-C

    extern const PSPDFPolicyEvent _Nonnull PSPDFPolicyEventSubmitForm

    Swift

    static let submitForm: PolicyEvent
  • Policy for the network.

    Declaration

    Objective-C

    extern const PSPDFPolicyEvent _Nonnull PSPDFPolicyEventNetwork

    Swift

    static let network: PolicyEvent
  • Register to get notified when the bookmarks managed by the bookmark manager posting this notification change.

    A change is defined as adding, removing, or replacing a bookmark or changing its sort order.

    This notification is guaranteed to be posted on the main thread.

    Declaration

    Objective-C

    extern const NSNotificationName _Nonnull PSPDFBookmarksChangedNotification

    Swift

    static let PSPDFBookmarksChanged: NSNotification.Name
  • Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT NSString *const PSPDFCryptorErrorDomain

    Swift

    let PSPDFCryptorErrorDomain: String
  • Search glyphs.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFObjectsGlyphsKey

    Swift

    let PSPDFObjectsGlyphsKey: String
  • Always return full PSPDFWords. Implies PSPDFObjectsTextKey.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFObjectsWordsKey

    Swift

    let PSPDFObjectsWordsKey: String
  • Include Text.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFObjectsTextKey

    Swift

    let PSPDFObjectsTextKey: String
  • Include text blocks, sorted after most appropriate.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFObjectsTextBlocksKey

    Swift

    let PSPDFObjectsTextBlocksKey: String
  • Include Image info.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFObjectsImagesKey

    Swift

    let PSPDFObjectsImagesKey: String
  • Output category for annotations.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFObjectsAnnotationsKey

    Swift

    let PSPDFObjectsAnnotationsKey: String
  • Ignore too large text blocks (that are > 90% of a page)

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFObjectsIgnoreLargeTextBlocksKey

    Swift

    let PSPDFObjectsIgnoreLargeTextBlocksKey: String
  • Include annotations of attached type

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFObjectsAnnotationTypesKey

    Swift

    let PSPDFObjectsAnnotationTypesKey: String
  • Special case; used for PSPDFAnnotationTypeNote hit testing.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFObjectsAnnotationPageBoundsKey

    Swift

    let PSPDFObjectsAnnotationPageBoundsKey: String
  • Special case; Used to correctly hit test zoom-invariant annotations.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFObjectsPageZoomLevelKey

    Swift

    let PSPDFObjectsPageZoomLevelKey: String
  • Include annotations that are part of a group.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFObjectsAnnotationIncludedGroupedKey

    Swift

    let PSPDFObjectsAnnotationIncludedGroupedKey: String
  • Will sort words/annotations (smaller words/annotations first). Use for touch detection.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFObjectsSmartSortKey

    Swift

    let PSPDFObjectsSmartSortKey: String
  • Will use path-based hit-testing based on the center point if set. All annotations that support path based hit-testing but fail the test will be excluded from the results.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFObjectMinDiameterKey

    Swift

    let PSPDFObjectMinDiameterKey: String
  • Will look at the text flow and select full sentences, not just what’s within the rect.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFObjectsTextFlowKey

    Swift

    let PSPDFObjectsTextFlowKey: String
  • Will stop after finding the first matching object.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFObjectsFindFirstOnlyKey

    Swift

    let PSPDFObjectsFindFirstOnlyKey: String
  • Only relevant for rect. Will test for intersection instead of objects that are fully included in the pdfRect. Defaults to YES if not set.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFObjectsTestIntersectionKey

    Swift

    let PSPDFObjectsTestIntersectionKey: String
  • Only relevant if PSPDFObjectsTestIntersectionKey is set to YES. Test succeeds if the fraction of the overlapping area between the object and pdfRect is greater than the fraction set here. Defaults to 0 if not set, which means the test succeeds if there is any intersection at all. Valid values: 0 - 1.

    @note: The overlap is calculated w.r.t the total area. So, if ao is the area of the object, ap is the area of pdfRect and ai is the intersecting area, then the overlap proportion would be ai / (ao + ap - ai).

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFObjectsTestIntersectionFractionKey

    Swift

    let PSPDFObjectsTestIntersectionFractionKey: String
  • Set to @YES to force saving, even though there are no dirty objects. This is useful in combination with a rewrite, to remove unreferenced objects: PSPDFDocumentSaveOptionStrategy = @(PSPDFDocumentSaveStrategyRewrite)

    Declaration

    Objective-C

    extern const PSPDFDocumentSaveOption _Nonnull PSPDFDocumentSaveOptionForceSaving

    Swift

    static let forceSaving: PDFDocumentSaveOption
  • Defines the save strategy. Defaults to PSPDFDocumentSaveStrategyAppend

    Declaration

    Objective-C

    extern const PSPDFDocumentSaveOption _Nonnull PSPDFDocumentSaveOptionStrategy

    Swift

    static let strategy: PDFDocumentSaveOption
  • A PSPDFDocumentSecurityOptions instance, specifies the security options to use when saving the document. Not passing this options means the current security options will be used.

    Note

    Requires PSPDFFeatureMaskDocumentEditing to be part of your license.

    Declaration

    Objective-C

    extern const PSPDFDocumentSaveOption _Nonnull PSPDFDocumentSaveOptionSecurityOptions

    Swift

    static let securityOptions: PDFDocumentSaveOption
  • A BOOL value wrapped in an NSNumber. If set to YES, applies all redactions in the document and removes the content underneath them. Not passing this option means redactions are not applied, and redaction annotations will stay in the document.

    Note

    Requires PSPDFFeatureMaskRedaction to be part of your license.

    Declaration

    Objective-C

    extern const PSPDFDocumentSaveOption _Nonnull PSPDFDocumentSaveOptionApplyRedactions

    Swift

    static let applyRedactions: PDFDocumentSaveOption
  • A document posts an underlying file changed notification each time one of the backing files of the document is changed and the change did not originate from the document itself. When a file deletion can be detected, the same notification will be sent with a PSPDFDocumentUnderlyingFileWillBeDeletedKey in the user info. The notification will be sent on the main thread.

    Declaration

    Objective-C

    extern const NSNotificationName _Nonnull PSPDFDocumentUnderlyingFileChangedNotification

    Swift

    static let PSPDFDocumentUnderlyingFileChanged: NSNotification.Name
  • The underlying file url key identifies the file url of the changed file inside a PSPDFDocumentUnderlyingFileChangedNotification‘s user info dictionary. It is of type NSURL.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(changedFileURL) const
        PSPDFDocumentUnderlyingFileChangedNotificationOptions
        PSPDFDocumentUnderlyingFileURLKey

    Swift

    static let changedFileURL: Document.UnderlyingFileChangedNotificationOption
  • The underlying file url key identifies the data provider that registered the change inside a PSPDFDocumentUnderlyingFileChangedNotification‘s user info dictionary. It is of type id<PSPDFCoordinatedFileDataProviding>.

    Declaration

    Objective-C

    extern const PSPDFDocumentUnderlyingFileChangedNotificationOptions _Nonnull PSPDFDocumentUnderlyingDataProvider

    Swift

    static let dataProvider: Document.UnderlyingFileChangedNotificationOption
  • A boolean NSNumber indicating that the underlying file is about to be deleted.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(deleteFile) const
        PSPDFDocumentUnderlyingFileChangedNotificationOptions
        PSPDFDocumentUnderlyingFileWillBeDeletedKey

    Swift

    static let deleteFile: Document.UnderlyingFileChangedNotificationOption
  • Called before the document starts to save annotations. Use to save any unsaved changes.

    Declaration

    Objective-C

    extern const NSNotificationName _Nonnull PSPDFDocumentWillSaveAnnotationsNotification

    Swift

    static let PSPDFDocumentWillSaveAnnotations: NSNotification.Name
  • NSUserDefaults key for the default global annotation author name.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFDocumentDefaultAnnotationUsernameKey

    Swift

    let PSPDFDocumentDefaultAnnotationUsernameKey: String
  • Contains the boxed PSPDFAnnotationType to control appearance stream generation for each type.

    Declaration

    Objective-C

    extern const PSPDFAnnotationWriteOption _Nonnull PSPDFAnnotationWriteOptionGenerateAppearanceStreamForType

    Swift

    static let generateAppearanceStreamForType: Document.AnnotationWriteOption
  • The notification posted when a checkpoint is saved. The object sending this is the document’s checkpointer.

    Declaration

    Objective-C

    extern const NSNotificationName _Nonnull PSPDFDocumentCheckpointSavedNotification

    Swift

    static let PSPDFDocumentCheckpointSaved: NSNotification.Name
  • The key set in PSPDFDocumentCheckpointSavedNotification‘s userInfo that indicates (using a BOOL wrapped in a NSNumber) whether the checkpoint saved successfully or not.

    Declaration

    Objective-C

    extern NSString
        *const _Nonnull PSPDFDocumentCheckpointSavedNotificationSucessKey

    Swift

    let PSPDFDocumentCheckpointSavedNotificationSucessKey: String
  • The constant to be used to indicate that the key length should be determined automatically.

    Declaration

    Objective-C

    extern const NSUInteger PSPDFDocumentSecurityOptionsKeyLengthAutomatic
  • The XMP PDF namespace.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFXMPPDFNamespace

    Swift

    let PSPDFXMPPDFNamespace: String
  • The XMP PDF namespace prefix.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFXMPPDFNamespacePrefix

    Swift

    let PSPDFXMPPDFNamespacePrefix: String
  • The XMP Dublin Core namespace.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFXMPDCNamespace

    Swift

    let PSPDFXMPDCNamespace: String
  • The XMP Dublin Core namespace prefix.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFXMPDCNamespacePrefix

    Swift

    let PSPDFXMPDCNamespacePrefix: String
  • Posted whenever a task starts loading.

    Declaration

    Objective-C

    extern const NSNotificationName _Nonnull PSPDFDownloadManagerDidStartLoadingTaskNotification

    Swift

    static let PSPDFDownloadManagerDidStartLoadingTask: NSNotification.Name
  • Posted whenever a task finishes loading.

    Declaration

    Objective-C

    extern const NSNotificationName _Nonnull PSPDFDownloadManagerDidFinishLoadingTaskNotification

    Swift

    static let PSPDFDownloadManagerDidFinishLoadingTask: NSNotification.Name
  • Posted whenever a task failed to load.

    Declaration

    Objective-C

    extern const NSNotificationName _Nonnull PSPDFDownloadManagerDidFailToLoadTaskNotification

    Swift

    static let PSPDFDownloadManagerDidFailToLoadTask: NSNotification.Name
  • The default intensity used for legacy lines without explicit intensity data.

    Declaration

    Objective-C

    extern const CGFloat PSPDFDefaultIntensity

    Swift

    static let defaultIntensity: CGFloat
  • Point at location CGPointZero with intensity 0..

    Declaration

    Objective-C

    extern const PSPDFDrawingPoint PSPDFDrawingPointZero

    Swift

    static let zero: DrawingPoint
  • An invalid point with all components set to NaN.

    Declaration

    Objective-C

    extern const PSPDFDrawingPoint PSPDFDrawingPointNull

    Swift

    static let null: DrawingPoint
  • Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT NSNotificationName const PSPDFApplicationDidReceiveMemoryWarningNotification

    Swift

    static let PSPDFApplicationDidReceiveMemoryWarning: NSNotification.Name
  • The PSPDFKit Error Domain.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFErrorDomain

    Swift

    let PSPDFErrorDomain: String
  • Paperclip icon.

    Declaration

    Objective-C

    extern const PSPDFFileIconName _Nonnull PSPDFFileIconNamePaperclip

    Swift

    static let paperclip: FileAnnotation.IconName
  • Graph icon.

    Declaration

    Objective-C

    extern const PSPDFFileIconName _Nonnull PSPDFFileIconNameGraph

    Swift

    static let graph: FileAnnotation.IconName
  • Tag icon.

    Declaration

    Objective-C

    extern const PSPDFFileIconName _Nonnull PSPDFFileIconNameTag

    Swift

    static let tag: FileAnnotation.IconName
  • Pushpin icon.

    Declaration

    Objective-C

    extern const PSPDFFileIconName _Nonnull PSPDFFileIconNamePushPin

    Swift

    static let pushPin: FileAnnotation.IconName
  • Specifies whether the file manager should use file coordination when performing operations. Expects a boolean NSNumber.

    Declaration

    Objective-C

    extern const PSPDFFileManagerOption _Nonnull PSPDFFileManagerOptionCoordinatedAccess

    Swift

    static let coordinatedAccess: DefaultFileManager.Option
  • The optional NSFilePresenter object to pass to the internally created NSFileCoordinator when performing coordinated operations. See the NSFileCoordinator documentation for details. This is only relevant when PSPDFFileManagerOptionCoordinatedAccess is enabled.

    Declaration

    Objective-C

    extern const PSPDFFileManagerOption _Nonnull PSPDFFileManagerOptionFilePresenter

    Swift

    static let filePresenter: DefaultFileManager.Option
  • The minimum acceptable font to be used when editing fields with autosizing fonts.

    Declaration

    Objective-C

    static const CGFloat PSPDFMinimumAcceptableFontSize = 5.

    Swift

    let PSPDFMinimumAcceptableFontSize: CGFloat
  • NSValueTransformer to convert between PSPDFFreeTextAnnotationIntent enum and string value.

    Note

    The transformer is added in the class initialize phase. Requires PSPDFFreeTextAnnotation to be accessed at least once.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(freeTextAnnotationIntent) const PSPDFValueTransformerName
        PSPDFFreeTextAnnotationIntentTransformerName

    Swift

    static let freeTextAnnotationIntent: ValueTransformerName
  • An NSRange representing an invalid range of PSPDFGlyphs.

    Declaration

    Objective-C

    extern const NSRange PSPDFInvalidGlyphRange

    Swift

    let InvalidGlyphRange: NSRange
  • X-Callback URL, see http://x-callback-url.com

    Note

    This is used for the Chrome activity in PSPDFWebViewController. Example: PSPDFKitGlobal.sharedInstance[PSPDFSettingKeyXCallbackURLString] = @"pspdfcatalog://";

    Declaration

    Objective-C

    extern const PSPDFSettingKey _Nonnull PSPDFSettingKeyXCallbackURLString

    Swift

    static let xCallbackURLString: SDK.Setting
  • Custom PSPDFApplicationPolicy instance that can be configured with setLicenseKey:options:.

    Declaration

    Objective-C

    extern const PSPDFSettingKey _Nonnull PSPDFSettingKeyApplicationPolicy

    Swift

    static let applicationPolicy: SDK.Setting
  • Custom PSPDFFileManager instance that can be configured with setLicenseKey:options:.

    Declaration

    Objective-C

    extern const PSPDFSettingKey _Nonnull PSPDFSettingKeyFileManager

    Swift

    static let fileManager: SDK.Setting
  • Custom coordinated PSPDFFileManager instance that can be configured with setLicenseKey:options:.

    Declaration

    Objective-C

    extern const PSPDFSettingKey _Nonnull PSPDFSettingKeyCoordinatedFileManager

    Swift

    static let coordinatedFileManager: SDK.Setting
  • Specifies whether coordinated file operations are used by default in PSPDFDocument. Creates PSPDFCoordinatedFileDataProviders when initializing documents with local URLs. Expects a boolean NSNumber. Defaults to @YES. Set to @NO to disable.

    Declaration

    Objective-C

    extern const PSPDFSettingKey _Nonnull PSPDFSettingKeyFileCoordinationEnabled

    Swift

    static let fileCoordinationEnabled: SDK.Setting
  • Specifies the indexing priority that the shared PSPDFLibrary instance must use. Must be a valid PSPDFLibraryIndexingPriority value wrapped in a NSNumber. SeePSPDFLibraryIndexingPriority` for details.

    Declaration

    Objective-C

    extern const PSPDFSettingKey _Nonnull PSPDFSettingKeyLibraryIndexingPriority

    Swift

    static let libraryIndexingPriority: SDK.Setting
  • Enables various debug UI options. (e.g. more settings)

    Declaration

    Objective-C

    extern const PSPDFSettingKey _Nonnull PSPDFSettingKeyDebugMode

    Swift

    static let debugMode: SDK.Setting
  • Allows you to specify additional font directories. Expects an array of strings.

    Some PDFs don’t contain embedded fonts and sometimes the system fonts don’t provide a good enough replacement. In that case, you can ship your own fonts and point PSPDFKit to your additional font directories.

    Declaration

    Objective-C

    extern const PSPDFSettingKey _Nonnull PSPDFSettingKeyAdditionalFontDirectories

    Swift

    static let additionalFontDirectories: SDK.Setting
  • Specifies whether PSPDFDocument permissions are honored in the PSPDFKit UI.

    PSPDFKit will honor certain PDF permissions and prevent corresponding UI actions, such as editing annotations, if the document disallows them. This option can be used to globally disable this behavior and instead allow all configured UI actions regardless of document permissions.

    Note

    This option will affect the output of PSPDFDocument.features while PSPDFDocument.permissions will still reflect the actual values configured in the PDF document. For documents that were instantiated before changing this option, [document.features updateFeatures] needs to be invoked to ensure the changes are correctly reflected in the features system.

    Expects a boolean NSNumber. Defaults to @YES. Set to @NO to disable.

    Declaration

    Objective-C

    extern const PSPDFSettingKey _Nonnull PSPDFSettingKeyHonorDocumentPermissions

    Swift

    static let honorDocumentPermissions: SDK.Setting
  • Deprecated

    Deprecated in PSPDFKit 4.x for macOS. Compatibility constant. Please migrate to PSPDFFeatureMaskRequireSignedSource

    Objective-C source compatibility with 9.2.x and older.

    Declaration

    Objective-C

    extern const PSPDFFeatureMask PSPDFFeatureRequireSignedSource

    Swift

    let PSPDFFeatureRequireSignedSource: Features
  • Deprecated

    Deprecated in PSPDFKit 4.3 for macOS. Please use PSPDFSettingKeyXCallbackURLString instead.

    Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT PSPDFSettingKey const PSPDFXCallbackURLStringKey

    Swift

    static let PSPDFXCallbackURLStringKey: SDK.Setting
  • Deprecated

    Deprecated in PSPDFKit 4.3 for macOS. Please use PSPDFSettingKeyApplicationPolicy instead.

    Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT PSPDFSettingKey const PSPDFApplicationPolicyKey

    Swift

    static let applicationPolicyKey: SDK.Setting
  • Deprecated

    Deprecated in PSPDFKit 4.3 for macOS. Please use PSPDFSettingKeyFileManager instead.

    Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT PSPDFSettingKey const PSPDFFileManagerKey

    Swift

    static let fileManagerKey: SDK.Setting
  • Deprecated

    Deprecated in PSPDFKit 4.3 for macOS. Please use PSPDFSettingKeyCoordinatedFileManager instead.

    Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT PSPDFSettingKey const PSPDFCoordinatedFileManagerKey

    Swift

    static let coordinatedFileManagerKey: SDK.Setting
  • Deprecated

    Deprecated in PSPDFKit 4.3 for macOS. Please use PSPDFSettingKeyFileCoordinationEnabled instead.

    Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT PSPDFSettingKey const PSPDFFileCoordinationEnabledKey

    Swift

    static let fileCoordinationEnabledKey: SDK.Setting
  • Deprecated

    Deprecated in PSPDFKit 4.3 for macOS. Please use PSPDFSettingKeyLibraryIndexingPriority instead.

    Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT PSPDFSettingKey const PSPDFLibraryIndexingPriorityKey

    Swift

    static let libraryIndexingPriorityKey: SDK.Setting
  • Deprecated

    Deprecated in PSPDFKit 4.3 for macOS. Please use PSPDFSettingKeyDebugMode instead.

    Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT PSPDFSettingKey const PSPDFKitDebugModeKey

    Swift

    static let kitDebugModeKey: SDK.Setting
  • Deprecated

    Deprecated in PSPDFKit 4.3 for macOS. Please use PSPDFSettingKeyAdditionalFontDirectories instead.

    Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT PSPDFSettingKey const PSPDFAdditionalFontDirectories

    Swift

    static let additionalFontDirectories: SDK.Setting
  • Deprecated

    Deprecated in PSPDFKit 4.3 for macOS. Please use PSPDFSettingKeyHonorDocumentPermissions instead.

    Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT PSPDFSettingKey const PSPDFHonorDocumentPermissionsKey

    Swift

    static let honorDocumentPermissionsKey: SDK.Setting
  • The library version.

    Declaration

    Objective-C

    extern const NSUInteger PSPDFLibraryVersion

    Swift

    let PSPDFLibraryVersion: UInt
  • PSPDFLibrary uses NSNotifications to post status updates.

    Declaration

    Objective-C

    extern const NSNotificationName _Nonnull PSPDFLibraryWillStartIndexingDocumentNotification

    Swift

    static let PSPDFLibraryWillStartIndexingDocument: NSNotification.Name
  • Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT NSNotificationName const PSPDFLibraryDidFinishIndexingDocumentNotification

    Swift

    static let PSPDFLibraryDidFinishIndexingDocument: NSNotification.Name
  • Sent when a document is removed from the library.

    Declaration

    Objective-C

    extern const NSNotificationName _Nonnull PSPDFLibraryDidRemoveDocumentNotification

    Swift

    static let PSPDFLibraryDidRemoveDocument: NSNotification.Name
  • Sent when all indexes are cleared as a result of -[PSPDFLibrary clearAllIndexes].

    Declaration

    Objective-C

    extern const NSNotificationName _Nonnull PSPDFLibraryDidClearIndexesNotification

    Swift

    static let PSPDFLibraryDidClearIndexes: NSNotification.Name
  • The key in the NSNotification userInfo for the UID of the document.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFLibraryNotificationUIDKey

    Swift

    let PSPDFLibraryNotificationUIDKey: String
  • The key in the NSNotification userInfo if the indexing operation was successful.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFLibraryNotificationSuccessKey

    Swift

    let PSPDFLibraryNotificationSuccessKey: String
  • The name of the exception thrown when an invalid operation occurs.

    Declaration

    Objective-C

    extern const NSExceptionName _Nonnull PSPDFLibraryInvalidOperationException

    Swift

    static let PSPDFLibraryInvalidOperationException: NSExceptionName
  • The name of PSPDFKit’s custom porter tokenizer.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFLibraryPorterTokenizerName

    Swift

    let PSPDFLibraryPorterTokenizerName: String
  • The name of PSPDFKit’s custom Unicode tokenizer. This tokenizer wraps around SQLite’s unicode61 tokenizer to add full case folding to the indexed text.

    Warning

    This tokenizer is only available when the library supports FTS5. Specifying this as the value for the PSPDFLibrary.tokenizer property will result in an error when trying to create the library.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(PDFLibrary.UnicodeTokenizerName) NSString *const
        PSPDFLibraryUnicodeTokenizerName

    Swift

    class let UnicodeTokenizerName: String
  • Option keys. Limit the number of document results.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFLibraryMaximumSearchResultsTotalKey

    Swift

    let PSPDFLibraryMaximumSearchResultsTotalKey: String
  • Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT NSString *const PSPDFLibraryMaximumSearchResultsPerDocumentKey

    Swift

    let PSPDFLibraryMaximumSearchResultsPerDocumentKey: String
  • Limit the number of preview results.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFLibraryMaximumPreviewResultsTotalKey

    Swift

    let PSPDFLibraryMaximumPreviewResultsTotalKey: String
  • Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT NSString *const PSPDFLibraryMaximumPreviewResultsPerDocumentKey

    Swift

    let PSPDFLibraryMaximumPreviewResultsPerDocumentKey: String
  • Set this to @YES to restrict search to exact word matches instead of beginsWith/endsWith checks.

    Warning

    If the default tokenizer is used, this will impact performance. If you find it is too slow, consider using a different tokenizer. See https://pspdfkit.com/guides/ios/current/features/indexed-full-text-search/

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFLibraryMatchExactWordsOnlyKey

    Swift

    let PSPDFLibraryMatchExactWordsOnlyKey: String
  • Set this to @YES to restrict search to exact phrase matches. This means that “Lorem ipsum dolor” only matches that phrase and not something like “Lorem sit ipsum dolor”.

    Warning

    If the default tokenizer is used, this will impact performance. If you find it is too slow, consider using a different tokenizer. See https://pspdfkit.com/guides/ios/current/features/indexed-full-text-search/

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFLibraryMatchExactPhrasesOnlyKey

    Swift

    let PSPDFLibraryMatchExactPhrasesOnlyKey: String
  • Set this to @YES to exclude annotations from the search. By default, indexed annotations will be searched.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFLibraryExcludeAnnotationsKey

    Swift

    let PSPDFLibraryExcludeAnnotationsKey: String
  • Set this to @YES to include document text from the search. By default, indexed document text will be searched.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFLibraryExcludeDocumentTextKey

    Swift

    let PSPDFLibraryExcludeDocumentTextKey: String
  • Customizes the range of the preview string. Defaults to 20/160.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFLibraryPreviewRangeKey

    Swift

    let PSPDFLibraryPreviewRangeKey: String
  • Metadata key for the document title. Object will be of type String.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(title) const PSPDFMetadataName PSPDFMetadataTitleKey
  • Metadata key for the document author. Object will be of type String.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(author) const PSPDFMetadataName PSPDFMetadataAuthorKey
  • Metadata key for the document subject. Object will be of type String.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(subject) const PSPDFMetadataName PSPDFMetadataSubjectKey
  • Metadata key for the document keywords. Object will be of type String.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(keywords) const PSPDFMetadataName PSPDFMetadataKeywordsKey
  • Metadata key for the document creator. Object will be of type String.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(creator) const PSPDFMetadataName PSPDFMetadataCreatorKey
  • Metadata key for the document producer. Object will be of type String.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(producer) const PSPDFMetadataName PSPDFMetadataProducerKey
  • Metadata key for the document creation date. Object will be of type Date.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(creationDate) const PSPDFMetadataName
        PSPDFMetadataCreationDateKey
  • Metadata key for the document modification date. Object will be of type Date.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(modificationDate) const PSPDFMetadataName
        PSPDFMetadataModDateKey
  • Metadata key for the document’s trapped value. Object will be of type String.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(trapped) const PSPDFMetadataName PSPDFMetadataTrappedKey
  • Transforms named actions to enum type and back.

    Note

    The transformer is added in the class initialize phase. Requires PSPDFNamedAction to be accessed at least once.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(namedActionType) const PSPDFValueTransformerName
        PSPDFNamedActionTypeTransformerName

    Swift

    static let namedActionType: ValueTransformerName
  • Marks an unused or invalid page number.

    Declaration

    Objective-C

    static const PSPDFPageIndex PSPDFPageNull = (9223372036854775807L * 2UL + 1UL)

    Swift

    let PSPDFPageNull: PageIndex
  • Specifies a blank page.

    Declaration

    Objective-C

    extern const PSPDFTemplateIdentifier _Nonnull PSPDFTemplateIdentifierBlank

    Swift

    static let blank: PageTemplate.Identifier
  • Specifies a pattern for a new page with a dot grid that is 5mm apart.

    Declaration

    Objective-C

    extern const PSPDFTemplateIdentifier _Nonnull PSPDFTemplateIdentifierDot5mm

    Swift

    static let dot5mm: PageTemplate.Identifier
  • Specifies a pattern for a new page with a grid that is 5mm apart.

    Declaration

    Objective-C

    extern const PSPDFTemplateIdentifier _Nonnull PSPDFTemplateIdentifierGrid5mm

    Swift

    static let grid5mm: PageTemplate.Identifier
  • Specifies a pattern for a new page with lines that are 5mm apart.

    Declaration

    Objective-C

    extern const PSPDFTemplateIdentifier _Nonnull PSPDFTemplateIdentifierLines5mm

    Swift

    static let lines5mm: PageTemplate.Identifier
  • Specifies a pattern for a new page with lines that are 7mm apart.

    Declaration

    Objective-C

    extern const PSPDFTemplateIdentifier _Nonnull PSPDFTemplateIdentifierLines7mm

    Swift

    static let lines7mm: PageTemplate.Identifier
  • Specifies a pattern for a new page with image.

    Declaration

    Objective-C

    extern const PSPDFTemplateIdentifier _Nonnull PSPDFTemplateIdentifierImage

    Swift

    static let image: PageTemplate.Identifier
  • NSValueTransformer to convert between PSPDFPolygonAnnotationIntent enum and string value.

    Note

    The transformer is added in the class initialize phase. Requires PSPDFPolygonAnnotation to be accessed at least once.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(polygonAnnotationIntent) const PSPDFValueTransformerName
        PSPDFPolygonAnnotationIntentTransformerName

    Swift

    static let polygonAnnotationIntent: ValueTransformerName
  • Available keys for options. PSPDFProcessorAnnotationDictKey in form of pageIndex -> annotations. Annotations will be flattened when type is set, unless PSPDFProcessorAnnotationAsDictionaryKey is also set. Don’t forget to also define the types of annotations that should be processed: PSPDFProcessorAnnotationTypesKey: @(PSPDFAnnotationTypeAll).

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFProcessorAnnotationTypesKey

    Swift

    let PSPDFProcessorAnnotationTypesKey: String
  • Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT NSString *const PSPDFProcessorAnnotationDictKey

    Swift

    let PSPDFProcessorAnnotationDictKey: String
  • Set to @YES to add annotations as dictionary and don’t flatten them. Dictionary keys are the original page indexes.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFProcessorAnnotationAsDictionaryKey

    Swift

    let PSPDFProcessorAnnotationAsDictionaryKey: String
  • Specifies the user password that should be set on the generated PDF.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFProcessorUserPasswordKey

    Swift

    let PSPDFProcessorUserPasswordKey: String
  • Specifies the owner password that should be set on the generated PDF.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFProcessorOwnerPasswordKey

    Swift

    let PSPDFProcessorOwnerPasswordKey: String
  • Specifies the key length that should be used to encrypt the PDF. Value must be divisible by 8 and in the range of 40 to 128.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFProcessorKeyLengthKey

    Swift

    let PSPDFProcessorKeyLengthKey: String
  • Defaults to PSPDFPaperSizeA4

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFProcessorPageRectKey

    Swift

    let PSPDFProcessorPageRectKey: String
  • Defaults to 10. Set lower to optimize, higher if you have a lot of content.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFProcessorNumberOfPagesKey

    Swift

    let PSPDFProcessorNumberOfPagesKey: String
  • Defines the page margin. Defaults to UIEdgeInsetsMake(5, 5, 5, 5).

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFProcessorPageBorderMarginKey

    Swift

    let PSPDFProcessorPageBorderMarginKey: String
  • If you print web pages, they might load async content which can’t be reliably detected. Defaults to 0.05 seconds. Set higher if you get blank pages.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFProcessorAdditionalDelayKey

    Swift

    let PSPDFProcessorAdditionalDelayKey: String
  • Defaults to NO. Adds an additional step to strip white pages if you’re getting any at the end.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFProcessorStripEmptyPagesKey

    Swift

    let PSPDFProcessorStripEmptyPagesKey: String
  • Common page sizes. Use for PSPDFProcessorPageRectKey.

    Declaration

    Objective-C

    extern const CGRect PSPDFPaperSizeA4

    Swift

    let PSPDFPaperSizeA4: CGRect
  • Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT const CGRect PSPDFPaperSizeLetter

    Swift

    let PSPDFPaperSizeLetter: CGRect
  • common options Will override any defaults if set.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFProcessorDocumentTitleKey

    Swift

    let PSPDFProcessorDocumentTitleKey: String
  • This notification is triggered if something happens that changes the way a page looks.

    The user info dictionary of this notification always contains the key PSPDFRenderManagerRenderResultChangedDocumentKey which contains the document that changed and optionally PSPDFRenderManagerRenderResultChangedPagesKey which contains an index set of the pages that changed within this document.

    If a document was changed e.g. by adding or removing an annotation, this notification tells you that the render engine and the cache have been updated and scheduling a new render task is guaranteed to return the new state of the document.

    In other words: If you constantly want to show up to date data, observe this notification and request a new image when this notification is posted.

    Note

    This notification is posted on an arbitrary queue. If you need to react on this on the main queue, you need to switch to the main queue yourself.

    Declaration

    Objective-C

    extern const NSNotificationName _Nonnull PSPDFRenderManagerRenderResultDidChangeNotification

    Swift

    static let PSPDFRenderManagerRenderResultDidChange: NSNotification.Name
  • The key of a PSPDFRenderManagerRenderResultDidChangeNotification userInfo’s dictionary, containing the PSPDFDocument that was changed.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFRenderManagerRenderResultChangedDocumentKey

    Swift

    let PSPDFRenderManagerRenderResultChangedDocumentKey: String
  • The key of a PSPDFRenderManagerRenderResultDidChangeNotification userInfo’s dictionary, containing an NSIndexSet with all the relevant pages. If the entry for this key in the user info dictionary is nil, the whole document should be treated as changed.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFRenderManagerRenderResultChangedPagesKey

    Swift

    let PSPDFRenderManagerRenderResultChangedPagesKey: String
  • The PSPDFPageInfo object containing page info.

    Declaration

    Objective-C

    extern NSString *const _Nonnull PSPDFPageRendererPageInfoKey

    Swift

    let PSPDFPageRendererPageInfoKey: String
  • Absolute limit for image rendering (memory constraint)

    Declaration

    Objective-C

    extern const CGSize PSPDFRenderSizeLimit

    Swift

    let PSPDFRenderSizeLimit: CGSize
  • Transforms a rendition action type enum to string and back.

    Note

    The transformer is added in the class initialize phase. Requires PSPDFRenditionAction to be accessed at least once.

    Declaration

    Objective-C

    extern NS_SWIFT_NAME(renditionActionType) const PSPDFValueTransformerName
        PSPDFRenditionActionTypeTransformerName

    Swift

    static let renditionActionType: ValueTransformerName
  • Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT NSString *const PSPDFSignerErrorDomain

    Swift

    let PSPDFSignerErrorDomain: String
  • Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT PSPDFSoundAnnotationEncoding const PSPDFSoundAnnotationEncodingRaw

    Swift

    static let raw: SoundAnnotation.Encoding
  • Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT PSPDFSoundAnnotationEncoding const PSPDFSoundAnnotationEncodingSigned

    Swift

    static let signed: SoundAnnotation.Encoding
  • Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT PSPDFSoundAnnotationEncoding const PSPDFSoundAnnotationEncodingMuLaw

    Swift

    static let muLaw: SoundAnnotation.Encoding
  • Undocumented

    Declaration

    Objective-C

    PSPDF_EXPORT PSPDFSoundAnnotationEncoding const PSPDFSoundAnnotationEncodingALaw

    Swift

    static let aLaw: SoundAnnotation.Encoding
  • Posted when recording or playback is started, paused or stopped.

    Declaration

    Objective-C

    extern const NSNotificationName _Nonnull PSPDFSoundAnnotationChangedStateNotification

    Swift

    static let PSPDFSoundAnnotationChangedState: NSNotification.Name
  • Posted when +stopRecordingOrPlaybackForAllExcept: is invoked.

    Declaration

    Objective-C

    extern const NSNotificationName _Nonnull PSPDFSoundAnnotationStopAllNotification

    Swift

    static let PSPDFSoundAnnotationStopAll: NSNotification.Name
  • A green checkmark stamp. Does not display text. From Adobe Acrobat’s Sign Here stamps.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeAccepted

    Swift

    static let accepted: StampAnnotation.Kind
  • A green stamp that displays the text ‘APPROVED’ in English. From Adobe Acrobat’s Standard Business stamps.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeApproved

    Swift

    static let approved: StampAnnotation.Kind
  • A stamp that displays the text ‘AS IS’ in English. From the PDF specification.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeAsIs

    Swift

    static let asIs: StampAnnotation.Kind
  • A green stamp that displays the text ‘COMPLETED’ in English. From Adobe Acrobat’s Standard Business stamps.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeCompleted

    Swift

    static let completed: StampAnnotation.Kind
  • A stamp that displays the text ‘CONFIDENTIAL’ in English. From Adobe Acrobat’s Standard Business stamps.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeConfidential

    Swift

    static let confidential: StampAnnotation.Kind
  • A stamp that displays the text ‘DEPARTMENTAL’ in English. From the PDF specification.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeDepartmental

    Swift

    static let departmental: StampAnnotation.Kind
  • A stamp that displays the text ‘DRAFT’ in English. From Adobe Acrobat’s Standard Business stamps.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeDraft

    Swift

    static let draft: StampAnnotation.Kind
  • A stamp that displays the text ‘EXPERIMENTAL’ in English. From the PDF specification.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeExperimental

    Swift

    static let experimental: StampAnnotation.Kind
  • A stamp that displays the text ‘EXPIRED’ in English. From the PDF specification.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeExpired

    Swift

    static let expired: StampAnnotation.Kind
  • A green stamp that displays the text ‘FINAL’ in English. From Adobe Acrobat’s Standard Business stamps.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeFinal

    Swift

    static let final: StampAnnotation.Kind
  • A stamp that displays the text ‘FOR COMMENT’ in English. From Adobe Acrobat’s Standard Business stamps.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeForComment

    Swift

    static let forComment: StampAnnotation.Kind
  • A stamp that displays the text ‘FOR PUBLIC RELEASE’ in English. From Adobe Acrobat’s Standard Business stamps.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeForPublicRelease

    Swift

    static let forPublicRelease: StampAnnotation.Kind
  • A stamp that displays the text ‘INFORMATION ONLY’ in English. From Adobe Acrobat’s Standard Business stamps.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeInformationOnly

    Swift

    static let informationOnly: StampAnnotation.Kind
  • A stamp with a left-pointing arrow that displays the text ‘INITIAL HERE’ in English. From Adobe Acrobat’s Sign Here stamps.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeInitialHere

    Swift

    static let initialHere: StampAnnotation.Kind
  • A red stamp that displays the text ‘NOT APPROVED’ in English. From Adobe Acrobat’s Standard Business stamps.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeNotApproved

    Swift

    static let notApproved: StampAnnotation.Kind
  • A stamp that displays the text ‘NOT FOR PUBLIC RELEASE’ in English. From Adobe Acrobat’s Standard Business stamps.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeNotForPublicRelease

    Swift

    static let notForPublicRelease: StampAnnotation.Kind
  • A stamp that displays the text ‘PRELIMINARY RESULTS’ in English. From Adobe Acrobat’s Standard Business stamps.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypePreliminaryResults

    Swift

    static let preliminaryResults: StampAnnotation.Kind
  • A red cross stamp. Does not display text. From Adobe Acrobat’s Sign Here stamps.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeRejected

    Swift

    static let rejected: StampAnnotation.Kind
  • A stamp that displays the text ‘REVISED’ in English. From Adobe Acrobat’s Dynamic stamps.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeRevised

    Swift

    static let revised: StampAnnotation.Kind
  • A red stamp with a left-pointing arrow that displays the text ‘SIGN HERE’ in English. From Adobe Acrobat’s Sign Here stamps.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeSignHere

    Swift

    static let signHere: StampAnnotation.Kind
  • A stamp that displays the text ‘SOLD’ in English. From the PDF specification.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeSold

    Swift

    static let sold: StampAnnotation.Kind
  • A stamp that displays the text ‘TOP SECRET’ in English. From the PDF specification.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeTopSecret

    Swift

    static let topSecret: StampAnnotation.Kind
  • A red stamp that displays the text ‘VOID’ in English. From Adobe Acrobat’s Standard Business stamps.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeVoid

    Swift

    static let void: StampAnnotation.Kind
  • A yellow stamp with a left-pointing arrow that displays the text ‘WITNESS’ in English. From Adobe Acrobat’s Sign Here stamps.

    Declaration

    Objective-C

    extern const PSPDFStampType _Nonnull PSPDFStampTypeWitness

    Swift

    static let witness: StampAnnotation.Kind
  • Mask for all text markups. PSPDFAnnotationTypeHighlight|PSPDFAnnotationTypeStrikeOut|PSPDFAnnotationTypeUnderline|PSPDFAnnotationTypeSquiggly

    Declaration

    Objective-C

    extern const PSPDFAnnotationType PSPDFAnnotationTypeTextMarkup

    Swift

    let PSPDFAnnotationTypeTextMarkup: Annotation.Kind
  • Sent once we have new undo operations available.

    Note

    Always sent on the main thread.

    Declaration

    Objective-C

    extern const NSNotificationName _Nonnull PSPDFUndoControllerAddedUndoActionNotification

    Swift

    static let PSPDFUndoControllerAddedUndoAction: NSNotification.Name
  • Sent once we have available undo actions have been changed/removed.

    Note

    Always sent on the main thread.

    Declaration

    Objective-C

    extern const NSNotificationName _Nonnull PSPDFUndoControllerRemovedUndoActionNotification

    Swift

    static let PSPDFUndoControllerRemovedUndoAction: NSNotification.Name