diff options
| author | Daniel Eklöf <daniel@ekloef.se> | 2019-06-19 08:04:47 +0000 |
|---|---|---|
| committer | Daniel Eklöf <daniel@ekloef.se> | 2019-06-19 08:04:47 +0000 |
| commit | 71dde121e63177b0fc1bc2d6897e63e533d666fc (patch) | |
| tree | fae25ca409f8edce97b5ab14dc037343e0fb74c1 /terminal.h | |
| parent | csi: CSI log messages are now single line (diff) | |
wip: initial input handling
Diffstat (limited to 'terminal.h')
| -rw-r--r-- | terminal.h | 26 |
1 files changed, 26 insertions, 0 deletions
@@ -4,6 +4,11 @@ #include <stdbool.h> #include <stddef.h> +#include <threads.h> + +#include <xkbcommon/xkbcommon.h> +#include <xkbcommon/xkbcommon-keysyms.h> + struct attributes { bool bold; bool italic; @@ -73,8 +78,29 @@ struct vt { bool dim; }; +struct kbd { + struct xkb_context *xkb; + struct xkb_keymap *xkb_keymap; + struct xkb_state *xkb_state; + struct { + mtx_t mutex; + cnd_t cond; + int trigger; + int pipe_read_fd; + int pipe_write_fd; + enum {REPEAT_STOP, REPEAT_START, REPEAT_EXIT} cmd; + + bool dont_re_repeat; + int32_t delay; + int32_t rate; + uint32_t key; + } repeat; +}; + struct terminal { + pid_t slave; int ptmx; struct vt vt; struct grid grid; + struct kbd kbd; }; |
