selectWord

abstract fun selectWord(position: Int, text: CharSequence): Pair<Int, Int>

Return

the left and right caret position to select the word at the given caret position

Parameters

position

The start position, which must be in the range 0 .. text.length (inclusive)