summaryrefslogtreecommitdiff
path: root/libterm/term.h
diff options
context:
space:
mode:
Diffstat (limited to 'libterm/term.h')
-rw-r--r--libterm/term.h26
1 files changed, 26 insertions, 0 deletions
diff --git a/libterm/term.h b/libterm/term.h
index 0be7391..b399cd6 100644
--- a/libterm/term.h
+++ b/libterm/term.h
@@ -16,6 +16,32 @@
#include "screen_modes.h"
#include "debug.h"
+enum TERM_KEY_ACTION {
+ KEY_NULL = 0, /* NULL */
+ CTRL_A = 1, /* Ctrl+a */
+ CTRL_B = 2, /* Ctrl-b */
+ CTRL_C = 3, /* Ctrl-c */
+ CTRL_D = 4, /* Ctrl-d */
+ CTRL_E = 5, /* Ctrl-e */
+ CTRL_F = 6, /* Ctrl-f */
+ CTRL_H = 8, /* Ctrl-h */
+ TAB = 9, /* Tab */
+ CTRL_K = 11, /* Ctrl+k */
+ CTRL_L = 12, /* Ctrl+l */
+ ENTER = 13, /* Enter */
+ CTRL_N = 14, /* Ctrl-n */
+ CTRL_P = 16, /* Ctrl-p */
+ CTRL_T = 20, /* Ctrl-t */
+ CTRL_U = 21, /* Ctrl+u */
+ CTRL_W = 23, /* Ctrl+w */
+ ESC = 27, /* Escape */
+ BACKSPACE = 127 /* Backspace */
+};
+
+
+#define TK_ENTER 13
+#define TK_ESC 27
+#define TK_BACKSPACE 127
typedef struct term_screen
{