From 624343388b02eb2f5199ee8fcd29961ba3b17581 Mon Sep 17 00:00:00 2001 From: Raphael 'kena' Poss Date: Thu, 25 Aug 2022 19:43:05 +0200 Subject: [PATCH] Support linux console F1-F5 --- key.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/key.go b/key.go index 8ebaeebcbd..135571bebb 100644 --- a/key.go +++ b/key.go @@ -394,6 +394,13 @@ var sequences = map[string]Key{ "\x1b\x1b[7~": {Type: KeyHome, Alt: true}, // urxvt "\x1b\x1b[8~": {Type: KeyEnd, Alt: true}, // urxvt + // Function keys, Linux console + "\x1b[[A": {Type: KeyF1}, // linux console + "\x1b[[B": {Type: KeyF2}, // linux console + "\x1b[[C": {Type: KeyF3}, // linux console + "\x1b[[D": {Type: KeyF4}, // linux console + "\x1b[[E": {Type: KeyF5}, // linux console + // Function keys, X11 "\x1bOP": {Type: KeyF1}, // vt100 "\x1bOQ": {Type: KeyF2}, // vt100