Hello! I'm having some trouble getting a background image to show up in a QFrame using Qt 4.2.2. Here is a snippit of the code that I have:
ui.frame->setStyleSheet("background-image: url(:/images/menu_background.png);"
"background-repeat: repeat;");
ui.frame->setStyleSheet("background-image: url(:/images/menu_background.png);"
"background-repeat: repeat;");
To copy to clipboard, switch view to plain text mode
The image being referenced is pulled in via a QRC file I have in the project. However, for some reason the image isn't showing up... Is there something I'm doing wrong?
Here's the contents of the QRC file for reference:
<RCC>
<qresource prefix="/" >
<file>images/menu_background.png</file>
</qresource>
</RCC>
<RCC>
<qresource prefix="/" >
<file>images/menu_background.png</file>
</qresource>
</RCC>
To copy to clipboard, switch view to plain text mode
Thanks!
- Clay
Bookmarks