What is the exact code to change PushButton background-color onclick in the button's stylesheet in Qt Designer?
-
wrote on 31 Jan 2021, 23:10 last edited by
How to make the PushButton's background-color gets changed onClick and onHover by adding code directly in button's stylesheet in Qt Designer. I spent hours googling but found nothing working. Thank you very much.
-
How to make the PushButton's background-color gets changed onClick and onHover by adding code directly in button's stylesheet in Qt Designer. I spent hours googling but found nothing working. Thank you very much.
wrote on 31 Jan 2021, 23:40 last edited by@I-TECH
This requires writing code to change the stylesheet in a slot. In Designer you can get as far as connecting signals to slots, but you can't write the code of a slot. So as far as I know you cannot do this 100% from Designer alone. -
@I-TECH
This requires writing code to change the stylesheet in a slot. In Designer you can get as far as connecting signals to slots, but you can't write the code of a slot. So as far as I know you cannot do this 100% from Designer alone.
1/3