From: Pierre Habouzit Date: Wed, 28 Nov 2007 14:30:16 +0000 (+0100) Subject: Fix F-keys X-Git-Url: http://git.madism.org/?a=commitdiff_plain;h=455019bee68a67c26be011b390dd54eb1fce743f;p=apps%2Fmadmutt.git Fix F-keys Signed-off-by: Pierre Habouzit --- diff --git a/lib-ui/madtty.c b/lib-ui/madtty.c index 4cc53fb..3e2ca5b 100644 --- a/lib-ui/madtty.c +++ b/lib-ui/madtty.c @@ -110,16 +110,26 @@ static char const * const keytable[KEY_MAX+1] = { [KEY_PPAGE] = "\e[5~", [KEY_NPAGE] = "\e[6~", [KEY_SUSPEND] = "\x1A", /* Ctrl+Z gets mapped to this */ - [KEY_F(1)] = "\e[[A", - [KEY_F(2)] = "\e[[B", - [KEY_F(3)] = "\e[[C", - [KEY_F(4)] = "\e[[D", - [KEY_F(5)] = "\e[[E", + [KEY_F(1)] = "\e[11~", + [KEY_F(2)] = "\e[12~", + [KEY_F(3)] = "\e[13~", + [KEY_F(4)] = "\e[14~", + [KEY_F(5)] = "\e[15~", [KEY_F(6)] = "\e[17~", [KEY_F(7)] = "\e[18~", [KEY_F(8)] = "\e[19~", [KEY_F(9)] = "\e[20~", [KEY_F(10)] = "\e[21~", + [KEY_F(11)] = "\e[23~", + [KEY_F(12)] = "\e[24~", + [KEY_F(13)] = "\e[25~", + [KEY_F(14)] = "\e[26~", + [KEY_F(15)] = "\e[28~", + [KEY_F(16)] = "\e[29~", + [KEY_F(17)] = "\e[31~", + [KEY_F(18)] = "\e[32~", + [KEY_F(19)] = "\e[33~", + [KEY_F(20)] = "\e[34~", }; static void t_row_set(t_row_t *row, int start, int len, uint16_t attr)