auto_shrink in one dimension?



Howdy,

I've just started work with the wonderful world of gtk+, and I've run into
some questions that aren't covered in the existing documentation (or at
least, not that I've been able to find).

I have a window that has a "collapsable" portion that displays extended
status information to the user.  There's a small arrow button that the user
can click on to roll up/roll down this portion of the display.

I use gtk_widget_show/gtk_widget_hide on the enclosing vbox to achieve this
effect.

I want the window to resize automatically in the vertical direction along
with this action.  Setting the auto_shrink policy *almost* gets me what I
want -- but not quite.

I want the window to maintain a fixed width, and only vary in length.

Is there any easy way around this?  I've tried setting the window size
manually myself, using gtk_window_set_default_size and
gtk_widget_set_usize, but these calls will only make the window *bigger* --
and, they appear to override the auto_shrink policy.

Any hints, pointers, or suggestions would be greatly appreciated.

Thanks,

  -- Lars

-- 
Lars Kellogg-Stedman <lars@larsshack.org>



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