PDA

View Full Version : Adding more tab widgets



rakkar
10th September 2009, 18:44
Is there a way to instance a template for the contents of a tab, for a QTabWidget? What I mean is that in QT designer I setup one page of the tab widget with a lot of widgets in it. Then in C++, when the user presses a button, I'd like to add a new tab which has all the same widgets as the first page.

If not, I'll make a new .ui file with just the contents of the tab, and attach that widget each time I add a new tab.

Boron
10th September 2009, 19:03
What you wrote in the last sentence is exactly what I would do.

franz
10th September 2009, 21:22
I think you can tell designer to add an extra tab to the tab widget.

In any case in C++ you can just define a new widget and add it to the tab widget.