Background in QTableWidget
General and Desktop
5
Posts
3
Posters
1.4k
Views
1
Watching
-
Hi and welcome to DevNet!
I think this can be done via QPalette/QPixmap:
@ QTableWidget* table = new QTableWidget;QPalette palette = table->palette(); QPixmap jpgImage( "board.jpg"); palette.setBrush(QPalette::Base, QBrush(jpgImage)); table->setPalette(palette);@Try it, I didn't test it..
-
Hi and welcome to devnet,
[quote author="Binary91" date="1417095175"]Hi and welcome to DevNet!
@QPixmap jpgImage( "board.jpg");@
[/quote]This is a relative path so the file must be in the same folder as the executable.
On a related note, since you are using Qt, you should use the *nix forward slash notation, it will avoid many problem with paths