Thread: nested tabpanel
View Single Post
  #1  
Old 04-08-2016, 07:12 AM
JudithVerstegen JudithVerstegen is offline
Member
 
Join Date: Apr 2016
Posts: 1
nested tabpanel

Hi,

I am trying to make a tabpanel, in which one of the panels is also a tabpanel, i.e. a nested tabpanel. But something strange happens with the alignment. When I run the code below, at first the panels are aligned on the lower right of the main panel. Only once I have clicked each one of them, they shift towards the upper left. I want them aligned upper left from the start. I am using Vizard 5.3 64-bit.


Code:
import viz
import vizdlg

viz.go()

menu = vizdlg.TabPanel()
submenu = vizdlg.TabPanel()
for aTabNr in range(1,5):
    panel = viz.addTexQuad(size=150)
    submenu.addPanel(str(aTabNr), panel, align=vizdlg.ALIGN_LEFT_TOP)

menu.addPanel('subMenu', submenu, align=vizdlg.ALIGN_LEFT_TOP)
viz.link(viz.RightTop, menu, offset=(-300,-50,0))
Reply With Quote