【Pyqt5】QTextEdit组件,for循环动态添加数据

for i in range(1,5):
    time.sleep(1)
    print("等待{}".format(1))
    QApplication.processEvents() # 动态添加
    self.QTextEdit.append("SSSS")

 



posted @ 2022-01-10 15:26  PythonNew_Mr.Wang  Views(726)  Comments(0)    收藏  举报