Re: [gtk-list] Two simple questions




On Sun, 16 May 1999, Dave Swegen wrote:
> 
> 1) If I have a dialog window, what is the best way to close it if I click
> on say OK or cancel (Told you they were dumb)?
>

gtk_widget_destroy() should work fine. You could gtk_widget_hide() too but
then you have to destroy it later (sometimes this is convenient).
 
> 2) What is the difference between a GTK_WINDOW_TOPLEVEL window and a
> GTK_WINDOW_DIALOG window? The tutorial is very hazy on the matter (as a
> matter of fact it is hazy in a manner which really irritates me: "We're
> going to tell you there's a difference, but not what the difference is." -
> how very useful).
> 

Gtk will set a hint on a dialog window telling the window manager it's a
dialog; some window managers will treat dialogs differently if they're
configured to do so. It makes no difference from the programmer's point of
view, except that you should use GTK_WINDOW_DIALOG if it's a dialog.

Havoc




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