[SOLVED] QCheckBox background color?
-
wrote on 22 May 2013, 07:34 last edited by
How to change the background color of the box/frame (default white ) in QCheckBox. I tried to use stylesheets by setting the background-color but it changes the label's background color. Am I missing something ?
Thanks,
-
AFAIK that's not possible.
But you can replace the whole checkbox (not it's label) with an image of your choice... -
wrote on 22 May 2013, 11:50 last edited by
Hi Sam!
Look at this "DarkStyle":http://qt-project.org/forums/viewthread/27978/#126305
maybe you can take some useful things. -
wrote on 22 May 2013, 12:00 last edited by
-Thanks qxoz, but there is no specification for changing the background-color of the checkbox. I think I have to change the image as suggested by raven-worx.-
-
ah..it seems it is possible via stylesheet after all:
@
QCheckBox::indicator
{
background-color: #FFFFFF;
}
@It may be possible that you also have to style the border to take the background-color effect.
-
wrote on 24 May 2013, 17:49 last edited by
Yep played with stylesheets thats the only way i got.
Thanks.
4/7