summaryrefslogtreecommitdiff
path: root/degesch.c
diff options
context:
space:
mode:
authorPřemysl Janouch <p.janouch@gmail.com>2016-02-29 02:50:41 +0100
committerPřemysl Janouch <p.janouch@gmail.com>2016-02-29 02:50:41 +0100
commit61907330795649cbdc7c893bb152a6c198a4e67b (patch)
treec5ab390995512fa3952bb6b374a277ab79ee7719 /degesch.c
parent676e6c20fa0b7f4c2186880a8938fd8fae7b99bc (diff)
downloadxK-61907330795649cbdc7c893bb152a6c198a4e67b.tar.gz
xK-61907330795649cbdc7c893bb152a6c198a4e67b.tar.xz
xK-61907330795649cbdc7c893bb152a6c198a4e67b.zip
degesch: mark a problem
Diffstat (limited to 'degesch.c')
-rw-r--r--degesch.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/degesch.c b/degesch.c
index 912a489..7b8494f 100644
--- a/degesch.c
+++ b/degesch.c
@@ -3063,6 +3063,14 @@ buffer_line_flush (struct buffer_line *line, struct formatter *f, FILE *output,
for (struct formatter_item *iter = line->items; iter->type; iter++)
formatter_add_item (f, *iter);
+ // XXX: we could reset attributes _before_ the newline. That, however,
+ // doesn't really work, because when the line wraps at the end of the
+ // screen and a background colour is set, the terminal paints the entire
+ // new line with that colour. "clr_to_eol" is not a solution in that
+ // case either, because it may delete the last character on a non-wrapped
+ // line, and while we can append an extra space as a workaround, that can
+ // cause an extra wrap for which I've found no way of avoiding.
+ // TODO: think about manual line wrapping; that way we can also word wrap
formatter_add (f, "\n");
formatter_flush (f, output, raw_attributes);
formatter_free (f);