]> Pileus Git - ~andy/gtk/blobdiff - docs/reference/gtk/tmpl/gtkwindow.sgml
Make 3.0 parallel-installable to 2.x
[~andy/gtk] / docs / reference / gtk / tmpl / gtkwindow.sgml
index 29d87969bdebe332d5231323c6827e3838bcf728..07c39b05b85dda08833a471b1a45a64278406974 100644 (file)
@@ -8,6 +8,29 @@ Toplevel which can contain other widgets
 <para>
 
 </para>
+<refsect2 id="GtkWindow-BUILDER-UI">
+<title>GtkWindow as GtkBuildable</title>
+<para>
+The GtkWindow implementation of the GtkBuildable interface supports a 
+custom &lt;accel-groups&gt; element, which supports any number of &lt;group&gt;
+elements representing the GtkAccelGroup objects you want to add to your
+window (synonymous with gtk_window_add_accel_group().
+</para>
+<example>
+<title>A UI definition fragment with accel groups</title>
+<programlisting><![CDATA[
+<object class="GtkWindow">
+  <accel-groups>
+    <group name="accelgroup1"/>
+  </accel-groups>
+</object>
+
+...
+
+<object class="GtkAccelGroup" id="accelgroup1"/>
+]]></programlisting>
+</example>
+</refsect2>
 
 <!-- ##### SECTION See_Also ##### -->
 <para>
@@ -17,6 +40,9 @@ Toplevel which can contain other widgets
 <!-- ##### SECTION Stability_Level ##### -->
 
 
+<!-- ##### SECTION Image ##### -->
+
+
 <!-- ##### STRUCT GtkWindow ##### -->
 <para>
 
@@ -131,6 +157,11 @@ Toplevel which can contain other widgets
 
 </para>
 
+<!-- ##### ARG GtkWindow:mnemonics-visible ##### -->
+<para>
+
+</para>
+
 <!-- ##### ARG GtkWindow:modal ##### -->
 <para>
 
@@ -229,86 +260,6 @@ Toplevel which can contain other widgets
 @wmclass_class: 
 
 
-<!-- ##### FUNCTION gtk_window_set_policy ##### -->
-<para>
-Changes how a toplevel window deals with its size request and user resize
-attempts. There are really only two reasonable ways to call this function:
-<orderedlist>
-<listitem>
-<para>
-<literal>gtk_window_set_policy (GTK_WINDOW (window), FALSE, TRUE, FALSE)</literal> 
-means that the window is user-resizable.
-</para>
-</listitem>
-<listitem>
-<para>
-<literal>gtk_window_set_policy (GTK_WINDOW (window), FALSE, FALSE, TRUE)</literal> 
-means that the window's size is program-controlled, and should simply match 
-the current size request of the window's children.
-</para>
-</listitem>
-</orderedlist>
-The first policy is the default, that is, by default windows are designed to 
-be resized by users.
-</para>
-
-<para>
-The basic ugly truth of this function is that it should be simply:
-<literal>
- void gtk_window_set_resizable (GtkWindow* window, gboolean setting);
-</literal>
-...which is why GTK+ 2.0 introduces gtk_window_set_resizable(), which you 
-should use instead of gtk_window_set_policy().
-</para>
-
-<para>
-If set to %TRUE, the @allow_grow parameter allows the user to expand the window
-beyond the size request of its child widgets. If @allow_grow is %TRUE, be sure to
-check that your child widgets work properly as the window is resized.
-</para>
-
-<para>
-A toplevel window will always change size to ensure its child widgets receive
-their requested size. This means that if you add child widgets, the toplevel
-window will expand to contain them. However, normally the toplevel will not
-shrink to fit the size request of its children if it's too large; the
-@auto_shrink parameter causes the window to shrink when child widgets have too
-much space. @auto_shrink is normally used with the second of the two window
-policies mentioned above.  That is, set @auto_shrink to %TRUE if you want the
-window to have a fixed, always-optimal size determined by your program.
-</para>
-
-<para>
-Note that @auto_shrink doesn't do anything if @allow_shrink and @allow_grow are
-both set to %FALSE.
-</para>
-
-<para>
-Neither of the two suggested window policies set the @allow_shrink parameter to
-%TRUE.  If @allow_shrink is %TRUE, the user can shrink the window so that its
-children do not receive their full size request; this is basically a bad thing,
-because most widgets will look wrong if this happens. Furthermore GTK+ has a
-tendency to re-expand the window if size is recalculated for any reason. The
-upshot is that @allow_shrink should always be set to %FALSE.
-</para>
-
-<para>
-Sometimes when you think you want to use @allow_shrink, the real problem is that
-some specific child widget is requesting too much space, so the user can't
-shrink the window sufficiently. Perhaps you are calling gtk_widget_set_size_request()
-on a child widget, and forcing its size request to be too large. Instead of
-setting the child's usize, consider using gtk_window_set_default_size() so that
-the child gets a larger allocation than it requests.
-</para>
-
-@window: the window
-@allow_shrink: whether the user can shrink the window below its size request
-@allow_grow: whether the user can grow the window larger than its size request
-@auto_shrink: whether the window automatically snaps back to its size request 
-              if it's larger
-@Deprecated: Use gtk_window_set_resizable() instead.
-
-
 <!-- ##### FUNCTION gtk_window_set_resizable ##### -->
 <para>
 
@@ -345,13 +296,6 @@ the child gets a larger allocation than it requests.
 @accel_group: 
 
 
-<!-- ##### MACRO gtk_window_position ##### -->
-<para>
-Deprecated alias for gtk_window_set_position().
-</para>
-
-
-
 <!-- ##### FUNCTION gtk_window_activate_focus ##### -->
 <para>
 
@@ -486,6 +430,7 @@ Deprecated alias for gtk_window_set_position().
 
 </para>
 
+@void: 
 @Returns: 
 
 
@@ -558,7 +503,7 @@ Deprecated alias for gtk_window_set_position().
 @focus: 
 
 
-<!-- ##### FUNCTION gtk_window_get_default ##### -->
+<!-- ##### FUNCTION gtk_window_get_default_widget ##### -->
 <para>
 
 </para>
@@ -748,15 +693,6 @@ Deprecated alias for gtk_window_set_position().
 @modifier: 
 
 
-<!-- ##### FUNCTION gtk_window_set_role ##### -->
-<para>
-
-</para>
-
-@window: 
-@role: 
-
-
 <!-- ##### FUNCTION gtk_window_set_type_hint ##### -->
 <para>
 
@@ -852,6 +788,16 @@ Deprecated alias for gtk_window_set_position().
 
 </para>
 
+@void: 
+@Returns: 
+
+
+<!-- ##### FUNCTION gtk_window_get_default_icon_name ##### -->
+<para>
+
+</para>
+
+@void: 
 @Returns: 
 
 
@@ -1050,6 +996,15 @@ Deprecated alias for gtk_window_set_position().
 @Returns: 
 
 
+<!-- ##### FUNCTION gtk_window_get_window_type ##### -->
+<para>
+
+</para>
+
+@window: 
+@Returns: 
+
+
 <!-- ##### FUNCTION gtk_window_move ##### -->
 <para>
 
@@ -1186,3 +1141,21 @@ Deprecated alias for gtk_window_set_position().
 @opacity: 
 
 
+<!-- ##### FUNCTION gtk_window_get_mnemonics_visible ##### -->
+<para>
+
+</para>
+
+@window: 
+@Returns: 
+
+
+<!-- ##### FUNCTION gtk_window_set_mnemonics_visible ##### -->
+<para>
+
+</para>
+
+@window: 
+@setting: 
+
+