|
From: Patrick E. <pa...@pa...> - 2004-04-02 15:32:07
|
On Friday 02 April 2004 00:49, Joakim Verona wrote:
> Yes, this seems very nice!
>
> How would the Attach function work in this case?
> It would be neat if we could attach an array of values.
Is there much of an advantage to attaching an array? In the case of
my example, you could just stick the attach line in the example and
assign it to a particular array index. Are there cases where you
wouldn't loop to add the extra widgets? Or when the loop index
probably wouldn't be numeric or sequentially numeric?
Patrick
> >jppResourceDialog dialog("myDialog", parentWin);
> >for x in ["one", "two", "three"] {
> > jppResoucePanel panel("myPanel");
> > wxLabel *label = (wxLabel *) panel.FindWindowByName("myLabel");
> > if(!label) cout << "You crazy!";
> > label.SetText(x);
> > dialog.AddToSizer("mySizer", panel);
> >}
|