Skip to main content

Module multi_cursor

Module multi_cursor 

Source
Expand description

Multi-cursor operations for adding cursors at various positions

Enums§

AddCursorResult
Result of attempting to add a cursor

Functions§

add_cursor_above
Add a cursor above the primary cursor at the same column
add_cursor_at_next_match
Add a cursor at the next occurrence of the selected text If no selection, selects the entire word at cursor position first
add_cursor_below
Add a cursor below the primary cursor at the same column
line_end_positions_in_selection
Compute end-of-line byte positions for every line covered by ANY existing cursor’s selection (or the cursor’s current line when there is no selection). Used to place cursors at the end of each line, matching VSCode’s “Add Cursor to Line Ends” / Sublime’s “Split Selection into Lines” semantics where every existing cursor contributes, not just the primary.