Skip to content

feat(gallery): batch Process… dialog and more bulk actions in the right-click menus - #96

Merged
IAmJSD merged 1 commit into
mainfrom
t3code/77ad8e6e
Sep 2, 2026
Merged

IAmJSD merged 1 commit into
mainfrom
t3code/77ad8e6e

Conversation

@IAmJSD

@IAmJSD IAmJSD commented Sep 2, 2026

Copy link
Copy Markdown
Member

Summary

  • The gallery's photo and bucket right-click menus' Upscale ×2 row becomes Process…, a batch dialog that runs one recipe over the selection or a whole bucket: a turn (rotate 90°/180°, flips), a neural ×2 upscale (the two built-in waifu2x models), and any number of colour adjustments (Brightness/Contrast, Levels, Exposure, Vibrance, Hue/Saturation, Color Balance, Black & White, Photo Filter, Channel Mixer, Invert, Posterize, Threshold) with the same sliders their adjustment layers have in the editor.
  • Output goes to gallery edits (each photo's .schist sidecar, written like a ⌘S: adjustments stay live layers, the previous edit is kept under versions/), copies beside the originals (<name>-edit.<ext>, never overwriting), or copies in a folder…; both copy modes take a format and quality.
  • New photo rows: Edit N in tabs, Move to folder…, Revert to original (the sidecar is moved into versions/, not deleted). New bucket rows: Select all, Process all…, Move all to folder….
  • Fixes a latent bug: opening several gallery photos at once used a single pending-backing slot, so every load but the last lost its sidecar link and a plain save would have overwritten the original.
  • transform_canvas is factored into a document-level transform_document, and sidecar versioning into keep_sidecar_version, so the batch engine runs without a workspace. docs/gallery.md describes the new menus and dialog.

Test plan

  • New unit test batch_process_writes_versioned_edits_and_flat_copies: rotate + invert land in the sidecar as a turned canvas with a live adjustment layer, the original bytes are untouched, a second run versions the first edit, copies land beside the photo without collisions.
  • cargo test -p schist-app library_ops (7 passed), cargo clippy -p schist-app --all-targets -- -D warnings, cargo fmt --check.
  • Headless Xvfb run on a seeded library: menu → dialog → Hue/Saturation +140° over three photos → recoloured thumbnails with "edited" badges; Revert to original restored them and left three files under versions/.
  • The neural upscale path in the batch reuses the editor's Image Size code but was not run headlessly.

🤖 Generated with Claude Code

…ht-click menus

The photo and bucket menus' "Upscale ×2" row becomes Process…, a
dialog that runs one recipe over the selection or a whole bucket:
a turn (rotate, flip), a neural ×2 upscale, and any number of
colour adjustments stacked with the same sliders their adjustment
layers have in the editor. Results land as versioned gallery edits
(the sidecar, with the adjustments kept as live layers and the
previous edit under versions/), as flat copies beside the originals,
or as copies in a chosen folder — originals are never touched and
copies never overwrite.

The menus also gain Edit N in tabs, Move to folder…, Revert to
original (the sidecar goes into versions/ rather than being lost),
and, for buckets, Select all, Process all… and Move all to folder….

Opening several gallery photos at once used a single pending-backing
slot, so every load but the last would have lost its sidecar link and
a plain save would have overwritten the original; it is a list now.
transform_canvas is factored into a document-level transform_document
and the sidecar versioning into keep_sidecar_version so the batch
engine can use both without a workspace.

Co-Authored-By: Claude Fable 5.1 <[email protected]>
@IAmJSD
IAmJSD merged commit 81a33aa into main Sep 2, 2026
4 checks passed
@IAmJSD
IAmJSD deleted the t3code/77ad8e6e branch September 2, 2026 19:18
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.

1 participant