Add a new widget in QGridLayout - Backgroud not displayed
Unsolved
General and Desktop
-
Hi,
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 ?
-
Hi,
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) :
QWidget(parent),
ui(new Ui::EverywhereWindow),
_menuOpen(true)
{
ui->setupUi(this);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 ?