Re: Closing (and destroying) windows.

> >> I have an application with a number of windows. Each window is retained all
> >> the time, and "shown" via clicking a button. The window is then "hidden" by
> >> clicking a button on that window. All very simply.
> >>
> >> Each Gtk window is created in its own CDE window, which just happens to have
> >> an in-built "close" function. If the user selects this, then the Gtk window
> >> is not just hidden, but destroyed. The upshot of this is that I can not
> >re-show
> >> the window.
> >
> >you can connect to the delete-event on that window, call gtk_widget_hide from
> >the
> >handler and return TRUE. If you don't catch the event or return FALSE from the
> >handler, the widget-destroy signal follows by default, which is not what you
> >want.
> Thanks Carsten for your reply. I have tried it out and it works okay.. BUT
> if the window happens to be iconised, and you try to "close" the icon, the
> window just locks up now. :-(
> Is there a separate event for deleting a window thru its icon, verses being
> open ??

Hmm, good point. Maybe we wait for somebody to explain how to handle iconized
windows (and some terms like mapped/visible, the corresponding signals, etc.). I
am curious myself.
- how to find out if we are minimized?
- how to (de)miniaturize or close icons?


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