Commit Graph
11425 Commits
Author SHA1 Message Date
skylar taylor-barrick fd1faf4e13 Merge pull request #6381 from dylanmtaylor/ci/shared-freebsd-workflow
ci: delegate FreeBSD workflow to craft-common-actions and add nix check
2026-10-15 21:34:22 -06:00
jonathnwxh 1d21c921f8 style: apply rustfmt to upstream smart-filter regression 2026-10-16 11:29:21 +08:00
jonathnwxh 2c635c5c3e Merge remote-tracking branch 'origin/main' into repair/6380-upstream-schema 2026-10-16 11:29:20 +08:00
skylartaylor 8f58ea4629 ci: integrate current main while retaining strict test gates 2026-10-16 05:25:24 +02:00
LochLogicandClaude Opus 5.5 708d393988 Tests: every GPU test holds gpu_lock (STATUS_ACCESS_VIOLATION on Windows)
testkit::gpu_lock documents that WARP faults in d3d10warp.dll when two GPU
harnesses render in parallel in one test process, and that every test that
builds a GPU harness or device holds the lock. Fifteen tests didn't, so on
Windows checker_canvas and marquee_autoscroll (and the lib test binary's GPU
tests) could take their whole test binary down with STATUS_ACCESS_VIOLATION.
They now take the lock on their first line, as the others do.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 21:24:07 -06:00
Higgs32584andClaude Opus 5.5 a80ece00aa Merge origin/main; cargo fmt (new_doc_ui.rs, smart_filter_authorization.rs)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 23:01:51 -04:00
Higgs32584 84d7a5f86f Merge remote-tracking branch 'origin/main' into fix/688-windows-symbols 2026-10-15 22:49:38 -04:00
Higgs32584 5d9093bf0c Merge remote-tracking branch 'origin/main' into HEAD 2026-10-15 22:49:34 -04:00
Omar Saidahmed 2b5e857d92 convert the background and match mask depth where they were missed 2026-10-15 22:46:05 -04:00
Omar Saidahmed 6822125f79 keep the rendering of smart filters that cannot be reproduced 2026-10-15 22:34:00 -04:00
Higgs32584andClaude Opus 5.5 43115de4ea rustfmt; merge main (CI Format step)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 22:30:29 -04:00
Higgs32584andClaude Opus 5.5 5c0e40784a rustfmt; merge main (CI Format step)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 22:29:42 -04:00
Higgs32584 36236b908a Merge remote-tracking branch 'origin/main' into fix/4962-web-save-dirty 2026-10-15 22:28:59 -04:00
Higgs32584andClaude Opus 5.5 b6be26a490 rustfmt; merge main (CI Format step)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 22:28:54 -04:00
Higgs32584 8cedb81a63 Merge remote-tracking branch 'origin/main' into fix/5712-artboard-pasteboard-hides-loose-layers 2026-10-15 22:28:09 -04:00
Higgs32584andClaude Opus 5.5 5f8d92f9f0 rustfmt; merge main (CI Format step)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 22:27:09 -04:00
Higgs32584 ad620fba50 Merge remote-tracking branch 'origin/main' into fix/5884-delay-load-windows-data-pdf 2026-10-15 22:26:18 -04:00
Higgs32584andClaude Opus 5.5 c972acf98f rustfmt: format after merging main (CI Format step)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 22:16:12 -04:00
Higgs32584andClaude Opus 5.5 76f29f67d5 rustfmt: format after merging main (CI Format step)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 22:16:03 -04:00
Higgs32584 3eef8af459 Merge remote-tracking branch 'origin/main' into fix/help-search-arrows-space 2026-10-15 22:09:43 -04:00
Higgs32584 f46bd2a907 Merge remote-tracking branch 'origin/main' into fix/1056-path-selection-canvas-menu 2026-10-15 22:09:40 -04:00
Higgs32584andClaude Opus 5.5 3f73409ba2 Context menus: an overflowing menu shows scroll arrows (#2091)
Long right-click menus already scrolled when taller than the window, but
only through egui's thin floating scroll bar, so nothing showed that more
items were hidden. Like Photoshop's and the system menus, an overflowing
menu now has arrows above and below its rows: hovering one scrolls that
way, clicking jumps a page, and an arrow dims at its end.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 22:06:52 -04:00
Dylan M. Taylor 0cc161e2a8 ci: delegate FreeBSD workflow to craft-common-actions and add nix check 2026-10-15 22:04:09 -04:00
Higgs32584andClaude Opus 5.5 7bc556ec02 Web: a requested download no longer marks the document saved (#4962)
The web writer only triggers an anchor download, which the user can cancel
and which reports nothing back, yet Save treated it as a confirmed write:
the document was marked clean and the leave-page guard disarmed. Services
gains `write_unconfirmed` (set by the web shell); a save through such a
writer names the document but keeps its changes unsaved.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 21:54:09 -04:00
Higgs32584andClaude Opus 5.5 73459a662c Artboards: layers outside the boards stay visible over the pasteboard (#5712)
Adding an artboard next to earlier work made that work vanish: the canvas
painted the opaque pasteboard over the whole image outside the boards,
hiding layers that are not in an artboard. Photoshop shows them, so the
pasteboard now leaves out where visible loose layers draw (their
composite bounds).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 21:44:21 -04:00
skylar taylor-barrick e2347f8ead Format inherited smart-filter authorization test 2026-10-15 19:41:26 -06:00
skylar taylor-barrick 1c93c79565 Simplify canvas visibility guard for strict Clippy 2026-10-15 19:37:04 -06:00
channelrambleandCodex c17761d032 Fix File Info field semantics and add layer-under-cursor selection
Co-authored-by: Codex <noreply@openai.com>
2026-10-15 19:37:04 -06:00
channelramble 25993c06c6 Fix painting, metadata, Pen and cursor workflows 2026-10-15 19:36:42 -06:00
jonathnwxh f22d08da8c style: apply rustfmt to upstream smart-filter regression 2026-10-16 09:32:47 +08:00
David MannandClaude Opus 5.5 a9ba86898e PSD: Hue/Saturation smart filters open and save like Photoshop (#6267)
A Hue/Saturation smart filter (Fltr class HStr, filterID 'HStr') opened
as psd.unsupportedFilter, so re-rendering the smart object (replace
contents, relink) dropped it, and a Hue/Saturation smart filter made in
PhotoCraft was left out of PSD saves.

The new hue_sat_filter_map module maps Photoshop's layout (measured on a
Photoshop-saved file: presetKind, Clrz, Adjs = master Hst2 {H, Strt,
Lght} plus one Hst2 per edited range with LclR, BgnR, BgnS, EndS, EndR,
all longs) to image.adjustments.hueSaturation with the command's params,
and writes it back in that layout. Anything outside it (unknown keys,
duplicate or unknown ranges, values the dialog can't hold) stays an
opaque unsupported filter written back verbatim. smart_map.rs only gets
the dispatch hooks.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-16 03:18:42 +02:00
David MannandClaude Opus 5.5 b59b0cd1d5 PSD: Perspective Warp smart filters open and save like Photoshop (#6268)
A Perspective Warp smart filter (Fltr class perspectiveWarpTransform) fell
through to psd.unsupportedFilter, so a re-rendered smart object (e.g. after
Replace Contents) lost its perspective. Each quad now becomes a plane of
layer.smartObjects.perspectiveWarp (src = vertices, dst = warpedVertices),
and PSD save writes Photoshop's descriptor back: the original item with
only the geometry rewritten, or a new item in the layout Photoshop writes.
Inconsistent descriptors stay opaque, as before.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-16 03:18:18 +02:00
Gustavo Ziger 5c941c5656 Merge branch 'main' into feat/zoom-animation-566 2026-10-15 22:17:24 -03:00
PerchenkoAnton 3cb3580a46 fix(psd): recover layered imports with damaged merged data (#6170) 2026-10-15 19:14:05 -06:00
jonathnwxh 7bff38c176 Merge remote-tracking branch 'origin/main' into repair/5413-upstream-schema 2026-10-16 09:13:54 +08:00
David MannandClaude Opus 5.5 0ce7e00fee Brush: the Dual Brush tip keeps its proportion at tiny main sizes (#4809)
Photoshop scales the Dual Brush diameter by the main size ratio, unrounded,
with a 5000 px cap and no lower floor: main 100 / dual 20 resized to 1 px
gives a 0.2 px dual tip, and back at 100 px it is 20 px again. PhotoCraft
already scaled the dual tip (#4856) but floored it at 0.5 px, so a trip to
1 px and back left a 50 px dual tip. Drop the floor (rendering bounds the
diameter itself), keep the cap, and leave a non-positive or NaN result alone.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-16 03:06:07 +02:00
Higgs32584andClaude Opus 5.5 cf3d26881d Windows: start without Windows.Data.Pdf.dll; delay-load it for printing (#5884)
winprint's PdfCreateRenderer made photocraft.exe and photocraft-cli.exe
import Windows.Data.Pdf.dll at load time, so Windows images without the
PDF component (NTLite-stripped, some N/LTSC builds) refused to start:
"windows.data.pdf.dll was not found". Both apps now delay-load it, and
PDF printing checks the DLL is installed first and reports an error
instead of aborting.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 20:41:08 -04:00
skylar taylor-barrick b630d7cb9a Security: enforce the automation read boundary on stored smart-filter params (#5684)
* Security: enforce the automation read boundary on stored smart-filter params

Smart filters store a command id and params inside the document, so a
crafted .pcraft could resolve stored ambient paths (displace mapPath,
color-lookup LUT files) at render time without the authorize gate:
synchronous smart-object rendering has no Session argument, spawned job
threads drop the requesting session's authority, and a trusted UI
render could warm the process-wide stack cache with a stage the gate
never saw.

Thread the requesting session's gate through a thread-local in jobs.rs
(entered around command execution, reinstalled on spawned workers and on
job apply, restored on drop), re-check stored filter commands in
render_in before source resolution and any cache lookup and in
apply_filter_to_surface, and re-authorize layer.smartFilter.setParam
with the complete merged params after merging stored document params —
including edits whose request contains no path and actions.play steps.
Denial is conservative: the document is unchanged and no worker starts.

Regression tests in the automation crate cover rerender, cached-stage
reuse, merged-param edits, action playback, background jobs, and filter
transfer, for both the displace map and color-lookup LUT vectors.

* Review: carry render authority through Session::edit and surface denials

Session::edit is the engine's universal mutation entry (linked-file
refresh, transforms, place); renders reached through it ran with no
authorization scope installed, so stored smart-filter params read
ambiently there even after the execute-path fix. Install the scope in
Session::edit as well, keyed on the session's authorize gate.

apply_filter_to_surface also conflated a denied filter with an unknown
one: authorize_render_command's Result was discarded with .ok()?, so a
denial silently rendered unfiltered pixels and the stage entered the
process-wide stack cache. The signature becomes
Result<Option<Surface>>: Err for denials (callers propagate), None for
ids that aren't pixel filters (pass-through semantics unchanged), and an
unreadable map keeps its deliberate pass-through. apply_smart_filter and
apply_smart_filters propagate instead of cur.clone().

Two tests: a refresh driven outside command execution (Session::edit)
is denied and leaves the document unchanged; a denied render caches no
stage. Nine authorization tests pass, engine suite and strict Clippy
clean, panic hunt green.

* ui_set description: name the layerFilter field main added

The Layers-panel filter dropdown (#5048) added layerFilter to the
control method's UI_SET_FIELDS without extending the ui_set tool's
description, so the drift guard (mcp.rs, ui_set_description_names_every_
accepted_field) fails on Windows CI for any branch built on main. Name
the field with its patch shape: by (kind, name or mode), kinds (a list
of layer kinds), name (matches part of the layer name), mode (a blend
mode name). The 40 MCP tests pass; strict Clippy clean.

* wasm size: compose and algo join cms at opt-level "z" to clear the 24 MiB gate

Main's browser build is 171 KB over the 24 MiB wasm gate in CI
(25,337,343 bytes), so every branch built on current main fails the
web size check. Demote three pixel crates in the wasm-release profile:

- cms: transforms are built once and cached (transform::cached),
  so "z" costs little runtime (measured -42 KB).
- compose: the browser app composites per frame on the GPU (crates/gpu,
  WebGPU/WebGL2), so the CPU compositor is not the browser's hot path
  there (measured -122 KB).
- algo: filters run per pixel on every interactive filter application.
  "z" there is the lever of last resort (measured -331 KB), taken
  because the gate is enforced in CI; if browser filters feel too slow,
  restore 3 here and reclaim the bytes from a feature-gated decoder.

Final size 24,811,949 bytes locally, 354 KB under the gate; the native
profiles are untouched. If a maintainer prefers keeping algo at 3, the
alternative is raising the self-imposed 24 MiB early-warning limit
(Cloudflare's hard cap is 25 MiB) - a policy call in packaging/web/
package.sh, not a code fix.
2026-10-15 18:19:26 -06:00
cortezsilvano-botandClaude Opus 5.5 6f2abe20fc Print: Functions › Bleed (corner crop marks on the trim line)
Photoshop's Print dialog has Functions › Bleed: crop marks print inside
the image by the bleed width, so trimming on them cuts through the
artwork and leaves no paper-white sliver. target-app-parity listed it as
missing ("No Separations/bleed").

- file.print / file.printOneCopy take "bleed" in inches (default 0),
  report it back, and Print One Copy remembers it.
- Corner crop marks move onto the trim line, still starting 6 pt outside
  the image. Centre and registration marks are unchanged (a symmetric
  bleed doesn't move the midlines).
- One helper (corner_crop_segments) drives both the PDF writer and the
  native Windows primitives; the dialog preview draws the marks there too.
- Negative, non-numeric or too-wide bleeds are BadParams, never a panic;
  bleed without corner crop marks changes nothing and reports 0.
- With bleed absent or 0 the PDF is byte-identical (tested).

The Print dialog field is a follow-up: every tl! label needs all
translations.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 19:14:47 -05:00
itsF4LCON 92c5c07202 Video Frames to Layers: every page of a multi-page TIFF (part of #6379)
A multi-page TIFF gave only its first page, while an animated GIF gives every
frame. File › Import › Video Frames to Layers and a video layer from a file
now take every full-resolution page of the TIFF's main chain, in order, one
layer (or frame) each, through io::import_tiff_page. Thumbnails,
reduced-resolution copies and masks are left out; a single-page TIFF is one
frame as before.
2026-10-16 02:03:50 +02:00
Higgs32584andClaude Opus 5.5 7cf4f27cf6 Windows releases ship a symbols zip: the release build's PDBs for profilers (#688)
package.ps1 now also writes photocraft-<v>-windows-<arch>-symbols.zip with photocraft.pdb and
photocraft_cli.pdb from the same optimized build as the signed exes, plus symbols.txt on loading
them in WPA, Superluminal or Visual Studio. It's a separate optional asset, so the MSI and
portable zip keep their size; the shared release workflow uploads everything in dist/release.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 19:42:38 -04:00
Higgs32584andClaude Opus 5.5 78bdba1134 Merge upstream/main
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 19:39:07 -04:00
Higgs32584andClaude Opus 5.5 eee57c02ce Merge upstream/main
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 19:38:26 -04:00
itsF4LCON dedf89feae Type: move the caret test next to its helper, away from the file's end 2026-10-16 01:33:24 +02:00
Higgs32584andClaude Opus 5.5 8237d76170 Help search test: take the first Levels result and move the cursor to the end
"levels" now finds two results (Image › Adjustments › Levels… and the
Levels adjustment layer), and one → only reaches level|s, so the test
needs a second → before typing the space.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 19:28:58 -04:00
David Mann a6f30f8de3 Merge main into fix/history-options
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

# Conflicts:
#	docs/scorecard.md
2026-10-16 01:24:54 +02:00
itsF4LCON 67602017f8 Merge remote-tracking branch 'upstream/main' into feat/6278-replace-color-result
# Conflicts:
#	crates/ui-egui/src/i18n/ko.tsv
#	crates/ui-egui/src/i18n/zh-hans.tsv
#	crates/ui-egui/src/i18n/zh-hant.tsv
2026-10-16 01:21:27 +02:00
David Mann ee0da9fbac Merge main into docs/scorecard-stale-rows-2
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

# Conflicts:
#	docs/scorecard.md
2026-10-16 01:13:28 +02:00
David Mann e80bd0ab7d Merge main into feat/ui-217-4-columns-unit
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

# Conflicts:
#	docs/scorecard.md
2026-10-16 01:08:34 +02:00
David Mann e6d636ce75 Merge main into feat/ui-217-4-animated-zoom
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

# Conflicts:
#	docs/scorecard.md
2026-10-16 01:02:02 +02:00