That's correct. In fact, after a test, it adds \e[0;39;49m if the previous cell
had no colour. There's two issues I can see:
1) If the previous cell's colour was default, it will add the above default
colours superfluously.
2) If the current cell colour changes in addition to the attribute being
Or this which actually builds...
diff --git a/grid.c b/grid.c
index a84a58b..8f5a669 100644
--- a/grid.c
+++ b/grid.c
@@ -75,7 +75,7 @@ void grid_reflow_split(struct grid *, u_int *, struct
grid_line *, u_int,
void grid_reflow_move(struct grid *, u_int *, struct grid_line *);
size_t grid_st
Does this work? If we do this can probably drop lastattr too and maybe
move the memcpy inside the _code func.
diff --git a/grid.c b/grid.c
index a84a58b..12ec643 100644
--- a/grid.c
+++ b/grid.c
@@ -477,7 +477,7 @@ grid_string_cells_bg(const struct grid_cell *gc, int
*values)
* bytes.
*/
voi
If the cell is default fg/bg, won't this add \e[0m\e[39m\[49m? The two
colour changes are unnecessary.
On Tue, Sep 16, 2014 at 06:39:38PM +, Matthew Darby wrote:
>Hi,
>grid_string_cells_code in grid.c currently resets all attributes when it
>finds the current cell lacks an attribu
Hi,
grid_string_cells_code in grid.c currently resets all attributes when it finds
the current cell lacks an attribute from the previous cell. Remaining
non-colour attributes seem to be well-looked after, but any colours set are
lost. The supplied patch restores the colours from the previous