aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsf-exg <sf-exg>2017-07-15 08:16:22 +0000
committersf-exg <sf-exg>2017-07-15 08:16:22 +0000
commit7585f95239df0a63a98a7b20a61974cd778cd706 (patch)
treecdeadf4ef72a7a3fd60c71f5ee7e883b816fae81
parentc6472d758639f57610a3f55f49ee121fbc4eac79 (diff)
downloadrxvt-unicode-7585f95239df0a63a98a7b20a61974cd778cd706.tar
rxvt-unicode-7585f95239df0a63a98a7b20a61974cd778cd706.tar.gz
Account for focus fading when enabling/disabling reverse video.
Patch by Daniel Hahler.
-rw-r--r--src/screen.C8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/screen.C b/src/screen.C
index 115afbf2..f3c6d576 100644
--- a/src/screen.C
+++ b/src/screen.C
@@ -1716,6 +1716,14 @@ rxvt_term::scr_rvideo_mode (bool on) NOTHROW
{
rvideo_state = on;
+#if OFF_FOCUS_FADING
+ if (rs[Rs_fade])
+ {
+ ::swap (pix_colors_focused[Color_fg], pix_colors_focused[Color_bg]);
+ ::swap (pix_colors_unfocused[Color_fg], pix_colors_unfocused[Color_bg]);
+ }
+ else
+#endif
::swap (pix_colors[Color_fg], pix_colors[Color_bg]);
#ifdef HAVE_IMG
if (bg_img == 0)