GNOME Bugzilla – Bug 340722
GtkToolbar::max-child-expand style property
Last modified: 2011-02-04 16:10:23 UTC
Attach patch from maemo-gtk adds a "max-child-expand" child property which limits the expanding of expanding tool items. It's pretty useful when there are only a few items that should expand if possible, but should not take all available space, because they would look too distributed then.
Created attachment 64851 [details] [review] Patch implementing the above
So what you want is really an item with a natural size, that is allowed to shrink, no? In any case, this patch doesn't look quite correct to me. For example in the case where there is both a fully-expandable and an expandable-to-a-point item, it looks to me like if the available extra space is more than twice the max-child-expand width, the fully-expandable item will not be assigned all of the remaining space.
Err, i didn't mean to say "child property". The property affects all expanding children, so there can't be a mix of fully-expandable and expandable-to-a-point.
ok, the patch looks good and also makes sense to me. i just think that explicitely defining DEFAULT_MAX_CHILD_EXPAND tends to uneccessarily spread out the property definition, so should be omitted. as i understood, Søren didn't really object aginst the property as a style property, which means the patch can go in now.
Fixed in CVS: 2006-05-16 Michael Natterer <mitch@imendio.com> * gtk/gtktoolbar.c: added "max-child-expand" style property which limits the space taken by expanding tool items. Fixes bug #340722.