On 26 Jun 2009, at 14:25, chandra shekhar wrote:

>> I don't know enough java or gtk to be sure, but I think you are maybe
>> describing the interface idiom provided by fltk::WizardGroup or  
>> possibly
>> by fltk::TabGroup...
>>
>> Check the docs for those, see if they do what you want.
>
> What I want is to switch containers (containing a set of widgets)  
> when user clicks a button for example; the window should be the  
> same though...
>
> I don't think fltk::WizardGroup  or fltk::TabGroup is intended for  
> such a think....

Actually, I think that is pretty much exactly what they do.

That said, it isn't necessary, you can do this with simple groups.

Put your widgets in a group, and ensure that the group has a boxtype  
set (not just a frame and certainly not NO_BOX mode).
Create several such groups all at the same x,y,w,h.

Call show() on one of the groups and hide() on all the others.

Then simply call hide() on the one that is currently shown and show()  
on one of the others.
That pretty much ought to do it.




_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk

Reply via email to