On 12.04.2013 10:46, MacArthur, Ian (Selex ES, UK) wrote:

>> 2. This program still uses Fl_Pack. I had originally tried Fl_Pack to
>> see what it would do. When changed over to Fl_Group, buttons lower in
>> the window don't respond properly. It seems like the clicked button and
>> above are the only responding buttons. I quit playing with Fl_Group
>> since I couldn't remedy the unpredictable buttons.
>
> Sounds like you have put the buttons outside the bounding box of the group, 
> so they don't get any key clicks.
>
> You need to ensure the parent group is sized to properly contain its 
> children, or Bad Things can happen.

That's exactly what I had thought when reading this.

To Marty: please try again with Fl_Group, because Fl_Pack won't do
what you want, unless you use Fl::add_timeout() for the popup.

Besides looking at the correct bounding box issue, you must only
calculate the new button coordinates after changing children inside
the group. Only if you want predictable resizing behavior, then you
must also call init_sizes() after rearranging children. That should
really be easy to implement...

Albrecht

_______________________________________________
fltk mailing list
fltk@easysw.com
http://lists.easysw.com/mailman/listinfo/fltk

Reply via email to