PSPDFOutlineCell
Objective-C
@interface PSPDFOutlineCell : PSPDFTableViewCell <PSPDFOverridable>
Swift
class OutlineCell : PDFTableViewCell, Overridable
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 (nonatomic, readonly, nullable) PSPDFOutlineElement *outlineElement;
Swift
var outlineElement: PSPDFOutlineElement? { get }
-
The resolved page label.
Declaration
Objective-C
@property (nonatomic, copy, readonly, nullable) NSString *pageLabelString;
Swift
var pageLabelString: String? { get }
-
Delegate for cell button.
Declaration
Objective-C
@property (nonatomic, weak) id<PSPDFOutlineCellDelegate> _Nullable delegate;
Swift
@IBOutlet weak var delegate: OutlineCellDelegate? { get set }
-
Shows the expand/collapse button.
Declaration
Objective-C
@property (nonatomic) BOOL showExpandCollapseButton;
Swift
var showExpandCollapseButton: Bool { get set }
-
Enables the page label on the right side of the cell.
Declaration
Objective-C
@property (nonatomic) BOOL showPageLabel;
Swift
var showPageLabel: Bool { get set }
-
Button that controls expanding and collapsing of cells.
Declaration
Objective-C
@property (nonatomic) UIButton *_Nonnull disclosureButton;
Swift
var disclosureButton: UIButton { get set }
-
The label displayed containing the outline name.
Declaration
Objective-C
@property (nonatomic) UILabel *_Nonnull nameLabel;
Swift
var nameLabel: UILabel { get set }
-
The page label displayed on the right side. Only valid if
showPageLabel
is set.Declaration
Objective-C
@property (nonatomic) UILabel *_Nonnull pageLabel;
Swift
var pageLabel: UILabel { 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?) -> UIFont
-
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?) -> UIFont
-
Set transform according to expansion state.
-
Button action. Animates and calls the delegate.
-
Should be changed in
OutlineViewController
.Declaration
Objective-C
@property (nonatomic) NSUInteger maximumNumberOfLines;
Swift
var maximumNumberOfLines: UInt { get set }
-
Should be changed in
OutlineViewController
.Declaration
Objective-C
@property (nonatomic) CGFloat outlineIndentLeftOffset;
Swift
var outlineIndentLeftOffset: CGFloat { get set }
-
Should be changed in
OutlineViewController
.Declaration
Objective-C
@property (nonatomic) CGFloat outlineIndentMultiplier;
Swift
var outlineIndentMultiplier: CGFloat { get set }