diff options
author | nicm <nicm> | 2020-06-02 20:10:23 +0000 |
---|---|---|
committer | nicm <nicm> | 2020-06-02 20:10:23 +0000 |
commit | 2a4d4bda2b94602e9f999ff0b59efa92613f75a9 (patch) | |
tree | 86cd9c1ee3eac4f1a9aacb9b9d1a3062ec106a09 /grid.c | |
parent | f5366ff828cde78c140efa2dd9453956b59f5241 (diff) | |
download | rtmux-2a4d4bda2b94602e9f999ff0b59efa92613f75a9.tar.gz rtmux-2a4d4bda2b94602e9f999ff0b59efa92613f75a9.tar.bz2 rtmux-2a4d4bda2b94602e9f999ff0b59efa92613f75a9.zip |
Allow UTF-8 characters of width 0 to be stored, it is useful to be able
to put padding cells in as width 0.
Diffstat (limited to 'grid.c')
-rw-r--r-- | grid.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -76,7 +76,7 @@ grid_need_extended_cell(const struct grid_cell_entry *gce, return (1); if (gc->attr > 0xff) return (1); - if (gc->data.size > 1 || gc->data.width > 1) + if (gc->data.size != 1 || gc->data.width != 1) return (1); if ((gc->fg & COLOUR_FLAG_RGB) || (gc->bg & COLOUR_FLAG_RGB)) return (1); @@ -570,7 +570,7 @@ grid_set_cells(struct grid *gd, u_int px, u_int py, const struct grid_cell *gc, gce = &gl->celldata[px + i]; if (grid_need_extended_cell(gce, gc)) { gee = grid_extended_cell(gl, gce, gc); - gee->data = utf8_build_one(s[i], 1); + gee->data = utf8_build_one(s[i]); } else grid_store_cell(gce, gc, s[i]); } |