qpushbutton 按下状态 ,图片更改
当工具栏的按钮被按下,图标保持不变,需要怎么做?
下面是qss,另外需要设置按钮 checkable 为true
QPushButton#btnZHGL { border-radius:10px; font-size:28px; font-family:Microsoft YaHei; font-weight:400; color:rgba(205,242,255,1); border-image:url(skin/image/ui/bg_btn_top_normal.png); } QPushButton#btnZHGL:hover { font-family:Microsoft YaHei; border-image:url(skin/image/ui/bg_btn_top_hover.png); } QPushButton#btnZHGL:pressed, QPushButton#btnZHGL:checked { font-family:Microsoft YaHei; border-image:url(skin/image/ui/bg_btn_top_pressed.png); }