feat: print name in output filename; export panel trim; queue template fix
- Output filename now includes the print: <garment>_<print>.<ext>, e.g. 1_TY030.png (folder grouping unchanged) (§17.12). - Hide the single-export button (export via the queue) and remove the orphaned static export hint label (§17.13). - Fix: selecting a non-fine-tuned queue item now lays the print out per the selected template (apply_current) instead of load_print's centred default; still guarded by _loading_queue_item so it isn't marked 已微调 (§17.14). Docs: PRD 6.6/6.8/9, UI design 7.6/7.7/10/12.4, tasks.md 17.12–17.14. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -117,13 +117,13 @@ def make_safe_output_path(output_dir, garment_path, print_path, output_format="P
|
||||
"""Return an output Path that will not overwrite an existing file.
|
||||
|
||||
Outputs are grouped by print into a subfolder named after the print file:
|
||||
<output_dir>/<print_stem>/<garment_stem>.<ext>
|
||||
<output_dir>/<print_stem>/<garment_stem>_<print_stem>.<ext>
|
||||
If that path exists, appends _1, _2, ... until a free slot is found.
|
||||
(The composer creates the subfolder when saving.)
|
||||
"""
|
||||
ext = ".png" if output_format.upper() == "PNG" else ".jpg"
|
||||
target_dir = Path(output_dir) / Path(print_path).stem
|
||||
stem = Path(garment_path).stem
|
||||
stem = "{}_{}".format(Path(garment_path).stem, Path(print_path).stem)
|
||||
|
||||
candidate = target_dir / (stem + ext)
|
||||
counter = 1
|
||||
|
||||
Reference in New Issue
Block a user