On Oct 8, 2005, at 12:30 AM, Steve Chaplin wrote:
> I share Ted's concern. I think a 'well-behaved child widget' does not
> know anything about its parent (or grandparent). Its added to a
> container widget and expands/shrinks (depending on its resize policy)
> to
> use the space that the container widget gives it. So the container
> widget dictates the size of the child widget, not the other way round.
I'm also concerned about the resizable-children approach, and not just
because it sounds scary. The result is a FigureCanvas widget that is
strongly coupled to its parent widget. This poses a thorny problem for
me because my WxMPL library subclasses FigureCanvasWxAgg and encourages
people to embed that class directly in their own Panels, Frames, and
whatnot.
> If you use the GUI to resize the canvas, you resize the gtk.Window and
> the gtk.Window resizes the canvas. It seems reasonable to use the same
> process to resize from a script - resize the gtk.Window and let the
> Gtk.Window resize the canvas.
I agree that this is a much more reasonable approach, and feel that its
also more robust. This brings me to the point of this email: is this
now the officially blessed way of implementing interactive GUI figure
resizing?
Ken
|