Adding TextBoxes in loop

Hi,

I’d like to add TextBox for each master so I tried this:

i=0    
for m in Font.masters:
        
     self.w["text_"+str(i)] = vanilla.TextBox(...)

But got an error:
TypeError: ‘FloatingWindow’ object does not support item assignment

So how can I dynamically add vanilla controls to the window?

Thanks.

You probably get better answers on the robofab list.

You need to do work with eval() in this case. Take a peek into my Floating Features script.

exec ?

Yeah, sorry, confused it myself: