QProgressBar not showing progress?

后端 未结 3 626
耶瑟儿~
耶瑟儿~ 2020-12-01 22:07

My first naive at updating my progress bar was to include the following lines in my loop which is doing the processing, making something like this:

while(dat         


        
3条回答
  •  长情又很酷
    2020-12-01 22:32

    You can create a sub-class of QThread that emits a signal progressChanged, which you connect to the QProgressBar.

    connect() makes the connections auto connections per default. That means that the signal-slot-mechanism already takes care of the threading issues for you, so you don't need to worry about that.

提交回复
热议问题