Instance Method

accessibilityFrame(for:)

Returns the rectangle enclosing the specified range of characters.

Required.

Declaration

func accessibilityFrame(for range: NSRange) -> NSRect

Parameters

range

The range of characters.

Return Value

The rectangle that encloses the specified characters.

Discussion

If the range crosses a line boundary, the returned rectangle will fully enclose all the lines of characters.

See Also

Text Navigation Methods

func accessibilityLine(for: Int) -> Int

Returns the line number for the line holding the specified character index.

Required.

func accessibilityRange(forLine: Int) -> NSRange

Returns the range of characters in the specified line.

Required.

func accessibilityString(for: NSRange) -> String?

Returns the substring for the specified range.

Required.