fix: use DTK standard TextTips color and T7 font for tip label#89
Conversation
There was a problem hiding this comment.
Sorry @F-windy, your pull request is larger than the review limit of 150000 diff characters
|
Hi @F-windy. Thanks for your PR. 😃 |
|
CLA Assistant Lite bot All contributors have signed the CLA ✍️ ✅ |
|
Hi @F-windy. Thanks for your PR. I'm waiting for a linuxdeepin member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
9996c9d to
eb42b09
Compare
|
I have read the CLA Document and I hereby sign the CLA. |
|
recheck |
1 similar comment
|
recheck |
eb42b09 to
3252495
Compare
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: F-windy, lzwind The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
1. Replace hardcoded tip label colors (109,124,136 / 138,161,180) with DPalette::TextTips so the label follows the theme palette 2. Bind the tip label font to DFontSizeManager::T7 for consistent auxiliary tip sizing 3. Apply TextTips color in both light and dark setIcons branches to keep them in sync 4. Add the DPalette include for the new palette usage Log: Use DTK standard TextTips color and T7 font for the tip label so it tracks theme palette changes fix(tiplabel): 使用 DTK 标准 TextTips 颜色与 T7 字号 1. 将提示标签硬编码颜色(109,124,136 / 138,161,180)替换为 DPalette::TextTips,使其随主题调色板统一变化 2. 将提示标签字体绑定到 DFontSizeManager::T7,保证辅助提示字号一致 3. 在 setIcons 的亮色与暗色分支均使用 TextTips 颜色,保持两套主题一致 4. 新增 DPalette 头文件以支持调色板取色 Log: 使用 DTK 标准 TextTips 颜色与 T7 字号,让提示文字随主题调色板统一刷新 PMS: BUG-368759
3252495 to
15096d2
Compare
deepin pr auto review★ 总体评分:100分■ 【总体评价】
■ 【详细分析】
■ 【改进建议代码示例】 // 当前代码已足够优秀,无需额外改进,以下为当前最佳实践展示
void MainWidget::setupUi(QWidget *Widget)
{
// ... 其他初始化代码
m_tiplabel = new DLabel(Widget);
m_tiplabel->setObjectName(QStringLiteral("tiplabel"));
// 提示文字使用 DTK 标准的辅助提示字号与颜色,随主题统一刷新
DFontSizeManager::instance()->bind(m_tiplabel, DFontSizeManager::T7);
{
DPalette dp = DGuiApplicationHelper::instance()->applicationPalette();
QPalette pe;
pe.setColor(QPalette::WindowText, dp.color(DPalette::TextTips));
m_tiplabel->setPalette(pe);
}
// ... 其他布局代码
}
void MainWidget::setIcons(DGuiApplicationHelper::ColorType themeType)
{
// ... 其他逻辑
if (m_tiplabel) {
DPalette dp = DGuiApplicationHelper::instance()->applicationPalette();
QPalette pe;
pe.setColor(QPalette::WindowText, dp.color(DPalette::TextTips));
m_tiplabel->setPalette(pe);
}
// ... 其他逻辑
} |
fix(tiplabel): use DTK TextTips color and T7 font
Log: Use DTK standard TextTips color and T7 font for the tip label so it tracks theme palette changes
fix(tiplabel): 使用 DTK 标准 TextTips 颜色与 T7 字号
Log: 使用 DTK 标准 TextTips 颜色与 T7 字号,让提示文字随主题调色板统一刷新
PMS: BUG-368759