diff options
author | C. McEnroe | 2020-09-06 22:43:50 -0400 |
---|---|---|
committer | C. McEnroe | 2020-09-06 22:43:50 -0400 |
commit | 05f94f1b8b638a5f0b347d972bbbf1c3cad6f3e6 (patch) | |
tree | f0ac2557f2f6aee39f902cae3f1394f37bd1e233 /buffer.c | |
parent | f0fe44f35504788edc241e347252384517a33087 (diff) |
Handle non-alignment tabs in line wrapping
Diffstat (limited to 'buffer.c')
-rw-r--r-- | buffer.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/buffer.c b/buffer.c index ff21eb4..7478211 100644 --- a/buffer.c +++ b/buffer.c @@ -128,6 +128,9 @@ static int flow(struct Lines *hard, int cols, const struct Line *soft) { // zero-width, so just remove them entirely. memmove(str, &str[n], strlen(&str[n]) + 1); continue; + } else if (wc == L'\t') { + // XXX: Assuming TABSIZE = 8. + width += 8 - (width % 8); } else if (wc < L' ') { // XXX: ncurses will render these as "^A". width += 2; |