Contents

init(labelWithAttributedString:)

Creates a text field for use as a static label that displays styled text, doesn’t wrap, and doesn’t have selectable text.

Declaration

convenience init(labelWithAttributedString attributedStringValue: NSAttributedString)

Parameters

  • attributedStringValue:

    An attributed string to use as the content of the label.

Return Value

A text field that displays the specified attributed string as a static label.

Discussion

The text field determines its line-break mode by inspecting the paragraph style attributes in the attributed string.

See Also

Creating Text Fields