From 746ade831abf70d03376041588365a0813d8b60a Mon Sep 17 00:00:00 2001 From: Jelle van der Waa Date: Thu, 28 Apr 2016 20:37:13 +0200 Subject: [PATCH] Add support to set the foreground cursor color VTE 0.44.1 supports setting the foregorund color of the cursor using vte_terminal_set_color_cursor_foreground Closes: #284 --- config | 1 + termite.cc | 3 +++ 2 files changed, 4 insertions(+) diff --git a/config b/config index 27db86f..c794a35 100644 --- a/config +++ b/config @@ -33,6 +33,7 @@ filter_unmatched_urls = true [colors] #cursor = #dcdccc +#cursor_foreground = #dcdccc foreground = #dcdccc foreground_bold = #ffffff background = #3f3f3f diff --git a/termite.cc b/termite.cc index 8807020..7cdf8c9 100644 --- a/termite.cc +++ b/termite.cc @@ -1296,6 +1296,9 @@ static void load_theme(GtkWindow *window, VteTerminal *vte, GKeyFile *config, hi if (auto color = get_config_color(config, "colors", "cursor")) { vte_terminal_set_color_cursor(vte, &*color); } + if (auto color = get_config_color(config, "colors", "cursor_foreground")) { + vte_terminal_set_color_cursor_foreground(vte, &*color); + } if (auto color = get_config_color(config, "colors", "highlight")) { vte_terminal_set_color_highlight(vte, &*color); }