[Qt-interest] QProgressBar with style sheet.

Surya Kiran Gullapalli suryakiran.gullapalli at gmail.com
Fri Apr 24 16:49:11 CEST 2009


Hello all,
I'm using a style sheet which sets up QProgressBar::chunk property with a
particular background color.

When tried to use an indeterminate QProgressBar, I'm not seeing the progress
chunks moving here and there. what I'm seeing is one big chunk of progress
indicator, which occupies 50% of progress bar.
If I remove the chunk property, the Progress bar works as expected.

I've tried using QProgressBar::chunk:indeterminate as well, with no results.

What am i missing here ?

my style sheet looks like this.

QProgressBar {
    border: 1px solid gray;
    background: white;
    padding: 1px;
    text-align: left ;
}

QProgressBar::chunk:horizontal {
    background: qlineargradient(x1: 0, y1: 0.5, x2: 1, y2: 0.5, stop: 0
white, stop: 1 green);
}

QProgressBar::chunk:indeterminate {
    background: qlineargradient(x1: 0, y1: 0.5, x2: 1, y2: 0.5, stop: 0
white, stop: 1 green);
}


Thanks,
Surya
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20090424/bd988073/attachment.html 


More information about the Qt-interest-old mailing list