From 01849297ef39a9e8f4af59dffc9d4138ed02fcd4 Mon Sep 17 00:00:00 2001 From: jagannatharjun Date: Sat, 15 Aug 2020 01:04:05 +0530 Subject: [PATCH] Fix incorrect foreground for read articles with custom theme --- src/gui/rss/articlelistwidget.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/gui/rss/articlelistwidget.cpp b/src/gui/rss/articlelistwidget.cpp index b094fb0d2..87d570814 100644 --- a/src/gui/rss/articlelistwidget.cpp +++ b/src/gui/rss/articlelistwidget.cpp @@ -98,7 +98,9 @@ void ArticleListWidget::handleArticleRead(RSS::Article *rssArticle) auto item = mapRSSArticle(rssArticle); if (!item) return; - item->setData(Qt::ForegroundRole, QPalette().color(QPalette::Inactive, QPalette::WindowText)); + const QColor defaultColor {palette().color(QPalette::Inactive, QPalette::WindowText)}; + const QBrush foregroundBrush {UIThemeManager::instance()->getColor("RSS.ReadArticle", defaultColor)}; + item->setData(Qt::ForegroundRole, foregroundBrush); item->setData(Qt::DecorationRole, UIThemeManager::instance()->getIcon(QLatin1String("sphere"))); checkInvariant();