diff options
author | Thomas Adam <thomas@xteddy.org> | 2020-06-03 00:01:20 +0100 |
---|---|---|
committer | Thomas Adam <thomas@xteddy.org> | 2020-06-03 00:01:20 +0100 |
commit | 62c0617d791c68132328e77a683897a5a42a4044 (patch) | |
tree | ab47549816070e4f89727590a1ec464c1cd4cc74 /tty.c | |
parent | 3d5decb305a960edb0ca3d91ceec3929dcbc8c3e (diff) | |
parent | 4694e9a2b62c8df0862d80237e42978d65fc824e (diff) | |
download | rtmux-62c0617d791c68132328e77a683897a5a42a4044.tar.gz rtmux-62c0617d791c68132328e77a683897a5a42a4044.tar.bz2 rtmux-62c0617d791c68132328e77a683897a5a42a4044.zip |
Merge branch 'obsd-master'
Diffstat (limited to 'tty.c')
-rw-r--r-- | tty.c | 9 |
1 files changed, 5 insertions, 4 deletions
@@ -1380,9 +1380,10 @@ tty_draw_line(struct tty *tty, struct screen *s, u_int px, u_int py, u_int nx, screen_select_cell(s, &last, gcp); else memcpy(&last, gcp, sizeof last); - if (!tty_check_overlay(tty, atx + ux, aty)) - ux += gcp->data.width; - else if (ux + gcp->data.width > nx) { + if (!tty_check_overlay(tty, atx + ux, aty)) { + if (~gcp->flags & GRID_FLAG_PADDING) + ux += gcp->data.width; + } else if (ux + gcp->data.width > nx) { tty_attributes(tty, &last, defaults, palette); tty_cursor(tty, atx + ux, aty); for (j = 0; j < gcp->data.width; j++) { @@ -1397,7 +1398,7 @@ tty_draw_line(struct tty *tty, struct screen *s, u_int px, u_int py, u_int nx, for (j = 0; j < gcp->data.size; j++) tty_putc(tty, gcp->data.data[j]); ux += gcp->data.width; - } else { + } else if (~gcp->flags & GRID_FLAG_PADDING) { memcpy(buf + len, gcp->data.data, gcp->data.size); len += gcp->data.size; width += gcp->data.width; |