[709] in The GTK GIMP ToolKit mailing list archive

home help back first fref pref prev next nref lref last post

[gtk-list] Re: GTK_SHRINK in GtkTable

daemon@ATHENA.MIT.EDU (Owen Taylor)
Sun Aug 10 12:23:02 1997

To: gtk-list@redhat.com
From: Owen Taylor <owt1@cornell.edu>
Date: 10 Aug 1997 12:24:28 -0400
In-Reply-To: mcrichto@cord.iupui.edu's message of Sat, 9 Aug 1997 00:11:27 -0500 (EST)
Resent-From: gtk-list@redhat.com
Reply-To: gtk-list@redhat.com


mcrichto@cord.iupui.edu writes:

> Well, I'm finally breaking down and asking for help on this one.  After
> pouring through the docs and src, and playing with some test programs, I
> cannot figure out what the GTK_SHRINK attribute does to a widget being
> attached to a table.

If a table widget was allocated _less_ space than it requested. (For
instance, because the user has resized the window to a smaller size),
then the deficit is equally divided among all rows (columns) where all
the child widgets are specified as GTK_SHRINK.

A practical instance is with a GtkPaned widget, where one of the
halves of the paned widget is a table of a text area and scrollbars

      +-------------------------+
      |                         |
      | 			|
      +-----------------------*-+
      |                       | |
      |                       | |
      |         A             |B|
      |                       | |
      |                       | |
      +-----------------------+-+
      |		C             | |
      +-----------------------+-+


If the user shrinks the bottom half of the paned widget. (By dragging
on the *), A and B should shrink vertically, but not C. So GTK_SHRINK
needs to be specified for A and B. (If GTK_SHRINK is specifed for nothing,
the table just gets pushed of the bottom of the window)

Regards,
                                        Owen

--
To unsubscribe: mail -s unsubscribe gtk-list-request@redhat.com < /dev/null


home help back first fref pref prev next nref lref last post