[Interest] QProgressBar::reset... when it doesn't

Matthew Woehlke mw_triad at users.sourceforge.net
Tue May 19 19:38:29 CEST 2015


I have a progress bar used to show that some task is executing. Some
times I know how its actual progress, and sometimes I don't. When the
task is done, I call QProgressBar::reset().

This is fine if I know the actual progress (value range is non-empty).
When I don't (value range = [0, 0]), reset() doesn't work.

The "problem" is that QProgressBar having an empty range, to show the
"I'm busy but can't show you meaningful progress", trumps the progress
bar being reset. Now, I can fix that by also setting a non-empty range,
but this feels like a bug.

This is with Qt 4.8.6. As I don't have an easy way to check, does anyone
know if it has been fixed in Qt 5.x? Does this feel like a bug that
should be reported? (I didn't find any existing reports for this issue,
at least nothing that mentioned both "QProgressBar" and "reset".)

-- 
Matthew




More information about the Interest mailing list