feat: persist template/batch-mode, per-aspect resets, de-dup template actions

§17.1 Preferences persistence:
- Wire the previously-unused config_service; remember and restore the
  last-selected template and last batch mode. main_window loads config,
  distributes initial values, then persists on change (save-on-change).
- template_panel: template_changed signal, select_template,
  current_template_state. queue_panel: set_batch_mode + batch_mode_changed.

§17.2 Independent resets:
- Replace the combined reset and 归零 with per-section 位置/尺寸/旋转 reset
  buttons (quiet ghost styling) that restore only their own aspect to the
  selected template. Size reset changes width/height only, leaving X/Y.

Button de-dup:
- Remove the export panel's 应用为模板 / 重置为模板 — literal duplicates of
  the template panel's 另存为 / 重置为模板. Template actions now live only
  in the template area; the export panel handles output only.

Docs: PRD (6.6/6.9/9/10), architecture (4.12), UI design (7.x/10),
development-rules (6, single-home actions + consistent naming), tasks.md (17).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
2026-06-16 17:01:58 +08:00
co-authored by Claude Opus 4.8
parent 69a6dc892a
commit f767ec2660
11 changed files with 300 additions and 115 deletions
+2
View File
@@ -9,6 +9,8 @@ DEFAULT_CONFIG = {
"output_dir": "", # empty = use app output/ dir
"last_garment_dir": "",
"last_print_dir": "",
"last_template": "", # name of the last-selected template
"last_batch_mode": "full_combo", # BatchMode value of the last-used mode
}
_CONFIG_FILENAME = "app_config.json"