Thanks to thuga for helping me.
The solution was to put a Layout into cImageInterface
and then put the QTabWidget
in it.
I've faced a problem by tring to create it in my code, so I've put it in the .ui file.
<layout class="QVBoxLayout" name="appTabLayout">
<property name="sizeConstraint">
<enum>QLayout::SetNoConstraint</enum>
</property>
and then you can :
cImageInterface::cImageInterface() : ui(new Ui::cImageInterface)
{
tabW_Application = new cAppTabWidget(this);
ui->setupUi(this);
ui->appTabLayout->addWidget(tabW_Application);
}