aboutsummaryrefslogtreecommitdiff
path: root/terminal.c
diff options
context:
space:
mode:
authorDaniel Eklöf <daniel@ekloef.se>2021-02-13 11:34:11 +0000
committerDaniel Eklöf <daniel@ekloef.se>2021-02-21 19:14:51 +0000
commit841e5f0e50a65bc4787ba06a642355cf4fb514a5 (patch)
treeae12f59686fc79d005e092e4ae138941ee6f6fb5 /terminal.c
parentgrid: enable rows to have ‘extra’ data associated with them (diff)
terminal: add OSC-8 state tracking to the VT sub-struct
Diffstat (limited to 'terminal.c')
-rw-r--r--terminal.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/terminal.c b/terminal.c
index 17b985a8..28c061ca 100644
--- a/terminal.c
+++ b/terminal.c
@@ -1102,6 +1102,9 @@ term_init(const struct config *conf, struct fdm *fdm, struct reaper *reaper,
.blink = {.fd = -1},
.vt = {
.state = 0, /* STATE_GROUND */
+ .osc8 = {
+ .begin = {-1, -1},
+ },
},
.colors = {
.fg = conf->colors.fg,
@@ -1645,6 +1648,9 @@ term_reset(struct terminal *term, bool hard)
free(term->vt.osc.data);
memset(&term->vt, 0, sizeof(term->vt));
term->vt.state = 0; /* GROUND */
+ term->vt.osc8.begin = (struct coord){-1, -1};
+ free(term->vt.osc8.uri);
+ term->vt.osc8.uri = NULL;
if (term->grid == &term->alt) {
term->grid = &term->normal;