Repository navigation
feat: add palette dconfig configuration for dtk - #155
18202781743 wants to merge 1 commit into
Conversation
|
Skipping CI for Draft Pull Request. |
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: 18202781743 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 |
Reviewer's guide (collapsed on small PRs)Reviewer's GuideIntroduces dconfig palette metadata for DTK, separating light and dark theme values through subpaths while preserving the existing installation flow. The definitions cover all QPalette and DPalette entries with standardized color encoding and complete metadata. File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
cd80d9c to
b44cb5c
Compare
|
CLA Assistant Lite bot: shuttle slave seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account. |
ec94502 to
c427b78
Compare
feat: 在 dtk preference dconfig 中新增调色板颜色数组 1. Delete org.deepin.dtk.palette.json and org.deepin.dtk.palette.dark.json 2. Add 4 array keys to org.deepin.dtk.preference.json: lightQPalette, darkQPalette, lightDPalette, darkDPalette 3. Each array contains #AARRGGBB color strings ordered by QPalette::ColorRole or DPalette::ColorType enum 4. Reuse existing org.deepin.dtk.preference dconfig instance instead of separate palette schema files 5. Use camelCase naming for config keys 1. 删除 org.deepin.dtk.palette.json 和 org.deepin.dtk.palette.dark.json 2. 在 org.deepin.dtk.preference.json 中新增 4 个数组配置项:lightQPalette、darkQPalette、lightDPalette、darkDPalette 3. 每个数组包含按 QPalette::ColorRole 或 DPalette::ColorType 枚举顺序排列的 #AARRGGBB 颜色字符串 4. 复用已有的 org.deepin.dtk.preference dconfig 实例,不再使用独立的 palette schema 文件 5. 配置项 key 使用小驼峰命名 PMS: DDE-330 Log: 迁移调色板颜色配置到 dconfig,使用数组型配置项替代独立 palette schema 文件,配置项使用小驼峰命名 Influence: 无
c427b78 to
5522080
Compare
deepin pr auto review🤖 AI 代码审查报告📊 总体评价
🔍 详细分析1. 语法逻辑 ✅评价: 优秀 ✅ 通过 潜在问题: 建议: [] 2. 代码质量 ✅评价: 优秀 ✅ 通过 潜在问题: 建议: [] 3. 代码性能 ✅评价: 优秀 ✅ 通过 潜在问题: 建议: [] 4. 代码安全 🔒评价: 优秀 ✅ 通过
安全漏洞详情: 建议: [] 💡 改进建议代码示例// 暂无代码示例本报告由 AI 代码审查工具自动生成 |
|
TAG Bot New tag: 6.7.51 |
背景
将 dtkgui 中硬编码的调色板颜色值迁移到 dconfig 配置,使用 subpath(light/dark)区分亮暗主题。
改动内容
新增 3 个 dsg.config.meta JSON 文件:
configs/org.deepin.dtk.palette.json— base,light 值作默认configs/light/org.deepin.dtk.palette.json— light,与 base 完全相同configs/dark/org.deepin.dtk.palette.json— dark,dark 值共 32 个 key(20 QPalette + 12 DPalette),每个 key 含 8 个必需字段(value / serial / name / name[zh_CN] / description / description[zh_CN] / permissions / visibility)。
所有非空 value 统一使用
#AARRGGBB八位格式(大写)。alpha 值按 C++double→int截断换算(如0.7×255=178→0xB2)。NoType 用空字符串""表示 invalid QColor。所有 key 已去除
qPalette/dPalette前缀,name 字段使用语义化中英文名称。install 规则
无需修改
CMakeLists.txt或debian/libdtkdata.install,现有规则已递归覆盖子目录。验证
关联
Summary by Sourcery
Add dconfig palette metadata to support configurable light and dark DTK color themes.
New Features:
Enhancements: