PTAnnotationViewController
@interface PTAnnotationViewController : UITableViewController <PTOverridable>
The PTAnnotationViewController
displays a list of all annotations in a document.
The list will contain any comments that have been added to the annotations, and selecting an
annotation will scroll the PTPDFViewCtrl
to the position of the annotation.
-
Initializes a
PTAnnotationViewController
instance.Declaration
Objective-C
- (nonnull instancetype)init;
Swift
init()
Return Value
an initialized
PTAnnotationViewController
instance -
Initializes a
PTAnnotationViewController
instance with the specified style.Declaration
Objective-C
- (nonnull instancetype)initWithStyle:(UITableViewStyle)style;
Swift
init(style: UITableView.Style)
Parameters
style
The table view style to use
Return Value
an initialized
PTAnnotationViewController
instance -
Initializes a
PTAnnotationViewController
instance with the given coder.Declaration
Objective-C
- (nonnull instancetype)initWithCoder:(nonnull NSCoder *)coder;
Swift
init(coder: NSCoder)
Parameters
coder
The coder
Return Value
an initialized
PTAnnotationViewController
instance -
Initializes a newly created
PTAnnotationViewController
with an annotation manager.Declaration
Objective-C
- (nonnull instancetype)initWithAnnotationManager: (nonnull PTAnnotationManager *)annotationManager;
Swift
convenience init(annotationManager: PTAnnotationManager)
Parameters
annotationManager
The annotation manager to be used by this view controller
Return Value
an initialized
PTAnnotationViewController
instance -
Initializes a newly created
PTAnnotationViewController
with a tool manager.Declaration
Objective-C
- (nonnull instancetype)initWithToolManager: (nonnull PTToolManager *)toolManager;
Swift
convenience init(toolManager: PTToolManager)
Parameters
toolManager
The tool manager to be used by this view controller
Return Value
an initialized
PTAnnotationViewController
instance -
The annotation manager associated with this control.
Declaration
Objective-C
@property (nonatomic, strong, nullable) PTAnnotationManager *annotationManager;
Swift
var annotationManager: PTAnnotationManager? { get set }
-
The default configuration instance, initialized with the default property values.
Declaration
Objective-C
@property (class, nonatomic, strong, readonly) PTAnnotationViewControllerConfiguration *_Nonnull defaultConfiguration;
Swift
class var defaultConfiguration: PTAnnotationViewControllerConfiguration { get }
-
The configuration used by this view controller.
The default value of this property is a copy of the configuration specified by the
PTAnnotationViewController.defaultConfiguration
class-property value.Declaration
Objective-C
@property (nonatomic, strong, readonly) PTAnnotationViewControllerConfiguration *_Nonnull configuration;
Swift
var configuration: PTAnnotationViewControllerConfiguration { get }
-
The delegate of this view controller.
Declaration
Objective-C
@property (nonatomic, weak, nullable) id<PTAnnotationViewControllerDelegate> delegate;
Swift
weak var delegate: (any PTAnnotationViewControllerDelegate)? { get set }
-
Whether annotations are considered readonly and cannot be modified or deleted.
The default value of this property is
NO
, meaning that annotations can be deleted.Note
ThePTToolManager.readonly
property is also consulted when determining if annotations can be modified or deleted. When the value ofPTToolManager.readonly
is set toYES
, that property takes precedence over this property.Declaration
Objective-C
@property (nonatomic, getter=isReadonly) BOOL readonly;
Swift
var isReadonly: Bool { get set }
-
Whether annotation replies are displayed by this view controller.
The default value of this property is
NO
.Declaration
Objective-C
@property (nonatomic, assign, unsafe_unretained, readwrite, getter=areAnnotationRepliesEnabled) BOOL annotationRepliesEnabled;
Swift
var areAnnotationRepliesEnabled: Bool { get set }
-
Whether annotations are hidden in the annotation list.
The default value of this property is
NO
.Declaration
Objective-C
@property (nonatomic, assign, unsafe_unretained, readwrite, getter=areAnnotationsHidden) BOOL annotationsHidden;
Swift
var areAnnotationsHidden: Bool { get set }
-
A list of annotation types to exclude from the annotation view controller.
The array entries are wrapped
PTAnnotType
enumeration values.The default value of this property is
nil
.Declaration
Objective-C
@property (nonatomic, copy, nullable) NSArray<NSNumber *> *excludedAnnotationTypes;
Swift
var excludedAnnotationTypes: [NSNumber]? { get set }
-
The list of available annotation sort modes for this view controller. The sort modes contained in this property are displayed in the
moreMenu
to allow the user to change the current sort mode.Declaration
Objective-C
@property (nonatomic, copy, nullable) NSArray<PTAnnotationSortMode *> *sortModes;
Swift
var sortModes: [PTAnnotationSortMode]? { get set }
-
The current annotation sort mode. The value of this property is
nil
when the array of sort modes in thesortModes
property is empty ofnil
.When setting the value of this property, the specified
PTAnnotationSortMode
instance must be in thesortModes
array property.The default value of this property is
pageNumberSortMode
.Declaration
Objective-C
@property (nonatomic, weak, nullable) PTAnnotationSortMode *currentSortMode;
Swift
weak var currentSortMode: PTAnnotationSortMode? { get set }
-
In this sort mode, annotations are sorted and grouped by their page number, and then by their creation dates.
Declaration
Objective-C
@property (nonatomic, strong, readonly) PTAnnotationSortMode *_Nonnull pageNumberSortMode;
Swift
var pageNumberSortMode: PTAnnotationSortMode { get }
-
Annotations are sorted by their creation date and grouped by day.
Declaration
Objective-C
@property (nonatomic, strong, readonly) PTAnnotationSortMode *_Nonnull creationDateSortMode;
Swift
var creationDateSortMode: PTAnnotationSortMode { get }
-
Annotations are sorted by their modification date and then grouped by day.
Declaration
Objective-C
@property (nonatomic, strong, readonly) PTAnnotationSortMode *_Nonnull modificationDateSortMode;
Swift
var modificationDateSortMode: PTAnnotationSortMode { get }
-
The “Done” bar button item shown by this view controller to allow dismissing it when shown in a non-popover modal presentation.
Declaration
Objective-C
@property (nonatomic, strong, readonly) UIBarButtonItem *_Nonnull doneButtonItem;
Swift
var doneButtonItem: UIBarButtonItem { get }
-
The “More” action bar button item shown by this view controller to access additional actions in a menu presentation.
Declaration
Objective-C
@property (nonatomic, strong, readonly) UIBarButtonItem *_Nonnull moreButtonItem;
Swift
var moreButtonItem: UIBarButtonItem { get }
-
The menu shown by the
moreButtonItem
to access additional actions.Declaration
Objective-C
@property (nonatomic, strong, readonly) API_AVAILABLE(ios(14.0)) UIMenu *moreMenu;
Swift
var moreMenu: UIMenu { get }
-
The view shown by this controller when there are no annotations in the document.
Declaration
Objective-C
@property (nonatomic, strong, readonly) PTEmptyTableViewIndicator *_Nonnull emptyIndicator;
Swift
var emptyIndicator: PTEmptyTableViewIndicator { get }
-
Undocumented
Declaration
Objective-C
- (instancetype)initWithNibName:(nullable NSString *)nibName bundle:(nullable NSBundle *)nibBundle NS_UNAVAILABLE;