Background-image || Border-image not working
Unsolved
General and Desktop
-
I'm building an application on Qt and I want to give a background image to the application. When I'm programming in my house, this piece of code works but when I
make
it in other place, this background image stops working...this -> mainWindow -> setStyleSheet("QMainWindow { \ border-image: url(:/resources/BackGround.png) 0 0 0 0 stretch stretch; \ }");
Somebody can help me? Thanks BTW.
-
@QSourceCreator
Are you absolutely sure that your built executable image contains the specified resource? You might verify by trying e.g.QPixmap pixmap(":/resources/BackGround.png");
and verifying!pixmap.isNull()
at runtime in your code run on the other machine.