How come, in the example below, the label widget always is on top of its parent widget when running on XP? On Linux, however, the two widgets are completely independent.
The reason why I set up thing as I do, is that I want the child widget to be closed automatically when the parent widget is closed.
#include <QApplication>
#include <QLabel>
int main(int argc, char *argv[])
{
widget->show();
label->show();
return app.exec();
}
int main(int argc, char *argv[])
{
QApplication app(argc, argv);
QWidget *widget = new QWidget;
widget->show();
QLabel *label = new QLabel("Label", widget, Qt::Window);
label->show();
return app.exec();
}
To copy to clipboard, switch view to plain text mode
Bookmarks