Scalable GUI
-
Hello, I create a scalable GUI with vertical, horizontal layouts and set geometry and when I extend the window then the half of GUI disappear. ( when I narrow the window then GUI works good. )
ui->verticalLayout_2->setGeometry(QRect( 0, 0, MainWindow::size().width(), MainWindow::size().height() )); // geometry

-
Looks like the tab widget is not set to expand it's children, or something. You should not need to even call
setGeometry()manually like that. Check out the tab dialog example for proper implementation: https://doc.qt.io/qt-5/qtwidgets-dialogs-tabdialog-example.html -
Hello, I create a scalable GUI with vertical, horizontal layouts and set geometry and when I extend the window then the half of GUI disappear. ( when I narrow the window then GUI works good. )
ui->verticalLayout_2->setGeometry(QRect( 0, 0, MainWindow::size().width(), MainWindow::size().height() )); // geometry

@NintyS put some layout on your main page like either horizontal or vertical accourding to your need. I don't think you should use setGeometry Just adding layout to main widget and applying another layout to tab widget will work
give centralWidget a horizontal layout likeverticalLayout.addWidget(tabWid);