From cf762c1482566dc8fcdea493b8f8a8a1b0710205 Mon Sep 17 00:00:00 2001 From: Guido Cella Date: Tue, 10 Oct 2023 08:33:08 +0200 Subject: [PATCH] console.lua: exit with with Ctrl+[ This binding commonly closes similar input buffers like vim's Command-line mode and dmenu. --- DOCS/man/console.rst | 2 +- player/lua/console.lua | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/DOCS/man/console.rst b/DOCS/man/console.rst index cfcc643323..30f849e885 100644 --- a/DOCS/man/console.rst +++ b/DOCS/man/console.rst @@ -11,7 +11,7 @@ Keybindings \` Show the console. -ESC +ESC and Ctrl+[ Hide the console. ENTER, Ctrl+J and Ctrl+M diff --git a/player/lua/console.lua b/player/lua/console.lua index c1958ef7dd..978ba51b6c 100644 --- a/player/lua/console.lua +++ b/player/lua/console.lua @@ -830,6 +830,7 @@ end function get_bindings() local bindings = { { 'esc', function() set_active(false) end }, + { 'ctrl+[', function() set_active(false) end }, { 'enter', handle_enter }, { 'kp_enter', handle_enter }, { 'shift+enter', function() handle_char_input('\n') end },