我通过以下代码将QLabel后面的QProgressBar添加到QStatusBar,但QProgressBar内衬了2条小垂直线。 我想知道如何删除2条垂直线?
import sys
from PyQt4.QtGui import *
from PyQt4.QtCore import *
class MainWindow(QMainWindow):
def __init__(self, parent=None):
super(MainWindow, self).__init__(parent)
self.resize(800, 600)
self.lb=QLabel('finding resource ')
self.pb = QProgressBar()
self.pb.setRange(0, 0)
# self.pb.setTextVisible(False)
self.statusBar().addPermanentWidget(self.lb)
self.statusBar().addPermanentWidget(self.pb, 1)
if __name__ == "__main__":
app = QApplication(sys.argv)
ui = MainWindow()
ui.show()
sys.exit(app.exec_())