on master help sign in
Add arrow keys to view mode (#987)
187197aNexiNov
book/src/keymap.md+12−12
@@ -128,18 +128,18 @@ key to return to normal mode after usage (useful when you're simply looking
128over text and not actively editing it).
128over text and not actively editing it).
129
129
130
130
131−| Key | Description | Command |
131+| Key | Description | Command |
132−| ----- | ----------- | ------- |
132+| ----- | ----------- | ------- |
133−| `z` , `c` | Vertically center the line | `align_view_center` |
133+| `z` , `c` | Vertically center the line | `align_view_center` |
134−| `t` | Align the line to the top of the screen | `align_view_top` |
134+| `t` | Align the line to the top of the screen | `align_view_top` |
135−| `b` | Align the line to the bottom of the screen | `align_view_bottom` |
135+| `b` | Align the line to the bottom of the screen | `align_view_bottom` |
136−| `m` | Align the line to the middle of the screen (horizontally) | `align_view_middle` |
136+| `m` | Align the line to the middle of the screen (horizontally) | `align_view_middle` |
137−| `j` | Scroll the view downwards | `scroll_down` |
137+| `j` , `down` | Scroll the view downwards | `scroll_down` |
138−| `k` | Scroll the view upwards | `scroll_up` |
138+| `k` , `up` | Scroll the view upwards | `scroll_up` |
139−| `f` | Move page down | `page_down` |
139+| `f` | Move page down | `page_down` |
140−| `b` | Move page up | `page_up` |
140+| `b` | Move page up | `page_up` |
141−| `d` | Move half page down | `half_page_down` |
141+| `d` | Move half page down | `half_page_down` |
142−| `u` | Move half page up | `half_page_up` |
142+| `u` | Move half page up | `half_page_up` |
143
143
144#### Goto mode
144#### Goto mode
145
145
helix-term/src/keymap.rs+4−4
@@ -651,8 +651,8 @@ impl Default for Keymaps {
651 "t" => align_view_top,
651 "t" => align_view_top,
652 "b" => align_view_bottom,
652 "b" => align_view_bottom,
653 "m" => align_view_middle,
653 "m" => align_view_middle,
654− "k" => scroll_up,
654+ "k" | "up" => scroll_up,
655− "j" => scroll_down,
655+ "j" | "down" => scroll_down,
656 "C-b" | "pageup" => page_up,
656 "C-b" | "pageup" => page_up,
657 "C-f" | "pagedown" => page_down,
657 "C-f" | "pagedown" => page_down,
658 "C-u" => half_page_up,
658 "C-u" => half_page_up,
@@ -663,8 +663,8 @@ impl Default for Keymaps {
663 "t" => align_view_top,
663 "t" => align_view_top,
664 "b" => align_view_bottom,
664 "b" => align_view_bottom,
665 "m" => align_view_middle,
665 "m" => align_view_middle,
666− "k" => scroll_up,
666+ "k" | "up" => scroll_up,
667− "j" => scroll_down,
667+ "j" | "down" => scroll_down,
668 "C-b" | "pageup" => page_up,
668 "C-b" | "pageup" => page_up,
669 "C-f" | "pagedown" => page_down,
669 "C-f" | "pagedown" => page_down,
670 "C-u" => half_page_up,
670 "C-u" => half_page_up,