Label
Label Attributes Inspector Reference
Text and Behavior
Lines
The maximum number of lines for the label text.
Set to 0 for an unlimited number of lines.
Access: numberOfLines
.
Text
Text Type
The type of the label text.
Selection |
---|
Plain |
Attributed |
Text Type: Plain
This group configures the label plain text.
Text
The label plain text.
Access: text
.
Color
The color of the label plain text.
Access: textColor
.
Font
The font of the label plain text.
Access: font
.
Alignment
The alignment of the label plain text.
Selection |
Method |
Argument |
---|---|---|
Left |
||
Center |
||
Right |
Text Type: Attributed
This group configures the text selected in Attributed Text.
Attributed Text Layout
The alignment and other layout characteristics of the selected attributed text.
To set alignment and other layout characteristics of part of the attributed text in code, you need to create an attributed string with the desired characteristics and assign it to attributedText
.
Selection |
---|
Left |
Center |
Right |
Justified |
Natural |
Text Color |
Background Color |
More |
Font
The font of the selected attributed text.
Access: font
.
Attributed Text
The label attributed text.
Access: attributedText
.
Behavior
Enabled
Whether the label is enabled.
Highlighted
Whether the label is highlighted.
Toggle this property after setting the text highlight color to preview the highlighted label.
Selection |
Method |
Argument |
---|---|---|
Unselected |
||
Selected |
Text Baseline and Line Breaks
Baseline
How to adjust the text baseline so that the text fits in the label.
Selection |
Method |
Argument |
---|---|---|
Align Baselines |
||
Align Centers |
||
None |
Line Breaks
The line break mode of the label text.
Selection |
Method |
Argument |
---|---|---|
Clip |
||
Character Wrap |
||
Word Wrap |
||
Truncate Head |
||
Truncate Middle |
||
Truncate Tail |
Text Sizing
Autoshrink
How to shrink the label text so that it fits in the label.
Selection |
Method |
Argument |
Method |
---|---|---|---|
Fixed Font Size |
|
||
Minimum Font Scale |
|||
Minimum Font Size |
Tighten Letter Spacing
Whether to reduce the label text letter spacing so that it fits in the label.
Selection |
Method |
Argument |
---|---|---|
Unselected |
||
Selected |
Text Highlight and Shadow
Highlighted
The color for the label text when the label is highlighted.
This property applies only to plain text labels.
Access: highlightedTextColor
.
Shadow
The color of the label text shadow.
Access: shadowColor
.
Shadow Offset
The offset of the label text shadow.
Access: shadowOffset
.
Copyright © 2014 Apple Inc. All rights reserved. Terms of Use | Privacy Policy | Updated: 2013-12-16