Re: Question on Iconify and Deiconify



Indrayana Rustandi <Indrayana Rustandi Sun COM> writes:

Thanks for the reply. I'm a GTK/Xlib newbie, so I hope you don't
mind another question. When the event is generated, I will have the
structs GdkEvent and GtkWidget in the signal handler function (from
the latter I can obtain GdkWindow). With these structs, how exactly
do you check whether window is (un)mapped according to GDK's
client-side state or not? I've browsed through the API doc, but I
still don't have any clue on how to do this. A code snippet should
be sufficient.


For widgets, I think GTK_WIDGET_MAPPED(widget) is accurate; I could be
wrong. It looks like the gdk_window_is_visible() flag returns the
right value for GdkWindow, though I may be missing some subtle aspect
of it. I'd try gdk_window_is_visible() first I guess.a

Presumably you'll be porting to GTK 2 eventually, and then can just
use the built-in window_state_event feature.

Havoc



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]