I have a QTabWidget
and I want to add/remove/rename individual tabs. Some sources claim that you can double click it to get a tab editor. When I double click it, I get the "Object name" popup:
I need a similar editor like the one used for comboboxes:
I also tried to edit tab properties by right-clicking it in object tree. The menu is pretty stripped of any useful options:
How to manage tabs? Is it possible without XML editor? If yes how do I
You can insert tab by int QTabWidget::insertTab ( int index, QWidget * page, const QIcon & icon, const QString & label ) which inserts a tab with the given label, page, and icon into the tab widget at the specified index : ui->tabWidget->insertTab(1,new myTabClass(),QIcon(QString(":/SomeIcon.
To enter tab order editing mode, open the Edit menu and select Edit Tab Order. In this mode, each input widget in the form is shown with a number indicating its position in the tab order.
In the creator right click the tab name and you can delete them.
Just to make it more clear...
From QTabWidget
context menu → InsertPage:
Select the tab to rename by clicking on it. Then edit QTabWidget property currentTabText
in the property editor:
Select the tab you want to delete. From QTabWidget
context menu → Page X of Y → delete:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With