ProjectWindow: Fix hardcoded color for panel title

Task-number: QTCREATORBUG-8930

Change-Id: I5db64abb91ab6657de811a4238692424026783f8
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
This commit is contained in:
Daniel Teske
2013-03-11 14:11:39 +01:00
parent 665ba57da0
commit 2fddc1ed0a

View File

@@ -188,7 +188,11 @@ void PanelsWidget::addPropertiesPanel(PropertiesPanel *panel)
QLabel *nameLabel = new QLabel(m_root);
nameLabel->setText(panel->displayName());
QPalette palette = nameLabel->palette();
palette.setBrush(QPalette::All, QPalette::Foreground, QColor(0, 0, 0, 110));
for (int i = QPalette::Active; i < QPalette::NColorGroups; ++i ) {
QColor foregroundColor = palette.color(QPalette::ColorGroup(i), QPalette::Foreground);
foregroundColor.setAlpha(110);
palette.setBrush(QPalette::ColorGroup(i), QPalette::Foreground, foregroundColor);
}
nameLabel->setPalette(palette);
nameLabel->setContentsMargins(0, ABOVE_HEADING_MARGIN, 0, 0);
QFont f = nameLabel->font();