Skip to content

Commit

Permalink
fix vim example's e mapping in operator-pending mode (fix #76)
Browse files Browse the repository at this point in the history
  • Loading branch information
rhysd committed Aug 1, 2024
1 parent 2ebce01 commit 76f1ab6
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions examples/vim.rs
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,13 @@ impl Vim {
key: Key::Char('w'),
..
} => textarea.move_cursor(CursorMove::WordForward),
Input {
key: Key::Char('e'),
ctrl: false,
..
} if matches!(self.mode, Mode::Operator(_)) => {
textarea.move_cursor(CursorMove::WordForward) // `e` behaves like `w` in operator-pending mode
}
Input {
key: Key::Char('e'),
ctrl: false,
Expand Down

0 comments on commit 76f1ab6

Please sign in to comment.