Instance Method


Returns the ruler (paragraph) attributes in effect for the characters within the given range.


func rulerAttributes(in range: NSRange) -> [NSAttributedString.Key : Any]



The range.

Return Value

A dictionary containing the ruler attributes in the range.


The only ruler attribute currently defined is that named by paragraphStyle. Use this method to obtain attributes that are to be copied or pasted with “copy ruler” operations.

Raises an rangeException if any part of aRange lies beyond the end of the receiver’s characters.

See Also

Retrieving Font Attribute Information

func fontAttributes(in: NSRange) -> [NSAttributedString.Key : Any]

Returns the font attributes in effect for the character at the given location.