Skip to content

refactor(theme): 抽离主题系统并实现暗色/多主题与设置中心#51

Merged
EchoFish merged 3 commits into
tate233:mainfrom
coalschef5:pr50-theme
May 29, 2026
Merged

refactor(theme): 抽离主题系统并实现暗色/多主题与设置中心#51
EchoFish merged 3 commits into
tate233:mainfrom
coalschef5:pr50-theme

Conversation

@coalschef5

Copy link
Copy Markdown
Contributor

refactor(theme): 抽离主题系统并实现暗色/多主题与设置中心

内容

  • 新增 theme.py:集中浅色/暗色调色板与 get_theme/available_themes,取代散落在 gui.py 的硬编码 self.colors 字典;
  • gui.py 启动时从 theme.get_theme(config.theme) 加载调色板;
  • 设置对话框新增主题选择项,持久化到 config.jsontheme 字段)。

验收

  • 可在设置中选择浅色/暗色主题并持久化(重启后保持);
  • gui.py 的中央配色不再硬编码,统一来自 theme.py(少量 ttk active-state 阴影仍为局部字面值)。
  • 所有主题包含完整键集;未知主题回退默认。(4 项测试全绿)

类型:refactor | 里程碑:M3 | 工作量:L | 风险:medium

@EchoFish EchoFish merged commit 0fb26e4 into tate233:main May 29, 2026
tate233 pushed a commit that referenced this pull request Jun 2, 2026
refactor(theme): 抽离主题系统并实现暗色/多主题与设置中心
tate233 pushed a commit that referenced this pull request Jun 5, 2026
refactor(theme): 抽离主题系统并实现暗色/多主题与设置中心
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants