daisy
daisy

Reputation: 23511

How to create progress bar like in the following picture?

This came from Qt SDK setup wizard , seems that QProgressBar only support accumulative bars , how did they made the following ? is that included in the open-source edition of Qt ?

enter image description here

Upvotes: 0

Views: 1879

Answers (2)

Kamil Klimek
Kamil Klimek

Reputation: 13130

It's simpler then you think... You just need to setRange(0, 0) on QProgressBar. Note that it won't behave exactly like that on all platforms.

With Mac OS X style it will look like this:

enter image description here

Blue stripes will move to the right

On windows it will look like this (with Vista/7 style):

enter image description here

Green indicator will appear from left to the right. It will take only part of progress bar of course.

Upvotes: 3

Dmitry
Dmitry

Reputation: 1156

Is blue box enlarge or static ? It can be QProgressBar on top of another control with animation. If it static, it could just animate Image without any QProgressBar.

Upvotes: 0

Related Questions