Commit ed63f28f authored by Attila Török's avatar Attila Török
Browse files

Change ProgressBar text color when selected

parent 00c04e8e
......@@ -334,6 +334,10 @@ void ViewDelegate::paintProgressBar(QPainter *painter, const QStyleOptionViewIte
progressBarOption.textVisible = true;
progressBarOption.direction = option.direction;
// ProgressBars have no concept of being selected (AFAIK), so the color of its text has to be changed manually
if (option.state & QStyle::State_Selected)
progressBarOption.palette.setColor(QPalette::Active, QPalette::WindowText, option.palette.highlightedText().color());
QApplication::style()->drawControl(QStyle::CE_ProgressBar, &progressBarOption, painter);
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment