forked from qt-creator/qt-creator
Utils: Improved handling of StyleHelper::baseColor
This change makes sure that the "UI coloring" feature respects the original brightness of the current theme. It prevents dark themes from getting a too light recoloring and vice versa. Extra benefit: this allows to remove much recently introduced code. Change-Id: Ib2c96e7ed172a4cc97520aa4b5d180cc6353c661 Reviewed-by: hjk <hjk@theqtcompany.com>
This commit is contained in:
@@ -272,9 +272,7 @@ void FancyActionBar::paintEvent(QPaintEvent *event)
|
||||
if (creatorTheme()->widgetStyle () == Theme::StyleFlat) {
|
||||
// this paints the background of the bottom portion of the
|
||||
// left tab bar
|
||||
painter.fillRect(event->rect(), StyleHelper::isBaseColorDefault()
|
||||
? creatorTheme()->color(Theme::FancyTabBarBackgroundColor)
|
||||
: StyleHelper::baseColor());
|
||||
painter.fillRect(event->rect(), StyleHelper::baseColor());
|
||||
painter.setPen(creatorTheme()->color(Theme::FancyToolBarSeparatorColor));
|
||||
painter.drawLine(borderRect.topLeft(), borderRect.topRight());
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user