PSPDFRenderOptions

Objective-C


@interface PSPDFRenderOptions : PSPDFModel <NSSecureCoding>

Swift

class RenderOptions : ModelObject, NSSecureCoding

Defines the options to apply when rendering PDF pages, such as color inversion, filters, colors and annotation behavior.

  • Changes the rendering to preserve the aspect ratio of the image. Defaults to false.

    Declaration

    Objective-C

    @property (nonatomic) BOOL preserveAspectRatio;

    Swift

    var preserveAspectRatio: Bool { get set }
  • Controls whether the image is forced to render with a scale of 1.0. Defaults to false.

    Declaration

    Objective-C

    @property (nonatomic) BOOL ignoreDisplaySettings;

    Swift

    var ignoreDisplaySettings: Bool { get set }
  • A color that is multiplied with the page content to color the pages. Defaults to UIColor.clearColor. If the page content draws a white square, the resulting color of that square will be pageColor. To set a background without tinting the page content, use backgroundFill instead.

    Declaration

    Objective-C

    @property (nonatomic) NSColor *_Nonnull pageColor;

    Swift

    var pageColor: NSColor { get set }
  • Inverts the rendering output. Defaults to false.

    Declaration

    Objective-C

    @property (nonatomic) BOOL invertRenderColor;

    Swift

    var invertRenderColor: Bool { get set }
  • Filters to be applied. Filters will increase rendering time. Defaults to no filters.

    Declaration

    Objective-C

    @property (nonatomic) PSPDFRenderFilter filters;

    Swift

    var filters: RenderFilter { get set }
  • Set custom interpolation quality. Defaults to kCGInterpolationHigh.

    Declaration

    Objective-C

    @property (nonatomic) CGInterpolationQuality interpolationQuality;

    Swift

    var interpolationQuality: CGInterpolationQuality { get set }
  • Set to true to NOT draw page content. Defaults to NO. (Use to just draw an annotation).

    Declaration

    Objective-C

    @property (nonatomic) BOOL skipPageContent;

    Swift

    var skipPageContent: Bool { get set }
  • Set to true to render annotations that have isOverlay = YES set. Defaults to false.

    Declaration

    Objective-C

    @property (nonatomic) BOOL overlayAnnotations;

    Swift

    var overlayAnnotations: Bool { get set }
  • Skip rendering of any annotations that are in this array.

    Declaration

    Objective-C

    @property (nonatomic, nullable) NSArray<PSPDFAnnotation *> *skipAnnotationArray;

    Swift

    var skipAnnotationArray: [PSPDFAnnotation]? { get set }
  • If true, will draw outside of page area. Defaults to false.

    Declaration

    Objective-C

    @property (nonatomic) BOOL ignorePageClip;

    Swift

    var ignorePageClip: Bool { get set }
  • Enables/Disables antialiasing. Defaults to true.

    Declaration

    Objective-C

    @property (nonatomic) BOOL allowAntialiasing;

    Swift

    var allowAntialiasing: Bool { get set }
  • The page base color. Page content is drawn on top of this fill. Defaults to UIColor.whiteColor. If the page content draws a white square, the resulting color of that square will be white regardless of the backgroundFill. To tint the page content too, use pageColor instead.

    Declaration

    Objective-C

    @property (nonatomic) NSColor *_Nonnull backgroundFill;

    Swift

    var backgroundFill: NSColor { get set }
  • Whether native text rendering via Core Graphics should be used. Defaults to true.

    Note

    Native text rendering usually yields better results but is slower.

    Declaration

    Objective-C

    @property (nonatomic) BOOL renderTextUsingCoreGraphics;

    Swift

    var renderTextUsingCoreGraphics: Bool { get set }
  • Sets the interactive fill color, which will override the fill color for all newly rendered form elements that are editable.

    The interactive fill color is used if a form element is editable by the user to indicate that the user can interact with this form element.

    If this value is set, it will always be used if the element is editable and the fillColor specified by the PDF is ignored. Remove this key to use the fill color specified in the PDF.

    Note

    This color is overlaid on top of the form contents. It is recommended to use a color with low alpha to ensure the content is still legible with the overlay applied.

    Defaults to a non-nil, translucent blue color.

    Declaration

    Objective-C

    @property (nonatomic, nullable) NSColor *interactiveFormFillColor;

    Swift

    var interactiveFormFillColor: NSColor? { get set }
  • Allows custom content rendering after the PDF.

    Declaration

    Objective-C

    @property (nonatomic, nullable) PSPDFRenderDrawBlock drawBlock;

    Swift

    var drawBlock: PSPDFRenderDrawBlock? { get set }
  • Controls if the “Sign here” overlay should be shown on unsigned signature fields. Defaults to true.

    Declaration

    Objective-C

    @property (nonatomic) BOOL drawSignHereOverlay;

    Swift

    var drawSignHereOverlay: Bool { get set }
  • Controls if redaction annotations should be drawn in their redacted state, to preview the appearance of how they would look if applied. By default redactions are rendered in their marked state.

    Defaults to false.

    Declaration

    Objective-C

    @property (nonatomic) BOOL drawRedactionsAsRedacted;

    Swift

    var drawRedactionsAsRedacted: Bool { get set }
  • Whether the annotations are drawn flattened when processing a document. Defaults to false.

    Declaration

    Objective-C

    @property (nonatomic) BOOL drawFlattened;

    Swift

    var drawFlattened: Bool { get set }
  • Set to true to specify that the annotation is being drawn for printing. Defaults to false.

    Declaration

    Objective-C

    @property (nonatomic) BOOL drawForPrinting;

    Swift

    var drawForPrinting: Bool { get set }
  • If the annotation should be rendered centered within it’s own context. Defaults to false.

    Declaration

    Objective-C

    @property (nonatomic) BOOL centered;

    Swift

    var centered: Bool { get set }
  • The margin that should be applied to the drawing annotation. Defaults to (0,0,0,0).

    Declaration

    Objective-C

    @property (nonatomic) NSEdgeInsets margin;

    Swift

    var margin: NSEdgeInsets { get set }
  • Whether the annotation’s appearance stream should be rendered. Defaults to false.

    Declaration

    Objective-C

    @property (nonatomic) BOOL drawAppearanceStream;

    Swift

    var drawAppearanceStream: Bool { get set }
  • Unavailable

    Not the designated initializer

    Undocumented

    Declaration

    Objective-C

    - (nullable instancetype)initWithCoder:(nonnull NSCoder *)aDecoder;
  • Unavailable

    Not the designated initializer

    Undocumented

    Declaration

    Objective-C

    - (nullable instancetype)
        initWithDictionary:(nullable NSDictionary<NSString *, id> *)dictionaryValue
                     error:(NSError *_Nullable *_Nullable)error;