这是按钮的代码:
self.pushButton.setFont(font)
self.pushButton.setStyleSheet("background-color: qlineargradient(spread:pad, x1:0.0568182, y1:0.126, x2:0.75, y2:0.227, stop:0.0738636 rgba(0, 255, 0, 255), stop:0.840909 rgba(0, 136, 0, 255));\n")
self.pushButton.setFlat(True)
self.pushButton.setObjectName("pushButton")
虽然我给这个按钮设置了一个背景渐变,但它不起作用。在
这是正常情况下的按钮:
当它被按下时:
好吧。解决了。在
问题是,我使用的是背景色,但是背景:#fff做到了。在
相关问题 更多 >
编程相关推荐