From 61907330795649cbdc7c893bb152a6c198a4e67b Mon Sep 17 00:00:00 2001
From: Přemysl Janouch 
Date: Mon, 29 Feb 2016 02:50:41 +0100
Subject: degesch: mark a problem
---
 degesch.c | 8 ++++++++
 1 file changed, 8 insertions(+)
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);
-- 
cgit v1.2.3-70-g09d2