From 6716985d278f60fc36dbbdcc3e7ae88c34bc34c4 Mon Sep 17 00:00:00 2001 From: Sebastien Helleu Date: Tue, 19 Nov 2013 19:58:10 +0100 Subject: [PATCH] core: fix current color/background after reset of color Bug was visible with such colored string in IRC: ^Cc7,5 one ^Cc ^Cc7 two Before the fix, the word "two" had a red background. The "^Cc" should reset both color + background, so now it does not have a background any more. --- src/gui/curses/gui-curses-window.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/gui/curses/gui-curses-window.c b/src/gui/curses/gui-curses-window.c index 2d13cf712..b1bbf0f0b 100644 --- a/src/gui/curses/gui-curses-window.c +++ b/src/gui/curses/gui-curses-window.c @@ -307,6 +307,9 @@ gui_window_reset_style (WINDOW *window, int weechat_color) void gui_window_reset_color (WINDOW *window, int weechat_color) { + gui_window_current_style_fg = gui_color[weechat_color]->foreground; + gui_window_current_style_bg = gui_color[weechat_color]->background; + wattron (window, COLOR_PAIR(gui_color_weechat_get_pair (weechat_color)) | gui_color[weechat_color]->attributes); }