diff options
author | nicm <nicm> | 2016-03-01 12:02:08 +0000 |
---|---|---|
committer | nicm <nicm> | 2016-03-01 12:02:08 +0000 |
commit | 26945d7956bf1f160fba72677082e1a9c6968e0c (patch) | |
tree | 2eddf33b2a95384f21b9b315715843df57b4a784 /tmux.h | |
parent | c7851e0ee71e26ee9af67f2523679132369b152f (diff) | |
download | rtmux-26945d7956bf1f160fba72677082e1a9c6968e0c.tar.gz rtmux-26945d7956bf1f160fba72677082e1a9c6968e0c.tar.bz2 rtmux-26945d7956bf1f160fba72677082e1a9c6968e0c.zip |
Use system wcwidth() instead of carrying around UTF-8 width tables.
Diffstat (limited to 'tmux.h')
-rw-r--r-- | tmux.h | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -32,6 +32,7 @@ #include <stdint.h> #include <stdio.h> #include <termios.h> +#include <wchar.h> #include "xmalloc.h" @@ -2311,14 +2312,13 @@ void session_group_synchronize1(struct session *, struct session *); void session_renumber_windows(struct session *); /* utf8.c */ -u_int utf8_width(u_int); void utf8_set(struct utf8_data *, u_char); void utf8_copy(struct utf8_data *, const struct utf8_data *); enum utf8_state utf8_open(struct utf8_data *, u_char); enum utf8_state utf8_append(struct utf8_data *, u_char); -u_int utf8_combine(const struct utf8_data *); -enum utf8_state utf8_split(u_int, struct utf8_data *); -u_int utf8_split2(u_int, u_char *); +u_int utf8_width(wchar_t); +wchar_t utf8_combine(const struct utf8_data *); +enum utf8_state utf8_split(wchar_t, struct utf8_data *); int utf8_strvis(char *, const char *, size_t, int); char *utf8_sanitize(const char *); struct utf8_data *utf8_fromcstr(const char *); |