The current styled text that is displayed by the label.
- iOS 6.0+
- Mac Catalyst 13.0+Beta
- tvOS 9.0+
This property is
nil by default.
Assigning a new value to this property also replaces the value of the
text property with the same string data, although without any formatting information. In addition, assigning a new a value updates the values in the
textColor, and other style-related properties so that they reflect the style information starting at location 0 in the attributed string.
To turn on auto-kerning on the label, set
NSKernAttributeName of the string to
Accessing the Text Attributes
The current text that is displayed by the label.
The font used to display the text.
The technique to use for wrapping and truncating the label’s text.
The enabled state to use when drawing the label’s text.
This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.Learn more about using Apple's beta software