diff options
author | Mattias Andrée <maandree@kth.se> | 2021-04-02 01:55:44 +0200 |
---|---|---|
committer | Mattias Andrée <maandree@kth.se> | 2021-04-02 01:55:44 +0200 |
commit | a523a2d3669b8799121a9d4260decb20df39b590 (patch) | |
tree | 8d83eadb1cd20c94e04122095bdc7fdd2b0565e8 /libterminput.c | |
parent | Add TODO (diff) | |
download | libterminput-a523a2d3669b8799121a9d4260decb20df39b590.tar.gz libterminput-a523a2d3669b8799121a9d4260decb20df39b590.tar.bz2 libterminput-a523a2d3669b8799121a9d4260decb20df39b590.tar.xz |
Add more key codes
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to '')
-rw-r--r-- | libterminput.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/libterminput.c b/libterminput.c index a255373..d721abd 100644 --- a/libterminput.c +++ b/libterminput.c @@ -143,13 +143,19 @@ parse_sequence(union libterminput_input *input, struct libterminput_state *ctx) switch (keylen) { case 2: switch (ctx->key[1]) { + case '@': input->keypress.key = LIBTERMINPUT_INS; break; case 'A': input->keypress.key = LIBTERMINPUT_UP; break; case 'B': input->keypress.key = LIBTERMINPUT_DOWN; break; case 'C': input->keypress.key = LIBTERMINPUT_RIGHT; break; case 'D': input->keypress.key = LIBTERMINPUT_LEFT; break; case 'E': input->keypress.key = LIBTERMINPUT_BEGIN; break; + case 'F': input->keypress.key = LIBTERMINPUT_END; break; case 'G': input->keypress.key = LIBTERMINPUT_BEGIN; break; + case 'H': input->keypress.key = LIBTERMINPUT_HOME; break; + case 'M': input->keypress.key = LIBTERMINPUT_MACRO; break; case 'P': input->keypress.key = LIBTERMINPUT_PAUSE; break; + case 'U': input->keypress.key = LIBTERMINPUT_NEXT; break; + case 'V': input->keypress.key = LIBTERMINPUT_PRIOR; break; case 'Z': input->keypress.key = LIBTERMINPUT_TAB; input->keypress.mods |= LIBTERMINPUT_SHIFT; |