Instance Property


A Boolean value indicating whether the font size should be reduced in order to fit the title string into the label’s bounding rectangle.


var adjustsFontSizeToFitWidth: Bool { get set }


Normally, the label text is drawn with the font you specify in the font property. If this property is set to true, and the text in the text property exceeds the label’s bounding rectangle, the label reduces the font size until the string fits or the minimum font scale is reached.The default value for this property is false. If you change it to true, be sure that you also set an appropriate minimum font scale by modifying the minimumScaleFactor property.

See Also

Sizing the Label’s Text

var allowsDefaultTighteningForTruncation: Bool

A Boolean value indicating whether the label tightens text before truncating.

var baselineAdjustment: UIBaselineAdjustment

Controls how text baselines are adjusted when text needs to shrink to fit in the label.

var minimumScaleFactor: CGFloat

The minimum scale factor supported for the label’s text.

var numberOfLines: Int

The maximum number of lines to use for rendering text.