Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
Stylesheet for QRadioButton
Milica last edited by
I want to add a stylesheet to a QRadiobutton. Want that black dot to be some other color, example red.
But if i try this:
border:1px solid black;
the white space between border and dot disapears.
The black dot is an image so you can't change its color. What you have above has replaced the image with a solid color.
If you want a red dot you need to provide an image with it and use background-image.
Another way is to provide a clever radial gradient that will draw the dot as background, e.g.
background: qradialgradient(cx:0, cy:0, radius: 1, fx:1, fy:1, stop:0.25 red, stop:0.3 white)