Label.getSelectionBounds

bool getSelectionBounds(out int start, out int end)

Gets the selected range of characters in the label, returning true if there’s a selection.

Parameters

startreturn location for start of selection, as a character offset
endreturn location for end of selection, as a character offset

Returns

true if selection is non-empty