aboutsummaryrefslogtreecommitdiff
path: root/osc.c
diff options
context:
space:
mode:
authorDaniel Eklöf <daniel@ekloef.se>2025-05-05 10:43:02 +0000
committerDaniel Eklöf <daniel@ekloef.se>2025-05-05 11:02:32 +0000
commit073b637d4535cd0dfe92ca1ce954b552ae9f1a4a (patch)
tree712ef9e9f37ddbf6a8e32ef468743c95e48b715d /osc.c
parentdoc: foot.ini: fix description of dark/light themes (diff)
render: refactor to allow setting only selection bg or fg
Before this, we only applied custom selection colors, if *both* the selection bg and fg had been set. Since the options are already split up into two separate options, and since it makes sense to at least be able to keep the foreground colors unchanged (i.e. only setting the selection background), let's allow only having one of the selection colors set. Closes #1846
Diffstat (limited to 'osc.c')
-rw-r--r--osc.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/osc.c b/osc.c
index 78f335e1..d59adc5a 100644
--- a/osc.c
+++ b/osc.c
@@ -1480,12 +1480,10 @@ osc_dispatch(struct terminal *term)
case 17:
term->colors.selection_bg = color;
- term->colors.use_custom_selection = true;
break;
case 19:
term->colors.selection_fg = color;
- term->colors.use_custom_selection = true;
break;
}
@@ -1589,13 +1587,11 @@ osc_dispatch(struct terminal *term)
case 117:
LOG_DBG("resetting selection background color");
term->colors.selection_bg = term->conf->colors.selection_bg;
- term->colors.use_custom_selection = term->conf->colors.use_custom.selection;
break;
case 119:
LOG_DBG("resetting selection foreground color");
term->colors.selection_fg = term->conf->colors.selection_fg;
- term->colors.use_custom_selection = term->conf->colors.use_custom.selection;
break;
case 133: