mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-02-05 04:06:08 -05:00
term: print: erase existing OSC-8 URI
If we have an “active” OSC-8 URI, term_print() would correctly replace an existing URI with the new one. But, if we don’t have an active URI, an existing URI was not erased. This can be reproduced with e.g echo -e '\e]8;;http://foo.bar\e\\foobar\e]8;;\e\\\b\b\b\b\b😀\n'
This commit is contained in:
parent
4986df7eeb
commit
3f10ee87b1
2 changed files with 4 additions and 1 deletions
|
|
@ -66,6 +66,8 @@
|
|||
(https://codeberg.org/dnkl/foot/issues/851).
|
||||
* Crash when maximizing the window and `[csd].size=1`
|
||||
(https://codeberg.org/dnkl/foot/issues/857).
|
||||
* OSC-8 URIs not getting overwritten (erased) by double-width
|
||||
characters (e.g. emojis).
|
||||
|
||||
|
||||
### Security
|
||||
|
|
|
|||
|
|
@ -3262,7 +3262,8 @@ term_print(struct terminal *term, wchar_t wc, int width)
|
|||
case OSC8_UNDERLINE_URL_MODE:
|
||||
break;
|
||||
}
|
||||
}
|
||||
} else if (row->extra != NULL)
|
||||
grid_row_uri_range_erase(row, col, col + width - 1);
|
||||
|
||||
/* Advance cursor the 'additional' columns while dirty:ing the cells */
|
||||
for (int i = 1; i < width && col < term->cols - 1; i++) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue