selection

fun selection(cursor: DocPos)

Set the initial cursor position.


fun selection(anchor: DocPos, head: DocPos)

Set the initial selection as a range.


fun selection(selection: EditorSelection)

Set the initial selection from an EditorSelection.