Step 2 of 5

Extending selections

Extending selections

In select mode you use the navigation commands that you already know. The only difference is what they do to the selection.

Try it on the practice line: in normal mode, each w selects just one word. Press v, and the same w now adds the next word to the selection instead. Every motion behaves this way — e, b, h, j, k, l, and the rest all grow the selection towards wherever the cursor ends up.

That includes motions that move between lines. Press j in select mode and the selection stretches down to the line below, which is how you select several lines at once.

Work through the checklist below.

  1. Select a word with w Put the cursor on the practice line and press w — a single word lights up.
  2. Switch to select mode Press v — the selection stays, and the statusline reads SEL.
  3. Grow the selection with w Press w again — this time the selection extends to cover the next word too.
  4. Grow it by a line with j Press j — the selection reaches down onto the next line.
Select a word with w Put the cursor on the practice line and press w — a single word lights up.

Next: Switch to select mode

Loading editor…