BOStringAttribute Class Reference
Inherits from | NSObject |
Declared in | BOStringAttribute.h |
Tasks
-
attributeRange
property -
stringLength
property -
attributeName
property -
attributeValue
property -
– with
-
– range
-
– stringRange
Properties
attributeName
Name of the attribute to apply.
@property (nonatomic, copy) NSString *attributeName
Discussion
Name of the attribute to apply.
Declared In
BOStringAttribute.h
attributeRange
Range of attribute. Default is (0, stringLength).
@property (nonatomic, assign) NSRange attributeRange
Discussion
Range of attribute. Default is (0, stringLength).
Declared In
BOStringAttribute.h
Instance Methods
range
Sets range of the attribute.
- (BOStringAttribute *( ^ ) ( NSRange ))range
Discussion
Sets range of the attribute.
Declared In
BOStringAttribute.h
stringRange
Sets range of the attribute to whole string. Equivalent:
- (void ( ^ ) ( ))stringRange
Discussion
Sets range of the attribute to whole string. Equivalent:
range(NSMakeRange(0, self.stringLength));
Declared In
BOStringAttribute.h
with
Semantic filler. Does nothing, just returns self. May be helpful in case if range needs to be changed:
- (instancetype)with
Return Value
self
Discussion
Semantic filler. Does nothing, just returns self. May be helpful in case if range needs to be changed:
make.foregroundColor([UIColor blueColor]).with.range(NSMakeRange(1, 2));
However, this code is equivalent to a bit shorter form:
make.foregroundColor([UIColor blueColor]).range(NSMakeRange(1, 2));
Which is a bit less human readable.
Declared In
BOStringAttribute.h