Fixed deprecated method QPalette::{Fore,Back}ground (#2510)
Co-authored-by: pajlada <rasmus.karlsson@pajlada.com>
This commit is contained in:
@@ -11,7 +11,7 @@ static void removeScrollAreaBackground(QScrollArea *scrollArea,
|
|||||||
scrollArea->setFrameStyle(0);
|
scrollArea->setFrameStyle(0);
|
||||||
|
|
||||||
QPalette p;
|
QPalette p;
|
||||||
p.setColor(QPalette::Background, QColor(0, 0, 0, 0));
|
p.setColor(QPalette::Window, QColor(0, 0, 0, 0));
|
||||||
scrollArea->setPalette(p);
|
scrollArea->setPalette(p);
|
||||||
childWidget->setPalette(p);
|
childWidget->setPalette(p);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -327,8 +327,8 @@ void BaseWindow::themeChangedEvent()
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
QPalette palette;
|
QPalette palette;
|
||||||
palette.setColor(QPalette::Background, this->theme->window.background);
|
palette.setColor(QPalette::Window, this->theme->window.background);
|
||||||
palette.setColor(QPalette::Foreground, this->theme->window.text);
|
palette.setColor(QPalette::WindowText, this->theme->window.text);
|
||||||
this->setPalette(palette);
|
this->setPalette(palette);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -886,12 +886,12 @@ void SplitHeader::themeChangedEvent()
|
|||||||
|
|
||||||
if (this->split_->hasFocus())
|
if (this->split_->hasFocus())
|
||||||
{
|
{
|
||||||
palette.setColor(QPalette::Foreground,
|
palette.setColor(QPalette::WindowText,
|
||||||
this->theme->splits.header.focusedText);
|
this->theme->splits.header.focusedText);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
palette.setColor(QPalette::Foreground, this->theme->splits.header.text);
|
palette.setColor(QPalette::WindowText, this->theme->splits.header.text);
|
||||||
}
|
}
|
||||||
this->titleLabel_->setPalette(palette);
|
this->titleLabel_->setPalette(palette);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user