diff options
| author | Daniel Eklöf <daniel@ekloef.se> | 2021-06-15 10:38:35 +0000 |
|---|---|---|
| committer | Daniel Eklöf <daniel@ekloef.se> | 2021-06-15 10:38:35 +0000 |
| commit | 5caa87adaf6c54a412fcd8a070c4275619e8c410 (patch) | |
| tree | b7f0cc16b6ca246dfbcaecd95fb41d7e57849a6a | |
| parent | Revert "gitignore: compile_commands.json + .ccls-cache" (diff) | |
term: no need to set attrs.clean=0 right after copying the VT attrs struct
When printing a character to a cell, we copy the current VT state’s
attributes to the cell. And then clear the ‘clean’ bit.
But the ‘clean’ bit is part of the VT state, and is *always*
zero. Thus there’s no need to explicitly clear it right after copying
the VT state.
| -rw-r--r-- | terminal.c | 3 |
1 files changed, 0 insertions, 3 deletions
@@ -2742,7 +2742,6 @@ print_spacer(struct terminal *term, int col, int remaining) cell->wc = CELL_SPACER + remaining; cell->attrs = term->vt.attrs; - cell->attrs.clean = 0; } void @@ -2792,7 +2791,6 @@ term_print(struct terminal *term, wchar_t wc, int width) row->dirty = true; row->linebreak = false; - cell->attrs.clean = 0; /* Advance cursor the 'additional' columns while dirty:ing the cells */ for (int i = 1; i < width && term->grid->cursor.point.col < term->cols - 1; i++) { @@ -2832,7 +2830,6 @@ ascii_printer_fast(struct terminal *term, wchar_t wc) row->dirty = true; row->linebreak = false; - cell->attrs.clean = 0; /* Advance cursor */ if (unlikely(++term->grid->cursor.point.col >= term->cols)) { |
