vim: Add horizontal scrolling support in vim mode (#32558)
Release Notes: - Added initial support for both `z l` and `z h` in vim mode These changes relate to #17219 but don't yet close the issue, as this Pull Request is simply adding support for horizontal scrolling in vim mode and actually moving the cursor to the correct column in the current row will be handled in a different Pull Request. Some notes on these changes: - 2 new default keybindings added to vim's keymap - `z l` which triggers the new `vim::ColumnRight` action - `z h` which triggers the new `vim::ColumnLeft` action - Introduced a new `ScrollAmount` variant, `ScrollAmount::Column(f32)` to represent horizontal scrolling - Replaced usage of `em_width` with `em_advance` to actually scroll by the width of the cursor, instead of the width of the character --------- Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
This commit is contained in:
parent
f63ae4388d
commit
9a6e8a19b5
5 changed files with 60 additions and 11 deletions
|
@ -184,6 +184,8 @@
|
|||
"z f": "editor::FoldSelectedRanges",
|
||||
"z shift-m": "editor::FoldAll",
|
||||
"z shift-r": "editor::UnfoldAll",
|
||||
"z l": "vim::ColumnRight",
|
||||
"z h": "vim::ColumnLeft",
|
||||
"shift-z shift-q": ["pane::CloseActiveItem", { "save_intent": "skip" }],
|
||||
"shift-z shift-z": ["pane::CloseActiveItem", { "save_intent": "save_all" }],
|
||||
// Count support
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue