Re: Geometry mystery
- From: Owen Taylor <otaylor redhat com>
- To: Mark Leisher <mleisher crl nmsu edu>
- Cc: gtk-list gnome org
- Subject: Re: Geometry mystery
- Date: 09 Aug 2000 18:35:20 -0400
Mark Leisher <mleisher@crl.nmsu.edu> writes:
> I have three widgets in a vbox. The one on the bottom resizes itself
> occasionally, the top two always stay the same size. The problem I'm having
> is that this last widget changes to the requested size, but the vbox does not.
> I am using gtk_widget_size_allocate() to do the size change within this last
> widget. What did I forget?
That you should never call gtk_widget_size_allocate()? (Unless you
are implementing a container widget.)
An application, to change the size of a widget like a drawing
area would typically call gtk_widget_set_usize().
A widget, to change its own size, would call gtk_widget_queue_resize()
on itself, and then when the resize happened, respond to
::size_request with the new desired size.
Regards,
Owen
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]