[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Binding the escape key separate from arrow keys in the terminal
From: |
Pierre Rouleau |
Subject: |
Re: Binding the escape key separate from arrow keys in the terminal |
Date: |
Fri, 2 May 2025 07:51:38 -0400 |
On Fri, May 2, 2025 at 2:09 AM Yuri Khan <yuri.v.khan@gmail.com> wrote:
> On Fri, 2 May 2025 at 03:10, Spencer Baugh via Users list for the GNU
> Emacs text editor <help-gnu-emacs@gnu.org> wrote:
>
> <snip>
>
> 1. Ditch the classic terminal key encoding scheme. Terminal emulators
> such as Kitty and Wezterm have an advanced key encoding[1] where every
> key is distinguishable from every other key. You’d have to write a
> terminal-specific library that enables that encoding and modifies
> input-decode-map to decode that encoding. Also you’d have to make sure
> the terminal properly advertises itself in the TERM environment
> variable so that Emacs knows when to apply your library. (TERM=xterm
> or TERM=xterm-256color won’t cut it.) After you do this, you basically
> have the same key set as a GUI frame, and can bind <escape>.
>
> [1]: https://sw.kovidgoyal.net/kitty/keyboard-protocol/
>
> This sounds like an interesting/useful project on its own.
Nobody has done such a system so far?
--
/Pierre