Returns the trailing whitespace width for a line.
- iOS 3.2+
- macOS 10.5+
- Mac Catalyst 13.0+Beta
- tvOS 9.0+
- watchOS 2.0+
- Core Text
The line whose trailing whitespace width is calculated.
The width of the line's trailing whitespace. If the line is invalid, this function will always return zero.
Creating a line for a width can result in a line that is actually longer than the desired width due to trailing whitespace. Although this is typically not an issue due to whitespace being invisible, this function can be used to determine what amount of a line's width is due to trailing whitespace.