]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
vt: add support for smput/rmput escape codes
authorCalixte Pernot <calixte.pernot@grenoble-inp.org>
Mon, 25 Aug 2025 12:56:09 +0000 (14:56 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 6 Sep 2025 13:48:32 +0000 (15:48 +0200)
commit23743ba64709a9c137c1b928f8b8e00d846af9cc
tree2df060ebb0376e1d46cbdaa5c0057330b9046602
parentcc4d900d0d6d8dd5c41832a93ff3cfa629a78f9a
vt: add support for smput/rmput escape codes

Support "\e[?1049h" and "\e[?1049l" escape codes.
This patch allows programs to enter and leave alternate screens.
This feature is widely available in graphical terminal emulators and mostly
used by fullscreen terminal-based user interfaces such as text editors.
Most editors such as vim and nano assume this escape code in not supported
and will not try to print the escape sequence if TERM=linux.
To try out this patch, run `TERM=xterm-256color vim` inside a VT.

Signed-off-by: Calixte Pernot <calixte.pernot@grenoble-inp.org>
Link: https://lore.kernel.org/r/20250825125607.2478-3-calixte.pernot@grenoble-inp.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/vt/vt.c
include/linux/console_struct.h