Add a new widget in QGridLayout - Backgroud not displayed
I have a QWidget with a QGridLayout containing two others widget. When I dynamically add a new widget to the grid and want to show it, it shows the new widget but not its background. None of its parents widget have a background css style. How can I resolv this so my new background widget is shown ?
What background should there be ?
an image set in the css with qt designerw. I have basically two designer class : News and Everwyhere Window, and the code below :
GUI::EverywhereWindow::EverywhereWindow(QWidget *parent) :
GUI::News *news = new GUI::News(this); ui->gridLayout->addWidget(news, 2, 0); ui->globalWidget->hide();
Are you sure the image is found at run time ?