Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
[SOLVED] QCheckBox background color?
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 ?
AFAIK that's not possible.
But you can replace the whole checkbox (not it's label) with an image of your choice...
qxoz last edited by
Look at this "DarkStyle":http://qt-project.org/forums/viewthread/27978/#126305
maybe you can take some useful things.
-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.-
Thanks the image shows the checkbox, but I have no idea about the implementation. I am still searching for a solution.
ah..it seems it is possible via stylesheet after all:
It may be possible that you also have to style the border to take the background-color effect.
Yep played with stylesheets thats the only way i got.