PTPopup

@interface PTPopup : PTAnnot

A pop-up annotation (PDF 1.3) displays text in a pop-up window for entry and editing. It shall not appear alone but is associated with a markup annotation, its parent annotation, and shall be used for editing the parent’s text. It shall have no appearance stream or associated actions of its own and shall be identified by the Popup entry in the parent’s annotation dictionary.

  • Creates a Popup annotation and initializes it using given Cos/SDF object.

    Note

    The constructor does not copy any data, but is instead the logical equivalent of a type cast.

    Declaration

    Objective-C

    - (instancetype)initWithD:(PTObj *)d;

    Swift

    init!(d: PTObj!)

    Parameters

    d

    The Cos/SDF object to initialze the annotation with.

  • Undocumented

    Declaration

    Objective-C

    - (instancetype)init;

    Swift

    init!()
  • Undocumented

    Declaration

    Objective-C

    - (instancetype)initWithAnn: (PTAnnot*)ann;

    Swift

    init!(ann: PTAnnot!)
  • Creates a new Popup annotation in the specified document.

    Declaration

    Objective-C

    + (PTPopup *)Create:(PTSDFDoc *)doc pos:(PTPDFRect *)pos;

    Swift

    class func create(_ doc: PTSDFDoc!, pos: PTPDFRect!) -> PTPopup!

    Parameters

    doc

    A document to which the Popup annotation is added.

    pos

    A rectangle specifying the Popup annotation’s bounds in default user space units.

    Return Value

    A newly created blank Popup annotation.

  • Returns the parent annotation of the Popup annotation.

    Note

    This annotation object represents the parent annotation with which this pop-up annotation shall be associated.

    Note

    If this entry is present, the parent annotation’s Contents, M, C, and T entries shall override those of the pop-up annotation itself.

    Declaration

    Objective-C

    - (PTAnnot *)GetParent;

    Swift

    func getParent() -> PTAnnot!

    Return Value

    An annot object which is the parent annotation of the Popup annotation.

  • Sets the Parent annotation of the Popup annotation. (Optional)

    Note

    This annotation object represents the parent annotation with which this pop-up annotation shall be associated.

    Note

    If this entry is present, the parent annotation’s Contents, M, C, and T entries shall override those of the pop-up annotation itself.

    Declaration

    Objective-C

    - (void)SetParent:(PTAnnot *)parent;

    Swift

    func setParent(_ parent: PTAnnot!)

    Parameters

    parent

    An annot object which is the parent annotation of the Popup annotation.

  • Returns the initial opening condition of Popup.

    Note

    This is a flag specifying whether the pop-up annotation’s window shall initially be displayed. Default value: false (closed).

    Declaration

    Objective-C

    - (BOOL)IsOpen;

    Swift

    func isOpen() -> Bool

    Return Value

    A bool indicating whether the Popup is initially open.

  • Sets the initial opening condition of Popup. (Optional)

    Note

    This is a flag specifying whether the pop-up annotation’s window shall initially be displayed. Default value: false (closed).

    Declaration

    Objective-C

    - (void)SetOpen:(BOOL)is_open;

    Swift

    func setOpen(_ is_open: Bool)

    Parameters

    is_open

    A bool indicating whether the Popup is initially open.