Remove selection around text QPushButton
When I add a QPushButton to my form, I get this:
You can see the ugly text selection (into the button). How can I remove it?
Here is my CSS for that button:
enterButton->setStyleSheet("QPushButton { \
padding: 6px; \
background: #369; \
color: white; \
font-size: 13px;\
border: 0; \
border-radius: 3px; \
}\
QPushButton:hover { \
background: #47a; \
}\
QPushButton:pressed { \
background: #58b; \
}");
Thank!
+3
source to share
1 answer
I don't have Ubuntu
one installed right now, but I think it outline: 0px
should work:
enterButton->setStyleSheet("QPushButton { \
padding: 6px; \
background: #369; \
color: white; \
font-size: 13px;\
border: 0; \
border-radius: 3px; \
outline: 0px; \
}\
QPushButton:hover { \
background: #47a; \
}\
QPushButton:pressed { \
background: #58b; \
}");
Try it and come back with feedback.
+5
source to share