我將在下面的每個選項卡內創建多個選項卡和多個組框。Qt - 如何將多個QGroupBox添加到QTabWidget?
_______ ______
| | |
| Tab1 | Tab2 |
| | ______ | _________________
|
| 組框1
| ------------------------------------
|
|
| 組框2
| ------------------------------------
我該怎麼用QTabWidget和QGroupBox?
編輯
,我在標籤控件使用一組框中的代碼是:
QGroupbox * testGB = new QGroupbox("Group Box 1");
...
// create a test layout and add some widget to it
...
testGB.setLayout(testLayout);
QTabWidget * tab = new QTabWidget this;
tab->addTab(testGB, tr("Tab1"));
但我不知道如何另一組框TAB1
追加到
Somethig [像這樣(http://www.poketcode.com/img/pyqt4/qtoolbox_change_item_position.png)你想要什麼?這裏是[QToolBox文檔](http://doc.qt.io/qt-4.8/qtoolbox.html)。如果沒有,請提供更多信息。 – Skywrath
感謝您的回覆。不,正如我所說的那樣,我想用QTabWidget創建一個選項卡,並將兩個組合框(QGroupbox)添加到它的內容中。 –