PSPDFLabelView
Objective-C
@interface PSPDFLabelView : UIView
Swift
class PDFLabelView : UIView
Base class to show a semi-transparent, rounded label.
You can use UIAppearance to customize the main properties.
[PSPDFLabelView appearance].labelStyle = PSPDFLabelStyleFlat;
[PSPDFLabelView appearance].backgroundColor = [UIColor colorWithWhite:0.1 alpha:0.8];
[PSPDFLabelView appearance].textColor = UIColor.whiteColor;
Note
The background color can be customized by setting the standardbackgroundColor
UIView
property. If you want to customize the background color, it is recommended
that you use PSPDFLabelStyleFlat
, as using the blur effect with a non-translucent
background color might produce unexpected results.
If you are customizing this view, you might also want to apply similar changes to
PSPDFBackForwardButton
.
-
UILabel
used internally to show the text.Declaration
Objective-C
@property (nonatomic, readonly) UILabel *_Nonnull label;
Swift
var label: UILabel { get }
-
Margin that is between the text and this view. Defaults to 2 on iPhone and 3 on iPad.
Declaration
Objective-C
@property (nonatomic) CGFloat labelMargin;
Swift
var labelMargin: CGFloat { get set }
-
Customize label style. Defaults to
PSPDFLabelStyleModern
. The styles match thebuttonStyle
values onPSPDFStyleButton
.Declaration
Objective-C
@property (nonatomic) PSPDFLabelStyle labelStyle;
Swift
var labelStyle: PDFLabelView.Style { get set }
-
Customize the blur effect style used. Only applicable in
PSPDFLabelStyleModern
. Defaults toUIBlurEffectStyleExtraLight
.Declaration
Objective-C
@property (nonatomic) UIBlurEffectStyle blurEffectStyle;
Swift
var blurEffectStyle: UIBlurEffect.Style { get set }
-
Equal to
label.textColor
, but can also be used withUIAppearance
. Defaults to black.Declaration
Objective-C
@property (nonatomic) UI_APPEARANCE_SELECTOR UIColor *textColor;
Swift
var textColor: UIColor { get set }