index(_:offsetByCharacters:)
Returns the position of the character offset a given distance, measured in characters, from a given string index.
Declaration
func index(_ i: AttributedString.Index, offsetByCharacters distance: Int) -> AttributedString.IndexParameters
- i:
The index of a position in the string.
- distance:
The number of charcters to advance by.
Return Value
The position of the character offset distance characters from position i.