Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add eb word selection trick to the tutor #5247

Merged
merged 1 commit into from
Dec 24, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 28 additions & 6 deletions runtime/tutor
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,7 @@ _________________________________________________________________


=================================================================
= 3.2 MORE ON MOTIONS =
= 3.2 MORE MOTIONS =
=================================================================

As you saw, typing w moves the cursor forward until the start
Expand All @@ -253,6 +253,19 @@ _________________________________________________________________
e - Move forward to the end of the current word.
b - Move backward to the beginning of the current word.

To select the word under cursor, combine e and b.

1. Move the cursor to the line marked '-->' below.
2. Move to a 'd' letter.
3. Type e to select a half of the word.
4. Type b to select the rest.

--> The Middle Kingdom.

=================================================================
= 3.3 WORDS AND words =
=================================================================

The w,e,b motions also have counterparts - W,E,B - which
traverse WORDS instead of words. WORDS are only separated by
whitespace, whereas words can be separated by other characters
Expand All @@ -262,8 +275,17 @@ _________________________________________________________________












=================================================================
= 3.3 THE CHANGE COMMAND =
= 3.4 THE CHANGE COMMAND =
=================================================================

Type c to change the current selection.
Expand All @@ -285,7 +307,7 @@ _________________________________________________________________


=================================================================
= 3.4 COUNTS WITH MOTIONS =
= 3.5 COUNTS WITH MOTIONS =
=================================================================

Type a number before a motion to repeat it that many times.
Expand All @@ -307,7 +329,7 @@ _________________________________________________________________


=================================================================
= 3.5 SELECT / EXTEND MODE =
= 3.6 SELECT / EXTEND MODE =
=================================================================

Type v to enter Select mode.
Expand All @@ -329,7 +351,7 @@ _________________________________________________________________


=================================================================
= 3.6 SELECTING LINES =
= 3.7 SELECTING LINES =
=================================================================

Type x to select a whole line. Type x again to select the next.
Expand All @@ -351,7 +373,7 @@ _________________________________________________________________
subsequent lines. X on an empty line does nothing.

=================================================================
= 3.7 COLLAPSING SELECTIONS =
= 3.8 COLLAPSING SELECTIONS =
=================================================================

Type ; to collapse selections to single cursors.
Expand Down