Commit Graph
11425 Commits
Author SHA1 Message Date
ljkxandClaude Opus 5.5 79b8073a8d Merge origin/main into feat/cli-metadata-option
Resolve docs/file-format-parity.md: keep main's new revision-history rows and this PR's row.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 20:38:24 +01:00
David Mann d93e65d001 Merge pull request #10952 from davidmann4/integration-batch-13
Integration batch 13: 13 parity epic PRs on main
2026-11-03 20:37:25 +01:00
dotCooCoo c439525a0d Layers panel: the Artboard filter reuses the panel's selection
Filter::with_selection takes the document and selection the Layers panel
already reads for the frame, so the Artboard filter does not walk the
document a second time on every redraw.
2026-11-03 11:35:22 -08:00
David Mann 4bbe9c78de Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	docs/scorecard.md
2026-11-03 20:32:22 +01:00
David Mann e6c4d91689 Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	crates/engine/src/prefs/validate.rs
#	docs/gaps.md
#	docs/scorecard.md
#	docs/ui-parity.md
2026-11-03 20:30:50 +01:00
vangel76andClaude Sonnet 5.5 af025e18d5 paint: replace only NaN brush values, test a long pixel-grid segment
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-03 20:30:34 +01:00
vangel76andClaude Sonnet 5.5 f5e92a6b3d paint: stream the dab generator's steps and keep non-finite brush values and points out
DabGenerator::walk collected every step of a segment into a Vec before building
dabs (up to 1e7 steps in the pixel-grid mode). The steps now become dabs as the
walker emits them. Non-finite opacity, flow, hardness and spacing fall back to the
defaults in bounded_for_render, and the smoother drops points without a finite
position.

Refs #11137

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-03 20:28:50 +01:00
David Mann 93384bf46e Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	crates/ui-egui/src/canvas/wheel_nav.rs
#	docs/scorecard.md
2026-11-03 20:23:24 +01:00
David Mann 854134df0f Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	crates/engine/src/cmd/image_cmds.rs
2026-11-03 20:14:58 +01:00
David Mann 7b4f29cace Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	crates/engine/src/cmd/image_cmds.rs
2026-11-03 20:11:45 +01:00
Claude 6641468187 #10682: the Batch test compares its output with the text typed by hand 2026-11-03 19:11:00 +00:00
vangel76andClaude Sonnet 5.5 acd35e1202 Guard zero-channel regions and saturate the pick-up bounds in Smudge
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-03 19:53:53 +01:00
vangel76andClaude Sonnet 5.5 c7e82529fe perf(paint): Mixer sample reads only the dab rectangle (#11133)
apply_mixer_dab read and converted the whole stroke working rectangle for every dab when a sample surface was given, which made Sample All Layers strokes quadratic. It now reads fp.rect clipped to the working rectangle, which is all apply_mixer_dab_region reads. Pixels are unchanged. Refs #11133.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-03 19:51:34 +01:00
vangel76andClaude Sonnet 5.5 9df4cd395c perf(paint): Smudge start-up and selection sampling without per-pixel work (#11132)
Smudge writes its carry buffer straight into place (no Vec per pixel) and picks up row by row; mix_back and apply_coverage read the selection one row at a time instead of one tile lookup per pixel. Output is bit-identical, tests compare against the previous per-pixel code. Refs #11132.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-03 19:51:02 +01:00
vangel76andClaude Sonnet 5.5 90e1e359f1 perf(paint): cache procedural brush textures between strokes (#11134)
BrushContext::new regenerated the procedural texture and re-applied its levels for every stroke and every symmetry pass. A bounded LRU (4 entries, 16 MiB) keyed by style, size, seed and the level settings returns the identical image. Refs #11134.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-03 19:50:53 +01:00
vangel76andClaude Sonnet 5.5 643786fdd8 test(paint): cover every special coordinate on both axes
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-03 19:46:47 +01:00
vangel76andClaude Sonnet 5.5 6a2baca3d6 perf(paint): wrap the Texture pattern once per axis in bilinear sampling (#11130)
Texture at a scale other than 100% made four sample_wrap calls per pixel,
eight rem_euclid in all. Wrap the two columns and rows once and read the four
texels directly; same bits out, with a test against the old four-call form.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-03 19:46:02 +01:00
David MannandClaude Opus 5.5 72c2585177 Merge origin/main (287352bf92) into integration-batch-13
Conflict in crates/engine/src/jobs.rs: main's save commit point (#5333,
OPEN/COMMITTED/CANCELLED phase) met the batch's cancel state
(CANCEL_REQUESTED/WORK_FINISHED). Both now share one atomic with a
COMMITTED bit; commit vs cancel and the batch's late-cancel guard each
stay one compare-and-swap. A Batch that refuses a repeated or late cancel
reports CancelRefused::Finishing ("finishing") in jobs.cancel's
notCancelled list, still {"cancelled": 0}. control-protocol.md documents both.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 19:35:44 +01:00
Claude dd8d675646 #10726: the committed-join test checks the commit went through and carried the path on
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01GbuSKAS2k5248LGFEapMUR
2026-11-03 18:33:25 +00:00
RickiNanoandClaude Opus 5.5 d33ec3c76d Preferences: rustfmt the Effect Cache load test
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 19:15:11 +01:00
RickiNanoandClaude Opus 5.5 4c262b0402 Preferences: a saved Effect Cache above the cap loads clamped
Review follow-up (skylartaylor on #10921). A 32-bit build accepted an
Effect Cache up to 65536 MB before its 1536 MB cap, and loading kept such
a value. Apply from another Preferences tab sends every value, so
validation rejected the untouched cache and blocked the unrelated change.
load_prefs_json now clamps effectCacheMb to the range the field accepts
(accepted_effect_cache_mb, which the byte budget uses too), so an old or
hand-edited value loads as the nearest one the dialog can save.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 18:59:21 +01:00
RickiNanoandClaude Opus 5.5 0c25e65bbd Preferences: the effect cache budget honours the field's 16 MB minimum
Review follow-up (CodeRabbit on #10921). A hand-edited effectCacheMb of
0 made Performance::effect_cache_budget_bytes report 0 bytes, though the
cache floors it at 1 MiB. The budget now clamps to the range the field
accepts (EFFECT_CACHE_MIN_MB..effect_cache_max_mb), and prefs::range
takes its minimum from the same constant.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 18:46:28 +01:00
RickiNanoandClaude Opus 5.5 d1ecc83867 Preferences: cap the effect cache on every 32-bit build
Review follow-up (CodeRabbit on #10921). The 1536 MB cap is about a
32-bit address space, not the browser: on 32-bit Windows a budget of
4096 MB or more saturated to usize::MAX, so the cache never evicted.
The cap (dialog range, prefs.set and the budget) now applies whenever
target_pointer_width is 32, which covers wasm32 and x86 Windows.

effect_cache_budget_bytes_for returns u64 and clamps to the accepted
maximum, and the tests compute their expectations in u64, so neither
overflows a 32-bit usize.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 18:46:28 +01:00
RickiNanoandClaude Opus 5.5 d8003129ec Preferences: Effect Cache accepts only the budget the web honours
Review follow-up (CodeRabbit on #10921):
- The Effect Cache field's range (prefs::range, which bounds both the
  dialog and prefs.set) tops out at the web cap of 1536 MB in the web
  build, so the dialog no longer shows and saves a value the cache never
  gets. Desktop keeps 16..65536.
- The byte budget moves into effect_cache_budget_bytes_for(stored, web),
  so the web cap is tested on every target, not only when tests run as
  wasm32 (CI only type-checks wasm).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 18:46:28 +01:00
RickiNanoandClaude Opus 5.5 41e675e35d Preferences: show Effect Cache, which the engine reads (#204)
The prefs_usage test skipped prefs.rs entirely, so it never saw
Session::apply_prefs read performance.effectCacheMb, and the working
setting stayed in HIDDEN_UNTIL_IMPLEMENTED. The test now scans the
`impl Session` blocks of prefs.rs, as the scorecard's prefs audit does,
and the setting is shown again.

With the field visible, the web build could take a budget up to
65536 MB, more than wasm's 4 GiB address space, so the cache could grow
until allocation aborts. The new Performance::effect_cache_budget_bytes
caps it at WASM_MEMORY_USAGE_CAP_MB on the web, as
effective_memory_usage_mb does, and converts with saturating_mul: on
wasm32 the old `mb << 20` truncated mod 4 GiB (4096 MB became 0, 5000 MB
became 904 MB).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 18:46:28 +01:00
RickiNanoandClaude Opus 5.5 cf91cf2657 Properties percent: a linked field takes the size the other one left
With W/H linked, `50%` in W, a click into H and `50%` there left the
shape 40x20 instead of 20x10 (and the same from H into W). H froze its
percentage base on focus gain, the frame W's transform was still
queued, so it kept the old height for the whole edit.

A focused field now reads the current size; the base is kept only from
the commit frame into the next, where egui reads the text once more.
Tests cover the click handoff both ways and W then H with Enter.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 18:42:05 +01:00
FredApps 287352bf92 Merge pull request #5333 from vistaero/codex/streamed-psb-save
Integrate streamed PSB saves with the shared save service
2026-11-03 18:41:16 +01:00
yoriswind 0edb29a18c Merge upstream main into Shear action mapping 2026-11-03 09:32:21 -08:00
David Mann 483140964c Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	crates/ui-egui/src/app/commands.rs
#	crates/ui-egui/src/i18n/cs.tsv
#	crates/ui-egui/src/i18n/de.tsv
#	crates/ui-egui/src/i18n/ko.tsv
#	crates/ui-egui/src/i18n/vi.tsv
#	crates/ui-egui/src/i18n/zh-hans.tsv
#	crates/ui-egui/src/i18n/zh-hant.tsv
#	docs/scorecard.md
#	docs/ui-parity.md
2026-11-03 18:23:32 +01:00
funkvay-star 2932e7fcdd Docs: where the Levels clipping display shows (#3328)
Only RGB and Grayscale documents with a raster layer target show it.
Other targets accept __clipping and keep the normal preview.
2026-11-03 21:23:29 +04:00
funkvay-star cb9e0f82d8 Levels clipping: test that a null __clipping draws no mesh (#3328)
The test paints a canvas frame with the dialog still open and checks
the cached texture draws nothing. paint_view now paints in a frame of
its own so its meshes don't spill into the next frame's shapes.
2026-11-03 21:23:15 +04:00
skylar taylor-barrick b323c1ba27 Merge pull request #10731 from RickiNano/fix/10665-pasteboard-pick-offcanvas
Don't auto-select off-canvas layers from the pasteboard (#10665)
2026-11-03 18:17:45 +01:00
funkvay-star 01cbd41e2b Levels clipping: drop the cache when the last document closes (#3328)
With no document there is no canvas to paint the display away, so
sync_views drops its cache and texture.
2026-11-03 21:14:17 +04:00
funkvay-star fadef65cc8 Levels clipping: draw nothing while a background job runs (#3328)
paint now returns before thresholds, scan and image while the session
has jobs, and the display comes back once they are done.
2026-11-03 21:12:15 +04:00
funkvay-star 8878ff335f Levels clipping: cap the display at 2048 x 2048 blocks (#3328)
A huge canvas grows the block size instead of building a 33M-texel
texture (8K at 100 %). 2560x1440 keeps one block per device pixel.
2026-11-03 21:09:58 +04:00
David Mann 3d36330d94 Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	docs/scorecard.md
2026-11-03 18:08:29 +01:00
funkvay-star 216a4260b0 Levels clipping: snapped area stays within the texture limit (#3328)
Snapping the visible area to the block grid can widen it by a block,
so the block size now grows until the snapped area fits max_side.
2026-11-03 21:07:09 +04:00
funkvay-star 0a209116e6 Levels clipping: no display for Smart Filter dialogs (#3328)
A Smart Filter's Levels edits the filter, not the layer's pixels, so
the display skips __smartFilter dialogs as the live preview does.
2026-11-03 21:04:21 +04:00
ljkxandClaude Opus 5.5 516c70073e Merge origin/main into feat/cli-metadata-option
Resolve apps/photocraft-cli/src/args.rs: keep both ValueError variants (Metadata and main's OnOff).
Resolve docs/file-format-parity.md: keep main's entries and re-add this PR's status entry, table notes and history row.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 18:03:15 +01:00
FredApps 996a52cb8f PSD export: a cancelled save stops between the bands of a banded layer
A banded layer checks the save's interrupt before each band and before each
channel's part of a band. Once cancelled it stops there and doesn't encode the
layer again raw; the incomplete model is discarded by the caller (which returns
IoError::Cancelled), so the save never reaches its commit point and the target
is untouched. Ex carries the export's Interrupt for this.

Addresses CodeRabbit review on crates/io/src/psd_export/banded.rs.
2026-11-03 18:00:23 +01:00
ljkx 3c82477fac Crop: turning the image keeps the frame inside it (#10869)
In the default mode a drag outside the box turns the image, but the
frame never changed, so its corners left the turned image and the crop
filled them with the background colour.

Each move of the turn now starts from the frame at the press: it keeps
its size and place if it fits the turned image, else moves the shortest
way in, else shrinks about its centre (keeping its proportions) to the
largest size that fits. The view follows the frame's centre, so the box
stays put on screen. Ctrl (Cmd) held during the turn leaves the frame as
it was. Content-Aware Fill and a frame already past the canvas keep
today's behaviour (not measured).
2026-11-03 17:57:16 +01:00
FredAppsandClaude Opus 5.5 d07684a379 fix(ui): Overscroll off keeps an image smaller than the window centred (#10488) (#11085)
* fix(ui): Overscroll off keeps an image smaller than the window centred (#10488)

With Tools › Overscroll off, an image smaller than the window stayed
wherever zooming around the pointer left it, inside the window, so
zooming out drifted it off centre. #1718 measured that on Photoshop 25.4,
but two reports of Photoshop itself (#10488, #4799) say it stays centred
with Overscroll off. The owner chose the centred behaviour:
scrollbars::clamp_axis now centres an axis on which the image is no
larger than the view; a larger image still can't leave its edges, and
Overscroll on keeps the free view.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): Overscroll off centres a fitting rotated image (#10488)

CodeRabbit on #11085: the rotated clamp path was only tested from an
already-centred view. A 600 px square at 45 degrees, started off centre
in a 900-point view, now ends with its screen bounds centred.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* style(ui): keep the rotated centring test within rustfmt's width

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 17:55:50 +01:00
FredAppsandClaude Opus 5.5 d9dc644db1 fix(ui): Roundness previews its radius within 1 px, and a held frame survives a factor change (#10474) (#11081)
* fix(ui): Roundness previews its radius within 1 px too, and a held frame survives a factor change (#10474)

Follow-up to #10524 from its last CodeRabbit review.

- Roundness's disc reaches floor(r) pixels along an axis, so at 6 px
  and k = 4 the proxy radius 1.5 reached 1 proxy px: a 4 px preview for
  a 6 px result. The factor now keeps floor(r / k) * k within 1 px of
  floor(r), as Squareness already does with round (k = 3 at 6 px, k = 2
  at 50 px). One whole-pixel function per mode replaces the special case.
- A canvas test drives the worker across a factor change: the frame for
  k = 2 stays on the canvas, at its own size, until the k = 1 frame lands.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(ui): a fractional Roundness radius previews closer at its chosen factor (#10474)

CodeRabbit on #11081: only the factors were pinned. At 6.5 px the
Roundness preview at the chosen k = 3 is compared with OK's result and
must differ less than the k = 4 preview did.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(ui): a mid-drag frame for the previous proxy factor still reaches the canvas (#10474)

CodeRabbit on #11081: the display gate keeps a held frame at any factor,
but the mid-drag publish arm still required the same factor, so a frame
finished for the factor the drag just left was dropped. It now uses
same_target_at_any_scale too; a frame already exact for the dialog is
still never displaced.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 17:55:42 +01:00
d21c403e5f Type: add OpenType Numerals submenu (figure styles) (#11051)
* Type: add OpenType Numerals submenu (figure styles)

Type › OpenType › Numerals sets lnum/onum/pnum/tnum as a radio style
(Default through Tabular Oldstyle). Checkmarks follow the selection
start; TYPE-218-5 scorecard/gaps updated; parity floor 640.

* refactor(engine): one style-at-character lookup for the OpenType menus

feature_on_at and numerals_style_at each walked the runs the same way;
they now share style_at. NumeralsStyle::from_id and numerals_style_of
read the existing tables instead of repeating them.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(text): persist OpenType numeral tags through PSD EngineData

Map lnum/pnum/tnum as EngineData bools and the width×height combos as
FigureStyle (Krita/Illustrator), so Numerals choices survive PSD round-trip.

* docs(gaps): note Numerals PSD figure-tag round-trip

* revert(text): keep PSD EngineData to the keys Photoshop writes

Backs out the PSD half of 18610324 and its gaps note (58813de3); the
engine reformat in that commit stays.

- `LiningFigures`, `ProportionalFigures` and `TabularFigures` are not
  Photoshop EngineData keys (the commit says Photoshop only has
  `OldStyle`), so writing them puts keys of our own into users' PSDs.
- The `/FigureStyle` code table (1-4) has no oracle: no Photoshop-authored
  file in photocraft-corpus, and neither ag-psd nor psd-tools reads it.

AGENTS.md rule 3 asks for public specs or observation. PSD persistence
of the numeral styles can come back with a Photoshop-authored oracle.
The Numerals menu still round-trips through .pcraft.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(text): lock PSD EngineData to Photoshop OldStyle for numerals

Document AGENTS.md clean-room: only onum survives TySh round-trip; lnum/pnum/tnum stay .pcraft-only until a Photoshop-authored corpus oracle.

---------

Co-authored-by: FredApps <153173854+FredApps@users.noreply.github.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 17:55:35 +01:00
ljkxandClaude Opus 5.5 dbf178969e Merge origin/main into fix/gradient-stop-drag-off
Resolve the parity-doc conflict: keep main's status line and entries, prepend this PR's entry.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 17:50:00 +01:00
ljkxandClaude Opus 5.5 01aef54239 Merge origin/main into feat/raw-xmp-crop
Resolve the parity-doc conflict: keep main's status line and entries, prepend this PR's entry.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 17:49:39 +01:00
ljkxandClaude Opus 5.5 96283f7458 Merge origin/main into feat/smart-sharpen-canvas-preview
Resolve the parity-doc conflict: keep main's status line and entries, prepend this PR's entry.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 17:49:33 +01:00
ljkxandClaude Opus 5.5 57cbf3111c Merge origin/main into feat/photo-filter-last-settings
Resolve the parity-doc conflict: keep main's status line and entries, prepend this PR's entry.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 17:49:13 +01:00
ljkxandClaude Opus 5.5 0a379e2465 Merge origin/main into feat/color-picker-live-preview
Resolve docs/ui-parity.md: keep main's status line and prepend this PR's entry.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 17:46:51 +01:00
David MannandClaude Opus 5.5 ae0da189a2 Address CodeRabbit review: a cancel after an action's saved snapshot keeps that file
When an action saves and then closes or switches away, Batch writes the
saved snapshot inside the action closure. A cancel landing after that write
made process_one return Cancelled, so the input was reported as skipped
although its output exists. The snapshot write is now final: the cancel
stops only the inputs after it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 17:26:39 +01:00