QProgressBar *b = new QProgressBar();
QString progressStyle = QString("::chunk {"
"background-color: "
"qlineargradient(x0: 0, x2: 1, "
"stop: 0 green, stop: 0.6 green, "
"stop: 0.6 orange, stop: 0.8 orange, "
"stop: 0.8 transparent, stop: 1 transparent"
")}");
b->setStyleSheet(progressStyle);
b->setValue(80);
b->show();
I'm trying to use solid colors, each color separated from the other, but my code results in gradient colors.
Here's how it looks:
How can I avoid this gradient effect, and achieve the solid colors I need?