diff options
author | Owen Taylor <otaylor@gtk.org> | 1998-12-07 06:37:27 +0000 |
---|---|---|
committer | Owen Taylor <otaylor@src.gnome.org> | 1998-12-07 06:37:27 +0000 |
commit | 621beb8aaf93c8cfe234723d7001e114ac5a8345 (patch) | |
tree | 40c4267ff9db1dbbe02c70bb1dee962c2e8a20a8 /gtk/gtkwindow.h | |
parent | fd7bdf03e002ecd5686ecab534b6254d83ea20ba (diff) | |
download | gtk+-621beb8aaf93c8cfe234723d7001e114ac5a8345.tar.gz |
New functions gtk_window_set_transient_for() - set up a "transient for"
Mon Dec 7 01:29:27 1998 Owen Taylor <otaylor@gtk.org>
* gtk/gtkwindow.c: New functions
gtk_window_set_transient_for() - set up a "transient for" relationship.
gtk_window_set_default_size() - set the initial size of a window
distinct from its minimum size.
gtk_window_set_geometry_hints() - Allow the user to set
minimum, maximum sizes, aspect rations, and gridded geometry,
possibly all with respect to a subwidget of the window.
These interfaces are still a wee bit experimental.
* gdk/gdk.c: Added gdk_window_set_transient_for(),
gdk_window_set_geometry_hints(), and gdk_window_set_role().
* gdk/gdktypes.h: Added new types for find-grained specification
of WM hints.
* gtk/testgtk.c: Various changes to tests to test the
above new functions.
* gtk/gtkfontsel.c: Squash a few 'const' warnings.
* gtk/gtktogglebutton.c (gtk_toggle_button_realize): Restored
call to gtk_style_set_background() to prevent egregious
flashing to black.
Diffstat (limited to 'gtk/gtkwindow.h')
-rw-r--r-- | gtk/gtkwindow.h | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/gtk/gtkwindow.h b/gtk/gtkwindow.h index 0b78adb8c7..fd307fae34 100644 --- a/gtk/gtkwindow.h +++ b/gtk/gtkwindow.h @@ -52,6 +52,7 @@ struct _GtkWindow GtkWidget *focus_widget; GtkWidget *default_widget; + GtkWindow *transient_parent; gushort resize_count; guint allow_shrink : 1; @@ -59,6 +60,13 @@ struct _GtkWindow guint auto_shrink : 1; guint handling_resize : 1; guint position : 2; + + /* The following flag is initially TRUE when a window is mapped. + * and will be set to FALSE after it is first positioned. + * It is also temporarily reset when the window's size changes. + * + * When TRUE, we move the window to the position the app set. + */ guint use_uposition : 1; guint modal : 1; }; @@ -96,6 +104,20 @@ void gtk_window_set_position (GtkWindow *window, gint gtk_window_activate_focus (GtkWindow *window); gint gtk_window_activate_default (GtkWindow *window); +void gtk_window_set_transient_for (GtkWindow *window, + GtkWindow *parent); +void gtk_window_set_geometry_hints (GtkWindow *window, + GtkWidget *geometry_widget, + GdkGeometry *geometry, + GdkWindowHints geom_mask); +/* The following differs from gtk_widget_set_usize, in that + * gtk_widget_set_usize() overrides the requisition, so sets a minimum + * size, while this only sets the size requested from the WM. + */ +void gtk_window_set_default_size (GtkWindow *window, + gint width, + gint height); + /* If window is set modal, input will be grabbed when show and released when hide */ void gtk_window_set_modal (GtkWindow *window, gboolean modal); |