--- rxvt-unicode/src/command.C 2006/02/20 19:42:55 1.308 +++ rxvt-unicode/src/command.C 2006/12/07 20:59:59 1.316 @@ -1,4 +1,4 @@ -/*--------------------------------*-C-*---------------------------------* +/*----------------------------------------------------------------------* * File: command.C *----------------------------------------------------------------------* * @@ -1460,11 +1460,13 @@ break; case FocusIn: - focus_in (); + if (ev.xfocus.detail != NotifyInferior && ev.xfocus.detail != NotifyPointer) + focus_in (); break; case FocusOut: - focus_out (); + if (ev.xfocus.detail != NotifyInferior && ev.xfocus.detail != NotifyPointer) + focus_out (); break; case ConfigureNotify: @@ -1777,12 +1779,30 @@ } } -#if TRANSPARENT +void +rxvt_term::update_fade_color (unsigned int idx) +{ +#if OFF_FOCUS_FADING + if (rs[Rs_fade]) + { + rgba c; + pix_colors [Color_fade].get (c); + pix_colors_focused [idx].fade (this, atoi (rs[Rs_fade]), pix_colors_unfocused [idx], c); + } +#endif +} + +#if TRANSPARENT || ENABLE_PERL void rxvt_term::rootwin_cb (XEvent &ev) { make_current (); + if (SHOULD_INVOKE (HOOK_ROOT_EVENT) + && HOOK_INVOKE ((this, HOOK_ROOT_EVENT, DT_XEVENT, &ev, DT_END))) + return; + +# if TRANSPARENT switch (ev.type) { case PropertyNotify: @@ -1800,6 +1820,7 @@ want_refresh = want_full_refresh = 1; break; } +# endif } #endif @@ -2767,6 +2788,7 @@ else { flag = true; + //TODO: due to popular request, implement "skipscroll" option here scr_refresh (); want_refresh = 1; } @@ -3656,6 +3678,8 @@ } else if (ch == C0_BEL || ch == CHAR_ST) break; + else if (ch == C0_SYN) + ch = cmd_get8 (); else if (ch < 0x20) return NULL; /* other control character - exit */ @@ -3665,10 +3689,7 @@ // stop at some sane length return NULL; - if (ch == C0_SYN) - string[n++] = cmd_get8 (); - else - string[n++] = ch; + string[n++] = ch; } string[n++] = '\0'; @@ -3757,6 +3778,10 @@ dLocal (Display *, dpy); assert (str != NULL); + + if (HOOK_INVOKE ((this, HOOK_OSC_SEQ, DT_INT, op, DT_STR, str, DT_END))) + return; + switch (op) { case XTerm_name: @@ -3983,7 +4008,7 @@ #if ENABLE_PERL case URxvt_perl: - if (HOOK_INVOKE ((this, HOOK_OSC_SEQ, DT_STR, str, DT_END))) + if (HOOK_INVOKE ((this, HOOK_OSC_SEQ_PERL, DT_STR, str, DT_END))) ; // no responses yet break; #endif