Visibility of X11 windows

Does anyone know if it is possible to check whether a window in x11 (using xlib) is visible or not? I tried XGetWindowProperty, but that doesn't work, because the windows host (dtwm on Solaris 10) does not support EWMH.

What do you mean by visible?

I can't find my X11 reference books right now, but I'd think you might be able to check WM_STATE, and/or see if the window is actually mapped.

Yeah, I am trying to find out if a (particular) window is visible and ready to receive input. I tried all sorts of routines, (XListProperties, XGetWindowProperty, XGetWindowAttributes) but all of them return that he window is visible, whether that is true or not. Also tried xprod -name, -id, but those return the same information whatever the state of the window.
Again, I am using DTWM as sole window manager, and that might just be the problem. On my Gnome desktop, I get the correct information.

Well, to get input it'd have to be the active window, right?

Can you query the root window for _NET_ACTIVE_WINDOW?

Just curious as to why are you using DTWM? DTWM was part of CDE which was a early-1990s windowing manager.

No, I cannot query _NET_ACTIVE_WINDOW. Properties are not set. Yes, I am using DTWM. Guess that's the source of my problems. :slight_smile:

---------- Post updated at 04:26 AM ---------- Previous update was at 02:35 AM ----------

I am using DTWM because it is legacy, that's it. Not supposed to touch anything that works. (???) Also, it uses TeleUSE. Don't know if I will compromise that, when installing another WM.