摘要: PyQt5使用QMessageBox,可以设置在几秒后关闭 (作者使用的python3) info_box = QMessageBox() # 因为没使用这种方式 QMessageBox.information(self, '复制', '复制成功', QMessageBox.Yes) 写弹出框, # 阅读全文
posted @ 2020-11-19 17:49 Lipx9527 阅读(2826) 评论(0) 推荐(0)
摘要: PyQt5支持自定义设置窗口图标 1. 窗口左上角图标(主窗口、或者QMessageBox等) .setWindowIcon(QIcon(pic_path)) 2. QMessageBox窗口中间的图标 .setIconPixmap(QPixmap(pic_path)) pic_path为图片的路径 阅读全文
posted @ 2020-11-19 17:36 Lipx9527 阅读(2866) 评论(0) 推荐(0)
摘要: PyQt5支持css设置样式,使用.setStyleSheet()方法。 比如为主窗口的一些部件设置一些通用样式 self.setStyleSheet( 'QPushButton{font-weight: bold; background: skyblue; border-radius: 14px; 阅读全文
posted @ 2020-11-19 17:24 Lipx9527 阅读(3649) 评论(0) 推荐(0)