From 7be28c6ac6277618dbebd6aa0e5d8cbcd3671ae9 Mon Sep 17 00:00:00 2001 From: F-windy <135823805+F-windy@users.noreply.github.com> Date: Fri, 28 Aug 2026 14:11:47 +0800 Subject: [PATCH] fix(catalog): use default text color for page numbers MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 1. Page number items used textTips() color, a semi-transparent low-contrast hint color 2. The color was cached as a static QBrush at creation and never updated on theme switch 3. Remove setForeground() so page numbers fall back to the view default opaque text color 4. Page numbers now follow the standard content text color and adapt to theme changes Log: Remove textTips() foreground from catalog page numbers Influence: Page numbers now readable in light and dark themes fix(catalog): 目录页码使用默认文本色 1. 目录页码项使用 textTips() 颜色,为半透明低对比度的提示色 2. 该颜色在创建时缓存为静态 QBrush,主题切换后不更新 3. 移除 setForeground() 调用,页码改用视图默认不透明文本色 4. 页码现跟随标准内容文本色,随主题切换自动适配 Log: 移除目录页码的 textTips 前景色设置 PMS: BUG-375491 Influence: 浅色和深色主题下页码均可清晰显示 --- reader/sidebar/CatalogTreeView.cpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/reader/sidebar/CatalogTreeView.cpp b/reader/sidebar/CatalogTreeView.cpp index 9e8c5c6b..b7ac4292 100644 --- a/reader/sidebar/CatalogTreeView.cpp +++ b/reader/sidebar/CatalogTreeView.cpp @@ -178,8 +178,6 @@ QList CatalogTreeView::getItemList(const QString &title, const item1->setData(realleft, Qt::UserRole + 2); item1->setData(realtop, Qt::UserRole + 3); item1->setTextAlignment(Qt::AlignRight | Qt::AlignVCenter); - QColor color = Dtk::Gui::DGuiApplicationHelper::instance()->applicationPalette().textTips().color(); - item1->setForeground(QBrush(color)); qCDebug(appLog) << "CatalogTreeView::getItemList() - Returning item list"; return QList() << item << item1;