feat: add emacs style keybind for command palette (A-x)
A-x is also more likely tmux compatible
This commit is contained in:
parent
e710637f95
commit
f631b672c4
2 changed files with 4 additions and 2 deletions
|
@ -153,6 +153,7 @@ fn mapPress(self: *Self, keypress: u32, egc: u32, modifiers: u32) !void {
|
||||||
'F' => self.cmd("move_word_right", .{}),
|
'F' => self.cmd("move_word_right", .{}),
|
||||||
'S' => self.cmd("filter", command.fmt(.{"sort"})),
|
'S' => self.cmd("filter", command.fmt(.{"sort"})),
|
||||||
'V' => self.cmd("paste", .{}),
|
'V' => self.cmd("paste", .{}),
|
||||||
|
'X' => self.cmd("open_command_palette", .{}),
|
||||||
key.LEFT => self.cmd("jump_back", .{}),
|
key.LEFT => self.cmd("jump_back", .{}),
|
||||||
key.RIGHT => self.cmd("jump_forward", .{}),
|
key.RIGHT => self.cmd("jump_forward", .{}),
|
||||||
key.UP => self.cmd("pull_up", .{}),
|
key.UP => self.cmd("pull_up", .{}),
|
||||||
|
@ -379,7 +380,7 @@ const hints = tui.KeybindHints.initComptime(.{
|
||||||
.{ "move_up", "up" },
|
.{ "move_up", "up" },
|
||||||
.{ "move_word_left", "C-left, A-b" },
|
.{ "move_word_left", "C-left, A-b" },
|
||||||
.{ "move_word_right", "C-right, A-f" },
|
.{ "move_word_right", "C-right, A-f" },
|
||||||
.{ "open_command_palette", "C-S-p, S-A-p" },
|
.{ "open_command_palette", "C-S-p, S-A-p, A-x" },
|
||||||
.{ "open_file", "C-o" },
|
.{ "open_file", "C-o" },
|
||||||
.{ "open_recent", "C-e" },
|
.{ "open_recent", "C-e" },
|
||||||
.{ "open_recent_project", "C-r" },
|
.{ "open_recent_project", "C-r" },
|
||||||
|
|
|
@ -87,6 +87,7 @@ fn mapPress(self: *Self, keypress: u32, modifiers: u32) tp.result {
|
||||||
'P' => self.cmd("goto_prev_file_or_diagnostic", .{}),
|
'P' => self.cmd("goto_prev_file_or_diagnostic", .{}),
|
||||||
'L' => self.cmd("toggle_panel", .{}),
|
'L' => self.cmd("toggle_panel", .{}),
|
||||||
'I' => self.cmd("toggle_inputview", .{}),
|
'I' => self.cmd("toggle_inputview", .{}),
|
||||||
|
'X' => self.cmd("open_command_palette", .{}),
|
||||||
key.LEFT => self.cmd("jump_back", .{}),
|
key.LEFT => self.cmd("jump_back", .{}),
|
||||||
key.RIGHT => self.cmd("jump_forward", .{}),
|
key.RIGHT => self.cmd("jump_forward", .{}),
|
||||||
else => {},
|
else => {},
|
||||||
|
@ -160,7 +161,7 @@ const hints = tui.KeybindHints.initComptime(.{
|
||||||
.{ "open_file", "o, C-o" },
|
.{ "open_file", "o, C-o" },
|
||||||
.{ "open_recent", "e, C-e" },
|
.{ "open_recent", "e, C-e" },
|
||||||
.{ "open_recent_project", "r, C-r" },
|
.{ "open_recent_project", "r, C-r" },
|
||||||
.{ "open_command_palette", "p, C-S-p, S-A-p" },
|
.{ "open_command_palette", "p, C-S-p, S-A-p, A-x" },
|
||||||
.{ "home_menu_activate", "enter" },
|
.{ "home_menu_activate", "enter" },
|
||||||
.{ "home_menu_down", "down" },
|
.{ "home_menu_down", "down" },
|
||||||
.{ "home_menu_up", "up" },
|
.{ "home_menu_up", "up" },
|
||||||
|
|
Loading…
Add table
Reference in a new issue