Begin Visual mode, move cursor to the mouse click position
<RightMouse>
Example
Normal 0 / 1Visual 1 / 1one two
three fourCursor on line 1, column 1one two
three fourCursor on line 1, column 7 · Character selectionBegin Visual mode, move cursor to the mouse click position.
Prepared mouse event
- Click
line 1, column 7 (o in two)- Options
mouse=a · mousemodel=extend · selectmode empty
Extend a characterwise Visual selection through the clicked o.
Prepared mouse event
- Click
line 1, column 7 (o in two)- Options
mouse=a · mousemodel=extend · selectmode empty
Before & after
one two
three fourCursor on line 1, column 1Prepared mouse event
- Click
line 1, column 7 (o in two)- Options
mouse=a · mousemodel=extend · selectmode empty
one two
three fourCursor on line 1, column 7 · Character selectionPrepared mouse event
- Click
line 1, column 7 (o in two)- Options
mouse=a · mousemodel=extend · selectmode empty
ILLUSTRATION. mouse=a, mousemodel=extend, selectmode empty, scrolloff=0; terminal/GUI mouse events reach Vim. Coordinates are one-based buffer line and column. The starting cursor is line 1, column 1.
Details & Vim help
Begin Visual mode, move cursor to the mouse click position. Use in Normal mode. Availability and exact behavior can depend on Vim build features, options, mappings and editor state; the linked help is authoritative. Mouse support and terminal/GUI event handling must be available.