PTSelectionRectContainerView
@interface PTSelectionRectContainerView : UIView
A transparent container view for the shaded PTSelectionRectView
and the resize widgets.
-
The shaded rectangle that is overlayed onto the selected annotation.
Declaration
Objective-C
@property (nonatomic, strong, readonly) PTSelectionRectView *_Nonnull selectionRectView;
Swift
var selectionRectView: PTSelectionRectView { get }
-
The rectangle that covers the group of annotations
Declaration
Objective-C
@property (nonatomic, strong, readonly) UIView *_Nonnull groupSelectionRectView;
Swift
var groupSelectionRectView: UIView { get }
-
The rectangle that draws the line between control resize widgets
Declaration
Objective-C
@property (nonatomic, strong, readonly) UIView *_Nonnull borderView;
Swift
var borderView: UIView { get }
-
The PTPDFViewCtrl that the selection is on.
Declaration
Objective-C
@property (nonatomic, weak) PTPDFViewCtrl *_Nullable pdfViewCtrl;
Swift
weak var pdfViewCtrl: PTPDFViewCtrl? { get set }
-
When true, only displays corner resize handles. Default is
false
.Declaration
Objective-C
@property (nonatomic) BOOL displaysOnlyCornerResizeHandles;
Swift
var displaysOnlyCornerResizeHandles: Bool { get set }
-
Hides all of the resize widgets.
Declaration
Objective-C
- (void)hideResizeWidgetViews;
Swift
func hideResizeWidgetViews()
-
Shows all of the resize widgets.
Declaration
Objective-C
- (void)showResizeWidgetViews;
Swift
func showResizeWidgetViews()
-
Shows the width resize widget (for spacing texts).
Declaration
Objective-C
- (void)showWidthResizeWidgetView;
Swift
func showWidthResizeWidgetView()
-
Shows the North-East and South-West resize widgets (for lines/arrows).
Declaration
Objective-C
- (void)showNESWWidgetViews;
Swift
func showNESWWidgetViews()
-
Shows the North-West and South-East resize widgets (for lines/arrows).
Declaration
Objective-C
- (void)showNWSEWidgetViews;
Swift
func showNWSEWidgetViews()
-
Used to set the view’s frame to match the selected annotation’s frame.
Declaration
Objective-C
- (void)setFrameFromAnnot:(CGRect)frame;
Swift
func setFrameFromAnnot(_ frame: CGRect)
Parameters
frame
The view’s new frame.
-
The rotation handle used for annotation rotating.
Declaration
Objective-C
@property (nonatomic, strong, nullable) PTRotateWidgetView *rotationHandle;
Swift
var rotationHandle: PTRotateWidgetView? { get set }
-
Used to set the location of the rotation handle.
Declaration
Objective-C
- (void)setRotationHandleLocation:(PTRotateHandleLocation)location;
Swift
func setRotationHandleLocation(_ location: PTRotateHandleLocation)
Parameters
location
The location of the rotation handle.
-
The text view used for free text annotation editing.
Declaration
Objective-C
@property (nonatomic, strong, nullable) PTFreeTextView *textView;
Swift
var textView: PTFreeTextView? { get set }
-
The text view presented when a spacing text annotation is selected.
Declaration
Objective-C
@property (nonatomic, strong, nullable) PTFreeTextView *spacingTextView;
Swift
var spacingTextView: PTFreeTextView? { get set }
-
Scales the text size of a free text annotation that’s being edited for the current zoom.
Declaration
Objective-C
- (void)setEditTextSizeForZoom:(double)zoom forFontSize:(int)size;
Swift
func setEditTextSizeForZoom(_ zoom: Double, forFontSize size: Int32)
-
Adds a UITextView to the selection rectangle for PTFreeText annotation editing.
Declaration
Objective-C
- (void)useTextViewWithText:(nullable NSString *)text withAlignment:(int)alignment atZoom:(double)zoom forFontSize:(int)size withFontName:(nonnull NSString *)fontName withFrame:(CGRect)frame withDelegate:(nonnull id<UITextViewDelegate>)delegateView;
Swift
func useTextView(withText text: String?, withAlignment alignment: Int32, atZoom zoom: Double, forFontSize size: Int32, withFontName fontName: String, withFrame frame: CGRect, with delegateView: UITextViewDelegate)
-
-useTextViewWithAttributedText:withAlignment:atZoom:forFontSize:withFontName:withFrame:withDelegate:
Adds a UITextView to the selection rectangle for PTFreeText annotation editing.
Declaration
Objective-C
- (void) useTextViewWithAttributedText:(nullable NSAttributedString *)attributedText withAlignment:(int)alignment atZoom:(double)zoom forFontSize:(int)size withFontName:(nonnull NSString *)fontName withFrame:(CGRect)frame withDelegate:(nonnull id<UITextViewDelegate>)delegateView;
Swift
func useTextView(withAttributedText attributedText: NSAttributedString?, withAlignment alignment: Int32, atZoom zoom: Double, forFontSize size: Int32, withFontName fontName: String, withFrame frame: CGRect, with delegateView: UITextViewDelegate)
-
Undocumented
Declaration
Objective-C
- (void)useTextViewForSpacingText:(nullable NSString *)text withAlignment:(int)alignment atZoom:(double)zoom forFontSize:(int)size withFontName:(NSString*)fontName withFrame:(CGRect)frame;
Swift
func useTextView(forSpacingText text: String?, withAlignment alignment: Int32, atZoom zoom: Double, forFontSize size: Int32, withFontName fontName: String, withFrame frame: CGRect)
-
Undocumented
Declaration
Objective-C
- (void)useTextViewForSpacingAttributedText:(nullable NSAttributedString *)attributedText withAlignment:(int)alignment atZoom:(double)zoom forFontSize:(int)size withFontName:(NSString*)fontName withFrame:(CGRect)frame;
Swift
func useTextView(forSpacingAttributedText attributedText: NSAttributedString?, withAlignment alignment: Int32, atZoom zoom: Double, forFontSize size: Int32, withFontName fontName: String, withFrame frame: CGRect)
-
Shows the selection rect. For use when editing line and arrow annotations, where the selection rectangle is not shown when the annotation is not being moved, and has a different appearance than other annotation types.
Declaration
Objective-C
- (void)showSelectionRect;
Swift
func showSelectionRect()
-
Hides the selection rect. For use when editing line and arrow annotations, where the selection rectangle is not shown when the annotation is not being moved, and has a different appearance than other annotation types.
Declaration
Objective-C
- (void)hideSelectionRect;
Swift
func hideSelectionRect()
-
Sets the annot type that is selected. Used to determine the appearance of the child
PTSelectionRectView
.Declaration
Objective-C
- (void)setAnnot:(nullable PTAnnot *)annot;
Swift
func setAnnot(_ annot: PTAnnot?)
Parameters
annot
The annotation that is selected.
-
Refreshes the live representation of the annotation’s appearance.
Declaration
Objective-C
- (void)refreshLiveAppearance;
Swift
func refreshLiveAppearance()
-
Removes the live representation of the annotation’s appearance.
Declaration
Objective-C
- (void)removeLiveAppearance;
Swift
func removeLiveAppearance()
-
Instantiates a new PTSelectionRectContainerView object.
Declaration
Objective-C
- (nonnull instancetype)initWithPDFViewCtrl:(nonnull PTPDFViewCtrl *)pdfViewCtrl forAnnot:(nullable PTAnnot *)annot withAnnotEditTool:(nonnull PTAnnotEditTool *)tool;
Swift
init(pdfViewCtrl: PTPDFViewCtrl, for annot: PTAnnot?, with tool: PTAnnotEditTool)
Parameters
pdfViewCtrl
The PTPDFViewCtrl instance that this view uses.
annot
The annotation that this view will be shown over.
tool
The current tool.
-
Undocumented
Declaration
Objective-C
-(instancetype)initWithFrame:(CGRect)frame NS_UNAVAILABLE;
-
Undocumented
Declaration
Objective-C
-(instancetype)initWithCoder:(NSCoder *)aDecoder NS_UNAVAILABLE;
-
Undocumented
Declaration
Objective-C
-(instancetype)init NS_UNAVAILABLE;