Closed theodox closed 8 years ago
Current version now uses the key value of the children to auto populate labels when the tablayout context closes
with TabLayout('tabs'): with FormLayout('hello'):
with FormLayout("world"):
#etc
produces two tabs named 'hello' and 'world'
Maya's default tabLayout management is pretty nasty: like formLayout it involves a lot of retrospective editing
What's the right way to clean it up?
right now you could do with TabLayout("fred") as tabs: with FormLayout("xxx") as tab1: Button("example") with FormLayout("yyy") as tab2: Button("example") tabs.tabLabels = ((tab1, "XXX"), (tab2, "YYY"))
but it would be nice if you did not have to. Could we:
add a setname function:
with TabLayout("fred") as tabs: with FormLayout("xxx") as tab1: Button("example") tabs.setname(tab1, "xxx")
other ideass?