> hints->input says whether the window wants input focus.  flags |=
> InputHint says "I've set ->input to something".  After all, it's
> impossible to have ->input unset; it'll always be something.  The hint
> says whether it's something we should pay attention to, or just random
> memory garbage.

Okay, that makes sense.  Thanks for the explanation.

> But, when xvile _changes_ its WM_HINTS after it's running, we were
> just accepting them without doing any adjustment.  So that's what's
> happening; xvile starts up, tells us nothing about focus at all, so we
> decide to force input=1.  But then after we've adopted the window, it
> _reset_ its WM_HINTS, telling us nothing about focus, and so we wound
> up not focusing it.  When you restart ctwm, it's after xvile has
> already reset WM_HINTS, but we go through the whole initial setup that
> DOES the overriding.

Nice analysis.  This also explains why xvile would sometimes
have focus (as indicated by the color of the window frame) when
the window was initially created, but once the mouse had been
moved off, would not regain it when the mouse was moved back on.

Reply via email to