PSPDFPageInfo


@interface PSPDFPageInfo : NSObject <NSCopying, NSSecureCoding>

Represents PDF page data. Managed within PSPDFDocumentProvider.

  • Unavailable

    Undocumented

    Declaration

    Objective-C

    PSPDF_EMPTY_INIT_UNAVAILABLE
  • Unavailable

    Undocumented

    Declaration

    Objective-C

    PSPDF_EMPTY_INIT_UNAVAILABLE
  • Referenced page, relative to the document provider.

    Declaration

    Objective-C

    @property (readonly, nonatomic) PSPDFPageIndex pageIndex;

    Swift

    var pageIndex: PageIndex { get }
  • Referenced document provider.

    Declaration

    Objective-C

    @property (readonly, nonatomic)
        PSPDFDocumentProvider *_Nullable documentProvider;

    Swift

    weak var documentProvider: PSPDFDocumentProvider? { get }
  • The visible size of the page. This considers page rotation.

    Declaration

    Objective-C

    @property (readonly, nonatomic) CGSize size;

    Swift

    var size: CGSize { get }
  • Saved clockwise rotation of page in degrees. The possible values are 0, 90, 180 and 270.

    Declaration

    Objective-C

    @property (readonly, nonatomic) PSPDFRotation savedRotation;

    Swift

    var savedRotation: Rotation { get }
  • The manually set clockwise rotation of the page relative to its saved rotation.

    The orientation of a page may be modified for display using -[PSPDFDocumentProvider setRotationOffset:forPageAtIndex:] without writing to the PDF. The possible values are 0, 90, 180 and 270. The final rotation a page appears is the sum of rotation and rotationOffset.

    Declaration

    Objective-C

    @property (readonly, nonatomic) PSPDFRotation rotationOffset;

    Swift

    var rotationOffset: Rotation { get }
  • Page transform matrix.

    This uses the rotation and CropBox to map from the raw PDF coordinate space to the normalized PDF coordinate space. Applying this transform to the CropBox will give a rectange with zero origin and a size equal to the size property.

    Declaration

    Objective-C

    @property (readonly, nonatomic) CGAffineTransform transform;

    Swift

    var transform: CGAffineTransform { get }
  • Returns the media box that is set in the PDF. This is in PDF coordinates, straight from the PDF.

    @note: This might return CGRectNull if there’s no MediaBox set.

    Declaration

    Objective-C

    @property (readonly, nonatomic) CGRect mediaBox;

    Swift

    var mediaBox: CGRect { get }
  • Returns the crop box that is set in the PDF. This is in PDF coordinates, straight from the PDF.

    @note: This might return CGRectNull if there’s no CropBox set.

    Declaration

    Objective-C

    @property (readonly, nonatomic) CGRect cropBox;

    Swift

    var cropBox: CGRect { get }
  • Defines additional page actions. Key is PSPDFPageTriggerEvent, value a PSPDFAction instance.

    Declaration

    Objective-C

    @property (readonly, copy, nonatomic, nullable)
        NSDictionary<NSNumber *, PSPDFAction *> *additionalActions;

    Swift

    var additionalActions: [NSNumber : PSPDFAction]? { get }
  • Can be used to selectively disable annotation creation on the page. This feature is a proprietary PSPDFKit extension. To disable annotation creation add a boolean key (PSPDF:AllowAnnotationCreation) to the PDF page dictionary and set it to false.

    Declaration

    Objective-C

    @property (readonly, nonatomic) BOOL allowAnnotationCreation;

    Swift

    var allowAnnotationCreation: Bool { get }