PTPanelView


@interface PTPanelView : UIView

Instances of the PTPanelView class can contain any view as a subview of its contentView, and when the panel can be resized, resize-controls are shown as appropriate.

  • The position of the panel in its container.

    The default value of this property is PTPanelPositionLeft.

    Declaration

    Objective-C

    @property (nonatomic) PTPanelPosition position;

    Swift

    var position: PTPanelView.PanelPosition { get set }
  • The content view to which views can be added. Views should not be added directly to the PTPanelView and instead added as a subview to the contentView.

    Declaration

    Objective-C

    @property (nonatomic, strong, readonly) UIView *_Nonnull contentView;

    Swift

    var contentView: UIView { get }
  • Whether the panel can be resized and should show the grabber.

    The default value of this property is YES.

    Declaration

    Objective-C

    @property (nonatomic, assign, unsafe_unretained, readwrite,
              getter=isResizingEnabled) BOOL resizingEnabled;

    Swift

    var isResizingEnabled: Bool { get set }
  • Whether the panel is currently being resized.

    The default value of this property is YES.

    Declaration

    Objective-C

    @property (nonatomic, readonly, getter=isResizing) BOOL resizing;

    Swift

    var isResizing: Bool { get }
  • The grabber control used by this view to allow the user to resize the panel.

    Declaration

    Objective-C

    @property (nonatomic, strong, readonly) PTGrabberView *_Nonnull grabber;

    Swift

    var grabber: PTGrabberView { get }
  • The color used for the grabber while resizing the panel. Setting a value of nil resets this property back to its default value.

    Declaration

    Objective-C

    @property (nonatomic, strong, null_resettable) UIColor *resizingGrabberColor;

    Swift

    var resizingGrabberColor: UIColor! { get set }
  • The default grabber color used while resizing for instances of the PTPanelView class.

    The default value of this property is a white color.

    Declaration

    Objective-C

    @property (class, nonatomic, strong, readonly) UIColor *_Nonnull defaultResizingGrabberColor;

    Swift

    class var defaultResizingGrabberColor: UIColor { get }
  • The gesture recognizers used to handle resizing the panel.

    These gesture recognizer are attached to the grabber.

    Declaration

    Objective-C

    @property (nonatomic, copy, readonly) NSArray<UIGestureRecognizer *> *_Nonnull resizeGestureRecognizers;

    Swift

    var resizeGestureRecognizers: [UIGestureRecognizer] { get }
  • The view used to show a separator along the edge of the panel.

    Declaration

    Objective-C

    @property (nonatomic, strong, readonly) UIView *_Nonnull shadowView;

    Swift

    var shadowView: UIView { get }
  • The color used for the shadow shown by the shadowView. Setting a value of nil resets this property back to its default value.

    Declaration

    Objective-C

    @property (nonatomic, strong, null_resettable) UIColor *shadowColor;

    Swift

    var shadowColor: UIColor! { get set }
  • The default shadow color for instances of the PTPanelView class.

    The default value of this property is a semi-transparent gray color.

    Declaration

    Objective-C

    @property (class, nonatomic, strong, readonly) UIColor *_Nonnull defaultShadowColor;

    Swift

    class var defaultShadowColor: UIColor { get }
  • The color used for the shadow shown by the shadowView while resizing the panel. Setting a value of nil resets this property back to its default value.

    Declaration

    Objective-C

    @property (nonatomic, strong, null_resettable) UIColor *resizingShadowColor;

    Swift

    var resizingShadowColor: UIColor! { get set }
  • The default shadow color used while resizing for instances of the PTPanelView class.

    The default value of this property is a black color.

    Declaration

    Objective-C

    @property (class, nonatomic, strong, readonly) UIColor *_Nonnull defaultResizingShadowColor;

    Swift

    class var defaultResizingShadowColor: UIColor { get }
  • The width of the shadow while the panel is being resized.

    The default value of this property is 10.0.

    Declaration

    Objective-C

    @property (nonatomic) CGFloat resizingShadowWidth;

    Swift

    var resizingShadowWidth: CGFloat { get set }
  • Whether the shadow shown by the shadowView is hidden.

    The default value of this property is NO.

    Declaration

    Objective-C

    @property (nonatomic, assign, unsafe_unretained, readwrite,
              getter=isShadowHidden) BOOL shadowHidden;

    Swift

    var isShadowHidden: Bool { get set }