[SOLVED]QRadioButton Style Sheet Issue
-
I want QRadioButton indicator to be of black color when checked and of white color when unchecked.
For this, i have used this line of code and set at application level@a.setStyleSheet("QRadiobutton::indicator::checked{background-color:black;} QRadioButton::indicator::unchecked{background-color:white;}");@
Using this, color requirement is fulfilled but the indicator shape is changed to square.
I want QRadioButton indicator to be of round shape. Can anyone tell why this is happening? -
Just play a bit with the stylesheet. Maybe something like this?
@ QRadioButton::indicator::unchecked{ border: 1px solid darkgray; border-radius: 6px; background-color: white; width: 10px; height: 10px; margin-left: 5px;}
QRadioButton::indicator::checked{ border: 1px solid darkgray; border-radius: 6px; background-color: black; width: 10px; height: 10px; margin-left: 5px;}@