PSPDFOutlineCell
@interface PSPDFOutlineCell : PSPDFTableViewCell
Single cell for the outline controller.
-
Configures the cell. The
documentProvider
is required to resolve the outline actions to page labels.Declaration
Objective-C
- (void) configureWithOutlineElement:(nonnull PSPDFOutlineElement *)outlineElement documentProvider:(nullable PSPDFDocumentProvider *)documentProvider;
Swift
func configure(with outlineElement: PSPDFOutlineElement, documentProvider: PSPDFDocumentProvider?)
-
Single outline element.
Declaration
Objective-C
@property (readonly, nonatomic, nullable) PSPDFOutlineElement *outlineElement;
Swift
var outlineElement: PSPDFOutlineElement? { get }
-
The resolved page label.
Declaration
Objective-C
@property (readonly, copy, nonatomic, nullable) NSString *pageLabelString;
Swift
var pageLabelString: String? { get }
-
Delegate for cell button.
Declaration
Objective-C
@property (readwrite, nonatomic) id<PSPDFOutlineCellDelegate> _Nullable delegate;
Swift
@IBOutlet weak var delegate: PSPDFOutlineCellDelegate? { get set }
-
Shows the expand/collapse button.
Declaration
Objective-C
@property (assign, readwrite, nonatomic) BOOL showExpandCollapseButton;
Swift
var showExpandCollapseButton: Bool { get set }
-
Enables the page label on the right side of the cell.
Declaration
Objective-C
@property (assign, readwrite, nonatomic) BOOL showPageLabel;
Swift
var showPageLabel: Bool { get set }
-
Button that controls expanding and collapsing of cells.
Declaration
Objective-C
@property (assign, readwrite, nonatomic) UIButton *_Nonnull disclosureButton;
Swift
var disclosureButton: UnsafeMutablePointer<Int32> { get set }
-
The label displayed containing the outline name.
Declaration
Objective-C
@property (assign, readwrite, nonatomic) UILabel *_Nonnull nameLabel;
Swift
var nameLabel: UnsafeMutablePointer<Int32> { get set }
-
The page label displayed on the right side. Only valid if
showPageLabel
is set.Declaration
Objective-C
@property (assign, readwrite, nonatomic) UILabel *_Nonnull pageLabel;
Swift
var pageLabel: UnsafeMutablePointer<Int32> { get set }
-
Subclass to change the font of
nameLabel
. Default isUIFontTextStyleSubheadline
for level 0 andUIFontTextStyleBody
for level > 0. This also respects thefontTraits
ofoutlineElement
.Declaration
Objective-C
+ (nonnull UIFont *)fontForOutlineElement: (nullable PSPDFOutlineElement *)outlineElement;
Swift
class func font(for outlineElement: PSPDFOutlineElement?) -> NSFont
-
Subclass to change the font of
pageLabel
. Default isUIFontTextStyleSubheadline
.Declaration
Objective-C
+ (nonnull UIFont *)pageLabelFontForOutlineElement: (nullable PSPDFOutlineElement *)outlineElement;
Swift
class func pageLabelFont(for outlineElement: PSPDFOutlineElement?) -> NSFont
-
Set transform according to expansion state.
Declaration
Objective-C
- (void)updateDisclosureButton;
Swift
func updateDisclosureButton()
-
Button action. Animates and calls the delegate.
Declaration
Objective-C
- (void)expandOrCollapse;
Swift
func expandOrCollapse()
-
Should be changed in
PSPDFOutlineViewController
.Declaration
Objective-C
@property (assign, readwrite, nonatomic) NSUInteger maximumNumberOfLines;
Swift
var maximumNumberOfLines: UInt { get set }
-
Should be changed in
PSPDFOutlineViewController
.Declaration
Objective-C
@property (assign, readwrite, nonatomic) CGFloat outlineIntentLeftOffset;
Swift
var outlineIntentLeftOffset: CGFloat { get set }
-
Should be changed in
PSPDFOutlineViewController
.Declaration
Objective-C
@property (assign, readwrite, nonatomic) CGFloat outlineIndentMultiplier;
Swift
var outlineIndentMultiplier: CGFloat { get set }