Skip to content

Commit

Permalink
vim: Add support for insert button (#19245)
Browse files Browse the repository at this point in the history
This commit adds support for using the physical insert-button. First
click toggles insert mode and subsequent clicks toggle back and forth
between replace and insert mode.

Closes #19224

Release Notes:

- Added support for using the insert button for vim_mode.
  • Loading branch information
axelcarl authored Oct 16, 2024
1 parent a56f946 commit a77ec94
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions assets/keymaps/vim.json
Original file line number Diff line number Diff line change
Expand Up @@ -256,6 +256,7 @@
"@": ["vim::PushOperator", "ReplayRegister"],
"ctrl-pagedown": "pane::ActivateNextItem",
"ctrl-pageup": "pane::ActivatePrevItem",
"insert": "vim::InsertBefore",
// tree-sitter related commands
"[ x": "editor::SelectLargerSyntaxNode",
"] x": "editor::SelectSmallerSyntaxNode",
Expand Down Expand Up @@ -338,7 +339,8 @@
"ctrl-t": "vim::Indent",
"ctrl-d": "vim::Outdent",
"ctrl-k": ["vim::PushOperator", { "Digraph": {} }],
"ctrl-r": ["vim::PushOperator", "Register"]
"ctrl-r": ["vim::PushOperator", "Register"],
"insert": "vim::ToggleReplace"
}
},
{
Expand All @@ -357,7 +359,8 @@
"ctrl-k": ["vim::PushOperator", { "Digraph": {} }],
"backspace": "vim::UndoReplace",
"tab": "vim::Tab",
"enter": "vim::Enter"
"enter": "vim::Enter",
"insert": "vim::InsertBefore"
}
},
{
Expand Down

0 comments on commit a77ec94

Please sign in to comment.