diff options
author | Thomas Adam <thomas@xteddy.org> | 2015-11-14 11:38:30 +0000 |
---|---|---|
committer | Thomas Adam <thomas@xteddy.org> | 2015-11-14 11:38:30 +0000 |
commit | 7b749eff3510ccf173c029a92c266e91454ce600 (patch) | |
tree | 8194d8dcf4d3364360960c741a3266cb9a9d7101 /input.c | |
parent | 23266e8e095fb590543d309ae3c8e30fcd98d6b7 (diff) | |
parent | c56b81a2ce815f6d289232f20bb6e07cfd0e36ec (diff) | |
download | rtmux-7b749eff3510ccf173c029a92c266e91454ce600.tar.gz rtmux-7b749eff3510ccf173c029a92c266e91454ce600.tar.bz2 rtmux-7b749eff3510ccf173c029a92c266e91454ce600.zip |
Merge branch 'obsd-master'
Conflicts:
server.c
tmux.c
Diffstat (limited to 'input.c')
-rw-r--r-- | input.c | 21 |
1 files changed, 15 insertions, 6 deletions
@@ -1921,9 +1921,12 @@ input_exit_rename(struct input_ctx *ictx) int input_utf8_open(struct input_ctx *ictx) { - log_debug("%s", __func__); + struct utf8_data *ud = &ictx->utf8data; + + utf8_open(ud, ictx->ch); + + log_debug("%s %hhu", __func__, ud->size); - utf8_open(&ictx->utf8data, ictx->ch); return (0); } @@ -1931,9 +1934,12 @@ input_utf8_open(struct input_ctx *ictx) int input_utf8_add(struct input_ctx *ictx) { + struct utf8_data *ud = &ictx->utf8data; + + utf8_append(ud, ictx->ch); + log_debug("%s", __func__); - utf8_append(&ictx->utf8data, ictx->ch); return (0); } @@ -1941,11 +1947,14 @@ input_utf8_add(struct input_ctx *ictx) int input_utf8_close(struct input_ctx *ictx) { - log_debug("%s", __func__); + struct utf8_data *ud = &ictx->utf8data; + + utf8_append(ud, ictx->ch); - utf8_append(&ictx->utf8data, ictx->ch); + log_debug("%s %hhu '%*s' (width %hhu)", __func__, ud->size, + (int)ud->size, ud->data, ud->width); - utf8_copy(&ictx->cell.cell.data, &ictx->utf8data); + utf8_copy(&ictx->cell.cell.data, ud); screen_write_cell(&ictx->ctx, &ictx->cell.cell); return (0); |