PTOutlineViewControllerDelegate

@protocol PTOutlineViewControllerDelegate <NSObject>

The methods declared by the PTOutlineViewControllerDelegate protocol allow the adopting delegate to respond to messages from the PTAnnotationViewController class.

  • Tells the delegate that an outline item was selected. Note that the PDF specification refers to outline items as bookmarks, which are not user bookmarks. The PTBookmark and related classes refer to outline items, not user bookmarks.

    Declaration

    Objective-C

    - (void)outlineViewController:
                (nonnull PTOutlineViewController *)outlineViewController
                 selectedBookmark:(nonnull NSDictionary *)bookmark;

    Swift

    optional func outlineViewController(_ outlineViewController: PTOutlineViewController, selectedBookmark bookmark: [AnyHashable : Any])

    Parameters

    outlineViewController

    The PTOutlineViewController object informing the delegate about the bookmark’s selection.

    bookmark

    A dictionary of bookmark information, with key-value pairs: {KEY_TITLE, NSString holding the bookmark’s title}, {KEY_CHILDREN, NSNumber with a BOOL value indicating the presence of children at this node}, {KEY_BOOKMARK, PTBookmark that’s the next bookmark}.

  • Tells the delegate that the outline control wants to be closed.

    Declaration

    Objective-C

    - (void)outlineViewControllerDidCancel:
        (nonnull PTOutlineViewController *)outlineViewController;

    Swift

    optional func outlineViewControllerDidCancel(_ outlineViewController: PTOutlineViewController)