summary refs log tree commit diff
path: root/chat.h
diff options
context:
space:
mode:
authorJune McEnroe <june@causal.agency>2018-08-06 14:19:52 -0400
committerJune McEnroe <june@causal.agency>2018-08-06 14:19:52 -0400
commitd6fb797b11aa6dd031032faf425be3ce5a69661d (patch)
treee348e4ec6ed53a9700219336fd6a3e3733093a56 /chat.h
parentRename line editing functions (diff)
downloadcatgirl-d6fb797b11aa6dd031032faf425be3ce5a69661d.tar.gz
catgirl-d6fb797b11aa6dd031032faf425be3ce5a69661d.zip
Use wchar_t strings for all of UI
vaswprintf is a nightmare.
Diffstat (limited to '')
-rw-r--r--chat.h13
1 files changed, 9 insertions, 4 deletions
diff --git a/chat.h b/chat.h
index 2c9239c..3d3586c 100644
--- a/chat.h
+++ b/chat.h
@@ -16,6 +16,7 @@
 
 #define SOURCE_URL "https://code.causal.agency/june/chat"
 
+#include <stdarg.h>
 #include <stdbool.h>
 #include <stdlib.h>
 #include <wchar.h>
@@ -41,11 +42,15 @@ void uiInit(void);
 void uiHide(void);
 void uiDraw(void);
 void uiRead(void);
-void uiTopic(const char *topic);
-void uiLog(const char *line);
+void uiTopic(const wchar_t *topic);
+void uiTopicStr(const char *topic);
+void uiLog(const wchar_t *line);
 
-__attribute__((format(printf, 1, 2)))
-void uiFmt(const char *format, ...);
+//__attribute__((format(printf, 1, 2)))
+void uiFmt(const wchar_t *format, ...);
 
 void handle(char *line);
 void input(wchar_t *line);
+
+wchar_t *wcssep(wchar_t **stringp, const wchar_t *delim);
+int vaswprintf(wchar_t **ret, const wchar_t *format, va_list ap);