Questions tagged [qprogressbar]

QProgressBar is a Qt class that provides a progress bar, which can be either horizontal or vertical.

The QProgressBar uses steps to show the progress. To use it, the minimum and maximum values should be specified. After that, when the progress bar receives a current step value, it will update itself to show the percentage of steps completed.

If both values are set to 0, the progress bar will turn into a "busy" indicator. An example of this is the following:

QProgressBar * b = new QProgressBar();
b->setMinimum(0);
b->setMaximum(0);
b->show();

Official documentation can be found here.

152 questions
2
votes
1 answer

QtWidgets.QProgressBar.setTextVisible(False) causes lag

I have a QProgressBar that gets updated every second. The percentage text wasn't needed on it, so I added progressBar.setTextVisible(False) when it was created. However, this made it extremely slow to respond and laggy, so that it takes longer than…
noname
  • 342
  • 5
  • 14
2
votes
1 answer

PyQt4: use a QTimer to continually update progress bars

I have a simple dialog with three progress bars that I want to continually update (displaying system resource usage). From reading around the docs, QTimer is the right way to fire a function every x milliseconds (which would update the progress…
Spencer
  • 1,931
  • 1
  • 21
  • 44
2
votes
2 answers

How to change color of default style for progressbar in Qt

How I can change green tint in default QProgressbar style, without changing other default gradients and effects (a little noticeable "flow white chunk" effect): Default QProgressbar style . I was tried to set new combination of background colors…
jola
  • 23
  • 1
  • 5
2
votes
0 answers

Is it possible to create many QProgressDialogs objects, that will show progress different long operations?

I have class, that launches tasks in separate thread: class SomeTask : public QObject, QRunnable { Q_OBJECT signals: void updateProgressBar(int, int); public: SomeTask(int, QWidget*); void run(); void runLongOperation(QString) …
Nikolay
  • 21
  • 1
2
votes
2 answers

How to control QProgressBar with Signal

Pushing the button starts 100 rounds cycle. With QLabel.setText() we update self.label from inside of scope of clicked() function. Aside from updating self.label we would like to update the progressbar as well. But since progressbar is a local…
alphanumeric
  • 17,967
  • 64
  • 244
  • 392
2
votes
1 answer

QProgressDialog: How to adjust the width to show the whole progress bar?

I create a QProgressDialog, set a QProgressBar to it. Set the format "Processing section %v of %m. Percentage completed: %p." to the QProgressBar. But the text is cut, not the whole progress bar is displayed on the dialog. How to adjust the width…
ldlchina
  • 927
  • 2
  • 12
  • 31
2
votes
2 answers

How to show QProgressBar smoothly?

I'm learning Pyside QProgressBar on MacOSX. When I use QProgressBar like following, it only indicate 0% or 100%. How to make a QProgressBar smoothly? Is there any way to do this? from PySide.QtGui import QApplication, QProgressBar, QWidget from…
Kei Minagawa
  • 4,395
  • 3
  • 25
  • 43
2
votes
2 answers

Python: QtGui.QProgressBar Color

I'm wondering if there is a way to customize a color of the progress bar (QtGui.QProgressBar). Let's say we would want to make it green when bar reaches 100%. Here is a working example: import sys, time from PyQt4 import QtCore, QtGui class…
alphanumeric
  • 17,967
  • 64
  • 244
  • 392
2
votes
2 answers

How to show "waiting" while files are loaded in a Qt application?

I'm selecting and loading some big Dicom files on my program. The whole loading process takes a long time(depends on the number of files, but the whole process can take more than minutes if the files are many). I want show a "waiting symbol" or…
the_naive
  • 2,936
  • 6
  • 39
  • 68
2
votes
3 answers

How to ensure QProgressDialog is shown in PyQt

Sometimes my QProgressDialog shows, sometimes it doesn't ever show at all (as if processEvents weren't called). Are there any artifacts of the processEvents() command that may cause the QProgressDialog not to show under certain circumstances? My…
ecoe
  • 4,994
  • 7
  • 54
  • 72
2
votes
1 answer

QProgressBar rendering is not good

I have added a qprogressbar to a form in qt designer, and set minimum and maximum value to 0 to show the in-progress state. but when I run the application progress bar is displayed with the shadow mark as shown in this pic... Same thing happens…
Prady
  • 663
  • 3
  • 11
  • 28
2
votes
1 answer

Qt Progressbar Incrementing more than it should

So what I want is just incrementing the progressbar with a timer. But somehow it increments the progressbar more than it should. mainwindow.h : Class MainWindow { //... private slots: //... void update(); private: Ui::MainWindow *ui; …
Davlog
  • 2,162
  • 8
  • 36
  • 60
2
votes
2 answers

Progress bar with differnet text color around the progress front?

How can one obtain the following effect for text in a QProgressBar from Qt? : The ideea is that I must have a brighter color in the left part of the progress bar.
andreihondrari
  • 5,743
  • 5
  • 30
  • 59
2
votes
1 answer

Updtaing a QProgressbar from a different Thread

I have developed my own hybrid stream cipher and for the GUI i am using Qt. Initially i wrote it on a single thread but it being a stream cipher was making GUI dysfunctional when operating on large files. So i shifted the encryption/decryption to a…
Rahul De
  • 393
  • 3
  • 14
1
vote
2 answers

qt trouble overriding paintEvent

I'm subclassing QProgressBar in a custom widget, and I overwrote the paintEvent method with the following code : void myProg::paintEvent(QPaintEvent *pe) { QProgressBar::paintEvent(pe); QRect region = pe->rect(); QPainter *painter = new…
Geo
  • 93,257
  • 117
  • 344
  • 520
1 2
3
10 11