diff options
author | Curtis McEnroe | 2018-08-08 16:59:26 -0400 |
---|---|---|
committer | Curtis McEnroe | 2018-08-08 16:59:26 -0400 |
commit | eac0f83efa3d6b1db2715c21d60b170a546ebc0a (patch) | |
tree | c8db1326e24716e29d3c9b06e42527178d030fa1 /chat.h | |
parent | b66c8abf707e6574f6867b646dfb2549a5a7147f (diff) |
Factor out line editing to edit.c
Diffstat (limited to 'chat.h')
-rw-r--r-- | chat.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/chat.h b/chat.h index 09f0d2c..9507f12 100644 --- a/chat.h +++ b/chat.h @@ -18,6 +18,7 @@ #include <stdarg.h> #include <stdbool.h> +#include <stdio.h> #include <stdlib.h> #include <wchar.h> @@ -31,6 +32,15 @@ struct { char *chan; } chat; +enum { + IRC_BOLD = 002, + IRC_COLOR = 003, + IRC_REVERSE = 026, + IRC_RESET = 017, + IRC_ITALIC = 035, + IRC_UNDERLINE = 037, +}; + int ircConnect(const char *host, const char *port, const char *webPass); void ircRead(void); void ircWrite(const char *ptr, size_t len); @@ -58,6 +68,10 @@ void uiFmt(const wchar_t *format, ...); } while(0) #endif +const wchar_t *editHead(void); +const wchar_t *editTail(void); +bool edit(bool meta, bool ctrl, wchar_t ch); + void handle(char *line); void input(char *line); |