[comp.windows.x] Query Visibity ?

TRANLE@INTELLICORP.COM (Minh Tran-Le) (08/10/89)

Is there any way that I can find out all current Visibity state
of a window without setting the VisibilityChangeMask and keeping
track of all the visibility transitions ?

Thanks, Tran Le.

Arpanet: tranle@IntelliCorp.com
uucp:  ..sun!icmv!mtranle
-------

keith@EXPO.LCS.MIT.EDU (08/10/89)

> Is there any way that I can find out all current Visibity state
> of a window without setting the VisibilityChangeMask and keeping
> track of all the visibility transitions ?

It's actually worse than this; as there is no VisibilityUnmapped state,
you must also track UnmapNotify events.  Unfortunately, UnmapNotify
events are only sent to the window which is actually unmapped; if your
window which wants to track Visibility state is the child of a window
which may be unmapped (i.e. a top-level application window which
might be iconified), you'll need to percolate the UnmapNotify event
down to the child window.  Fortunately, ICCCM demands that the client
window actualy be unmapped when iconifying a window (instead of just
unmapping the frame window), so this will work.

The X Toolkit provides unusable support for tracking visibility state;
it doesn't deal with unmapped windows at all.

In summary:  it's hard.

Keith Packard
MIT X Consortium
keith@expo.lcs.mit.edu