Companion

object Companion

Functions

Link copied to clipboard
fun create(ranges: List<SelectionRange>, mainIndex: Int = 0): EditorSelection

Sort and merge the given set of ranges, creating a valid selection.

Link copied to clipboard
fun cursor(pos: DocPos, assoc: Int = 0, bidiLevel: Int? = null, goalColumn: Int? = null): SelectionRange

Create a cursor selection range at the given position.

Link copied to clipboard

Create a selection from a JSON representation.

Link copied to clipboard
fun range(anchor: DocPos, head: DocPos, goalColumn: Int? = null, bidiLevel: Int? = null): SelectionRange

Create a selection range.

Link copied to clipboard
fun single(anchor: DocPos, head: DocPos = anchor): EditorSelection

Create a selection holding a single range.