[Xcb] Expose events on focus change

Ulrich Eckhardt doomster at knuut.de
Mon Aug 16 00:21:39 PDT 2010


I just stumbled over something that worries me a bit and where I'm not sure 
whether it is intended or not. I noticed that when I move my mouse or use a 
key combo to switch focus to/from a window it gets "expose" events. This is my 
first issue, why should a window be repainted just because it gained or lost 

Secondly, I noticed that it isn't just one such event but several of them! 
When losing focus, I get two expose events, when gaining focus I get four 
expose events. Note that these numbers already account for the fact that the 
exposure comes in multiple events each exposing one rectangle, otherwise I 
would have several times as many.

 - I'm using the shape extension, haven't tried non-shaped windows yet.
 - I'm using fluxbox, still need to try a different WM.
 - There already is a bug report which sounds related: 

I can actually turn this off by simply announcing to the WM that I don't ever 
want focus (xcb_wm_hints_set_input), but that neither changes Debian bug 
#544112 nor does this give sense to the behavior otherwise.

Can someone clarify whether I'm seeing expected behavior or a bug?


More information about the Xcb mailing list