Stan wrote:
> Quoth the prophet:
> 
>   If type() is FL_HORIZONTAL all the children are resized to the
>   height of the Fl_Pack, and are moved next to each other horizontally.
>   If type() is not FL_HORIZONTAL  then the children are resized to the
>   width and are stacked below each other. Then the Fl_Pack resizes
>   itself to surround the child widgets.
> 
> I don't get the phrase "Then the Fl_Pack resizes itself ..."
> When?

        I'd read it as when anything is changed; ie. new widgets added
        or if type() is changed.

        I believe this means as items are added on, the widget
        enlarges itself to accommodate the added items. (as opposed
        to squishing them, clipping them, or popping up a scroll bar).

> Does the "Fl_Pack resizes itself" literally mean its w() and/or
> h() changes?  If so, I haven't been able to detect that in code.

        If you look at Fl_Pack.cxx::draw(), it does actually call
        resize() on itself after calculating the new width/heights.

        I guess it does this in the draw() code, so that it gets
        triggered automatically whenever widgets are added/removed.
_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk

Reply via email to