BPKLabel
@interface BPKLabel : UILabel
BPKLabel
is a subclass of UILabel
which uses the Skyscanner style.
-
Create a
BPKLabel
with a specific BPKFont style.See
BPKFontStyleDeclaration
Objective-C
- (nonnull instancetype)initWithFontStyle:(BPKFontStyle)style;
Swift
init(fontStyle style: BPKFontStyle)
Parameters
style
Font style to be used by the label.
-
The font style used for the label.
See
BPKFontStyle for the integer values to use when setting from Interface Builder.Declaration
Objective-C
@property (nonatomic) BPKFontStyle fontStyle;
Swift
var fontStyle: BPKFontStyle { get set }
-
Set the font style for a given range of the label.
Declaration
Objective-C
- (void)setFontStyle:(BPKFontStyle)fontStyle range:(NSRange)range;
Swift
func setFontStyle(_ fontStyle: BPKFontStyle, range: NSRange)
Parameters
fontStyle
The style of the text being appended.
range
The range to apply the font style to.