pyqt 狀態欄顯示進度條

from PyQt5.QtWidgets import QMainWindow, QApplication, QMessageBox,QStatusBar,QProgressBar,QLabel

        self.statusBar = QStatusBar()
        self.setStatusBar(self.statusBar)
        self.reportlabel = QLabel()
        self.reportlabel.setText('test:')
        self.report_processbar = QProgressBar()
        self.report_processbar.setValue(0)
        self.statusBar.addPermanentWidget(self.reportlabel,stretch=0)
        self.statusBar.addPermanentWidget(self.report_processbar,stretch=1)

 

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章