diff --git a/meli.conf.5 b/meli.conf.5 index cc2f2eaf0..b67ccda2d 100644 --- a/meli.conf.5 +++ b/meli.conf.5 @@ -456,6 +456,10 @@ exit_thread = 'i' .Pp .Em general .Bl -tag -width 36n +.It Ic toggle_help +Toggle help and shortcuts view. +.\" default value +.Pq Em \&? .It Ic enter_command_mode Enter .Em COMMAND diff --git a/src/components/utilities.rs b/src/components/utilities.rs index 31d640a93..604fc6eac 100644 --- a/src/components/utilities.rs +++ b/src/components/utilities.rs @@ -1653,7 +1653,7 @@ impl Component for Tabbed { self.set_dirty(true); return true; } - UIEvent::Input(Key::Char('?')) => { + UIEvent::Input(ref key) if shortcut!(key == shortcuts["general"]["toggle_help"]) => { if self.show_shortcuts { /* children below the shortcut overlay must be redrawn */ self.set_dirty(true); diff --git a/src/conf/shortcuts.rs b/src/conf/shortcuts.rs index 22553e3a1..031b08787 100644 --- a/src/conf/shortcuts.rs +++ b/src/conf/shortcuts.rs @@ -211,6 +211,7 @@ shortcut_key_values! { "pager", shortcut_key_values! { "general", pub struct GeneralShortcuts { + toggle_help |> "Toggle help and shortcuts view." |> Key::Char('?'), enter_command_mode |> "Enter COMMAND mode." |> Key::Char(' '), go_to_tab |> "Go to the nth tab" |> Key::Alt('n'), next_tab |> "Next tab." |> Key::Char('T'),