PSPDFNewPageConfiguration


@interface PSPDFNewPageConfiguration : NSObject

This class configures a new page for the PSPDFProcessor or PSPDFDocumentEditor. You can configure what type of page it should be and also add images or logos from a PDF.

  • Unavailable

    Undocumented

    Declaration

    Objective-C

    PSPDF_EMPTY_INIT_UNAVAILABLE
  • Unavailable

    Undocumented

    Declaration

    Objective-C

    PSPDF_EMPTY_INIT_UNAVAILABLE
  • Instantiates a new page configuration from the provided template and configuration block.

    Declaration

    Objective-C

    + (nonnull instancetype)
    newPageConfigurationWithPageTemplate:(nonnull PSPDFPageTemplate *)pageTemplate
                            builderBlock:
                                (nullable void (^)(PSPDFNewPageConfigurationBuilder
                                                       *_Nonnull))builderBlock;

    Swift

    convenience init(pageTemplate: PSPDFPageTemplate, builderBlock: ((PSPDFNewPageConfigurationBuilder) -> Void)? = nil)

    Parameters

    pageTemplate

    The PSPDFPageTemplate to use for the new page configuration.

    builderBlock

    Block that’ll be executed to build the new page configuration.

    Return Value

    PSPDFNewPageConfiguration instance.

  • The configured page size. If this is CGSizeZero, the size of the first page in the resulting document will be used.

    Declaration

    Objective-C

    @property (readonly, nonatomic) CGSize pageSize;

    Swift

    var pageSize: CGSize { get }
  • The configured page rotation. Can only be 0, 90, 180 or 270.

    Declaration

    Objective-C

    @property (readonly, nonatomic) PSPDFRotation pageRotation;

    Swift

    var pageRotation: Rotation { get }
  • The configured background color. If nil, no background color will be set in the resulting page.

    Declaration

    Objective-C

    @property (readonly, nonatomic, nullable) UIColor *backgroundColor;

    Swift

    var backgroundColor: UIColor? { get }
  • The page margins. This is mainly useful for aligning items.

    Declaration

    Objective-C

    @property (readonly, nonatomic) UIEdgeInsets pageMargins;

    Swift

    var pageMargins: UIEdgeInsets { get }
  • The tiled pattern that is configured.

    Declaration

    Objective-C

    @property (readonly, nonatomic, nullable) PSPDFPageTemplate *pageTemplate;

    Swift

    var pageTemplate: PSPDFPageTemplate? { get }
  • The item that will be added to the new page.

    Declaration

    Objective-C

    @property (readonly, nonatomic, nullable) PSPDFProcessorItem *item;

    Swift

    var item: PSPDFProcessorItem? { get }