I am making something in QT in C++.
However, when I am using a while(1)
loop in the code, the window never appears. I tried many things, such as adding a QApplication::processEvents();
at the end of the loop, but it doesn't work. There is no window.
How do get the window to appear?
Example code:
MainWindow::MainWindow(QWidget * parent, Qt::WindowFlags flags) : QMainWindow(parent, flags) {
_ui.setupUi(this);
while(1){
}
}
Thanks
See Question&Answers more detail:os