python - Combine multiple QMainWindow into one as tabs in QTabWidget -
so, project had been divided multiple portions each working independently. me , group members worked on individual portions , want combine of them single qmainwindow. have menu items in each qmainwindow makes jumping 1 part possible.. (by closing current window , launching within same qapplication)
but want more elegantly, using qtabwidget, each part have own tab. how achieve this? (btw, i'm using qt designer designing ui)
what i've done:
-make new window, add qtabwidget, drag , drop widgets previous qmainwindow separate tabs.
this works design perspective.
don't know how combine code. in separate classes inherited qmainwindow.
is there no way manually add associated slots , functions new mainwindow?
as each portion qmainwindow, each qmainwindow put in tabwidget.
suppose portion_one_qmainwindow derives qmainwindow. use working code, similar following 1 :
qtabwidget *tabmaster = new qtabwidget; portion_one_qmainwindow *portion_one = new portion_one_mainwindow; tabmaster.addtab(portion_one, qicon("images/portion_one.png"), "name_of_portion_one" ); the big effort retrieve code portions common place in order build "master launcher".
Comments
Post a Comment