PTNoteEditController


@interface PTNoteEditController : UIViewController <PTOverridable>

A view controller that displays and allows editing of an annotation’s popup note.

  • Initializes a newly created PTNoteEditController instance.

    Declaration

    Objective-C

    - (nonnull instancetype)initWithDelegate:
                                (nonnull id<PTNoteEditControllerDelegate>)delegate
                                   annotType:(PTExtendedAnnotType)annotType;

    Swift

    init(delegate: any PTNoteEditControllerDelegate, annotType: PTExtendedAnnotType)
  • The delegate of the note edit controller.

    Declaration

    Objective-C

    @property (nonatomic, weak, nullable) id<PTNoteEditControllerDelegate> delegate;

    Swift

    weak var delegate: (any PTNoteEditControllerDelegate)? { get set }
  • The UITextView that displays the contents of the note.

    Declaration

    Objective-C

    @property (nonatomic, strong, readonly) UITextView *_Nonnull textView;

    Swift

    var textView: UITextView { get }
  • The contents of the note.

    Declaration

    Objective-C

    @property (nonatomic, copy) NSString *_Nonnull noteString;

    Swift

    var noteString: String { get set }
  • Whether the UIBarButtonItem to change the style of the note should be hidden. The default value is NO.

    Declaration

    Objective-C

    @property (nonatomic) BOOL styleButtonHidden;

    Swift

    var styleButtonHidden: Bool { get set }
  • Whether the note is readonly and editing is disabled. The default value is NO.

    Declaration

    Objective-C

    @property (nonatomic, getter=isReadonly) BOOL readonly;

    Swift

    var isReadonly: Bool { get set }
  • Whether this view controller’s contents should be tinted to reflect the annotation’s primary color.

    The default value of this property is YES.

    Declaration

    Objective-C

    @property (nonatomic, assign, unsafe_unretained, readwrite,
              getter=isAnnotationTintColorEnabled) BOOL annotationTintColorEnabled;

    Swift

    var isAnnotationTintColorEnabled: Bool { get set }
  • The tinted background color of this view controller.

    The default value of this property is nil.

    Declaration

    Objective-C

    @property (nonatomic, strong, nullable) UIColor *backgroundTintColor;

    Swift

    var backgroundTintColor: UIColor? { get set }
  • The tinted button item color of this view controller.

    The default value of this property is nil.

    Declaration

    Objective-C

    @property (nonatomic, strong, nullable) UIColor *buttonItemTintColor;

    Swift

    var buttonItemTintColor: UIColor? { get set }
  • This method is called when cancel button is pressed. Override point.

    Declaration

    Objective-C

    - (void)cancelButtonPressed;

    Swift

    func cancelButtonPressed()
  • This method is called when the delete button is pressed. Override point.

    Declaration

    Objective-C

    - (void)deleteButtonPressed;

    Swift

    func deleteButtonPressed()
  • This method is called when the save button is pressed. Override point.

    Declaration

    Objective-C

    - (void)saveButtonPressed;

    Swift

    func saveButtonPressed()
  • This method is called when the style button is pressed. Override point.

    Declaration

    Objective-C

    - (void)styleButtonPressed;

    Swift

    func styleButtonPressed()
  • This method is called when the done button is pressed. Override point.

    Declaration

    Objective-C

    - (void)doneButtonPressed;

    Swift

    func doneButtonPressed()
  • The annotation type for which the note edit controller is being shown.

    Declaration

    Objective-C

    @property (nonatomic) PTExtendedAnnotType annotType;

    Swift

    var annotType: PTExtendedAnnotType { get set }
  • The “Style” button item shown in the toolbar to modify the annotation’s style.

    Declaration

    Objective-C

    @property (nonatomic, strong) UIBarButtonItem *_Nonnull styleButtonItem;

    Swift

    var styleButtonItem: UIBarButtonItem { get set }
  • The “Delete” button item shown in the toolbar to delete the annotation’s style. Only shown for text (sticky note) annotations.

    Declaration

    Objective-C

    @property (nonatomic, strong) UIBarButtonItem *_Nonnull deleteButtonItem;

    Swift

    var deleteButtonItem: UIBarButtonItem { get set }
  • Undocumented

    Declaration

    Objective-C

    -(instancetype)initWithCoder:(NSCoder *)aDecoder NS_UNAVAILABLE;
  • Undocumented

    Declaration

    Objective-C

    -(instancetype)initWithNibName:(nullable NSString *)nibName bundle:(nullable NSBundle *)bundle NS_UNAVAILABLE;
  • Undocumented

    Declaration

    Objective-C

    -(instancetype)init NS_UNAVAILABLE;