Checkable QToolButton only seems pressed on hover
General and Desktop
1
Posts
1
Posters
1.5k
Views
1
Watching
-
This may be pretty basic so apologies first!
I created a QToolButton and made it checkable. I assigned an icon to it. I expected to get it to look "pressed" when I check it. However it only looks pressed (checked) when I hover the mouse on top of it.
Here is the code.
@/* Skip the member definition and setting it to the layout where it is displayed */@
@btnPause = new QToolButton;@
@QIcon pauseIcon;@
@pauseIcon.addFile(QString::fromUtf8(":/Pause.png"), QSize(), QIcon::Normal, QIcon::On);@
@btnPause->setCheckable(true);@
@btnPause->setIcon(pauseIcon);@Am I missing something?