Instance Method

setAttributedString(_:)

Replaces the receiver’s entire contents with the characters and attributes of the given attributed string.

Declaration

func setAttributedString(_ attrString: NSAttributedString)

Parameters

attributedString

The attributed string whose characters and attributes replace those in the receiver.

See Also

Changing characters and attributes

func append(NSAttributedString)

Adds the characters and attributes of a given attributed string to the end of the receiver.

func insert(NSAttributedString, at: Int)

Inserts the characters and attributes of the given attributed string into the receiver at the given index.

func replaceCharacters(in: NSRange, with: NSAttributedString)

Replaces the characters and attributes in a given range with the characters and attributes of the given attributed string.