Commit Graph
11425 Commits
Author SHA1 Message Date
Vincent Cloutier 0d7e849605 Merge current upstream main and require decoded animation corpus descriptors 2026-11-02 14:37:22 -05:00
yoriswind 003a8a5482 fix: preserve Batch references, source images and script limits 2026-11-02 11:36:42 -08:00
Claude 311d8fb128 Merge remote-tracking branch 'upstream/main' into fix/typing-records-one-step 2026-11-02 19:31:11 +00:00
Claude 3c100eb526 Merge remote-tracking branch 'upstream/main' into fix/curvature-pen-resumes 2026-11-02 19:29:28 +00:00
David Mann 673bfb4d9c Merge remote-tracking branch 'origin/main' into integration-batch-12
# Conflicts:
#	docs/file-format-parity.md
2026-11-02 20:15:23 +01:00
yoriswind dd1f34a57d fix: preserve Actions dialog ownership and picker limits 2026-11-02 11:07:35 -08:00
ljkx 61c72186f6 Crop: a Shift-corner drag follows the frame's diagonal (#10871)
With a free ratio, Shift on a crop corner kept the proportions by letting
the larger relative extent win, so (-100, -50) on an 800 x 500 frame gave
720 x 450. Photoshop projects the pointer onto the frame's diagonal through
the dragged corner and gives 706 x 441. Do the same, with and without Auto
Center Preview and on a turned frame. A ratio preset, Alt+Shift and edge
handles keep today's rule.
2026-11-02 20:03:32 +01:00
FredApps f8e393fdb6 Merge pull request #6266 from danielmigueltejedor/fix/gnome-window-decorations
Enable font-free GNOME/Wayland controls for system title bars
2026-11-02 19:59:41 +01:00
ljkxandClaude Opus 5.5 7eb54124ea Merge origin/main into feat/raw-xmp-crop
Conflict only in docs/file-format-parity.md: main's status line with this PR's Camera Raw crop entry first (Last updated 2026-11-02), and both revision-history rows, this PR's redated to 2026-11-02 above main's 2026-10-30 YCbCr TIFF row.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 19:59:27 +01:00
Fabio Lissi b22384aab8 Release action snapshot before closed-document scratch buffers 2026-11-02 12:44:46 -06:00
Fabio Lissi d1141d08f8 Merge branch 'main' of https://github.com/storytold/photocraft into feat/actions-record-independent 2026-11-02 12:40:52 -06:00
Fabio Lissi b27b5c7a79 Update Batch UI tests for flat filenames 2026-11-02 12:39:15 -06:00
9034223c4b TIFF: open YCbCr images as RGB (#10316) (#10319)
* TIFF: open YCbCr images as RGB (#10316)

Scanners often write JPEG-compressed YCbCr TIFFs with 2x2 chroma
subsampling. The tiff crate decodes and upsamples them but returns raw
YCbCr samples, which the decoder rejected with "colour type YCbCr(8)".

The new tiff/ycbcr.rs converts them to RGB after decoding: JPEG data
uses the JFIF full-range BT.601 conversion (as libtiff does), other
compressions honour ReferenceBlackWhite and YCbCrCoefficients with the
TIFF defaults as fallback. 8 and 16-bit. YCbCr with extra samples, or
in other sample formats, fails with a clear unsupported error.

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

* Contributors: add Yuki-init's display name

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

* TIFF YCbCr: test that YCbCrCoefficients set the luma weights

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

* TIFF: YCbCr tags with the wrong value count use the defaults

tag_f64s now returns None unless the tag holds exactly n values, so a
YCbCrCoefficients or ReferenceBlackWhite tag with extra values falls
back to the TIFF defaults instead of being truncated.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Lrgj5pnShYtsSnrsZq5iRn

* TIFF YCbCr: tests for tiled JPEG with ICC, big-endian 16-bit and planar

Covers the layouts the review asked for: a tiled 4:2:0 JPEG file with an
embedded profile (checked against an independent JPEG decoder), a
big-endian 16-bit file, and planar data in both byte orders.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Lrgj5pnShYtsSnrsZq5iRn

* TIFF YCbCr: cite the formula sources and pin the green-channel choice

Documents where the conversion comes from: TIFF 6.0 Section 21
(YCbCrCoefficients, pp. 90-91) and libtiff's tif_color.c
(TIFFYCbCrToRGBInit, TIFFYCbCrtoRGB). Red and blue follow the spec;
green follows libtiff and adds Y unscaled, which matches the spec only
when the luma weights sum to 1. The module doc records this as a
deliberate compatibility choice, and a new test pins it: with weights
0.25/0.25/0.25, mid gray stays (128, 128, 128).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Lrgj5pnShYtsSnrsZq5iRn

* Codecs README: YCbCr TIFFs with three 8- or 16-bit samples decode to RGB

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Lrgj5pnShYtsSnrsZq5iRn

* Format tiff_ycbcr tests with rustfmt

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

* test(tiff): compare grouped YCbCr decoding and update support notes

* style(tiff): align grouped decode call with test formatting

* style(tiff): apply repository rustfmt to grouped YCbCr regression

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: FredApps <153173854+FredApps@users.noreply.github.com>
Co-authored-by: FredApps <FredApps@users.noreply.github.com>
2026-11-02 19:31:22 +01:00
David Mann af2c9da25d Merge remote-tracking branch 'origin/main' into HEAD 2026-11-02 19:10:47 +01:00
FredApps 9236d27eb6 Merge current main into fix/gnome-window-decorations 2026-11-02 19:10:43 +01:00
yoriswind 848c6aa6ca Merge commit '289dd0a874763d6528bab2184a87a1b53771c02a' into codex/atn-actions-review-repairs-10766 2026-11-02 10:07:55 -08:00
David Mann f11123f472 Merge remote-tracking branch 'origin/main' into HEAD 2026-11-02 19:05:40 +01:00
David MannandClaude Opus 5.5 79fee53116 Address CodeRabbit review: the hidden-pixel resample refusal suggests Delete Cropped Pixels only when it would help
Delete Cropped Pixels clips pixel layers, fill caches and video frames only. When a layer mask,
channel, the quick mask, the selection, type, a shape or a smart object holds the hidden pixels
over the budget, the refusal now says so instead of pointing to an option that can't clear it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 19:05:38 +01:00
yoriswind 4649808594 Adapt action test fixtures to pooled render buffers 2026-11-02 09:49:07 -08:00
Fabio Lissi 07bc258bbd Avoid case probes for unrelated Batch paths 2026-11-02 11:37:52 -06:00
yoriswind 488ab1ab14 Merge commit '289dd0a874763d6528bab2184a87a1b53771c02a' into codex/atn-dialog-calculations 2026-11-02 09:37:49 -08:00
yoriswind 0681361e6e Preserve Batch sources and cancellable action filters
Resolve recorded layer targets per Batch input and refuse destructive EXR Save and Close output. Prepare custom Shape Blur kernels in cancellable jobs, retaining Smart Filter progress and geometry. Preserve supported ATN descriptor metadata, defaults, channel sources and three-value LUT shapers; cover rebuilt naming rules, non-identity Custom kernels and float lookup dither.
2026-11-02 09:37:49 -08:00
Fabio Lissi f14da98cc3 Resolve Batch log aliases in future output directories 2026-11-02 11:36:46 -06:00
Fabio Lissi 00f75988b9 Match measured Photoshop Batch naming and error logs 2026-11-02 11:30:58 -06:00
Fabio Lissi 50360ac4ef Record portable nudges, document switches, and type positions 2026-11-02 11:30:37 -06:00
ljkx 945cf2218d Crop with Delete Cropped Pixels off turns the Background into Layer 0 (#10867)
A crop with Delete Cropped Pixels off now turns the Background into a
normal layer named "Layer 0", as in Photoshop, within the crop's one
history step: straight, extending and turned crops, and crops with a
target W x H x Resolution. The pixels past the canvas stay on every
layer, and the area an extending crop adds is transparent on every
layer instead of taking the background colour. A turned crop converts
the Background before the turn, so it turns like the other layers and
keeps its overhang.

Delete Cropped Pixels on is unchanged. Image > Reveal All keeps its
current result (the Background stays, its extension takes the
background colour) by calling the inner crop with a keep-Background
flag. Content-Aware crop fill with Delete off was not measured and is
left as it is.

Adds crates/engine/tests/it/crop_delete_off_background.rs. The #7086
test now locks the cropped layer back into a Background, the state
documents saved before this change still hold.
2026-11-02 18:29:48 +01:00
Hector VillarrealandClaude Opus 5.5 c91fde6191 Path mode: a custom shape's holes cut only the shape (CodeRabbit review on shapes.rs:106)
The work path folds each subpath into everything before it, so a Ring
drawn over a rectangle in Path mode kept its hole as a subtracted subpath
and cut the rectangle where the hole overlapped it. Photoshop 2025 adds a
custom shape as one shape component: a ring placed with Combine over a
rectangle leaves the rectangle whole under the hole (checked by making a
selection from the work path).

The subpaths after a custom shape's first now join it, with holes wound
against it so the fill rule cuts them. Where the joined form would cover
a different area (an intersect or exclude subpath, or a cut reaching past
the shape, like the Crescent Moon's) the shape is appended as before.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 11:22:07 -06:00
Hector VillarrealandClaude Opus 5.5 3a0647bb67 Path mode: a new work path takes the custom shape's fill rule (CodeRabbit review on shapes.rs:106)
With no work path yet, Path mode started one with the default non-zero
rule and appended the outline's subpaths, so an even-odd custom shape
(shape.presets.new reads fillRule) lost its rule: a pentagram's middle
filled. The new work path now takes the outline's fill rule.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 11:22:07 -06:00
Hector VillarrealandClaude Opus 5.5 8eeca2301f Path mode: a custom shape keeps its holes in the work path (CodeRabbit review on shapes.rs:100)
Path mode appended the outline with path.set's "op": "combine", which
sets every appended subpath's operation, so a Custom Shape's subtracted
subpaths (the Ring's hole, the Fish's eye) became combined ones. The
outline is now appended to the work path as it is and the whole path set
in one step, so each subpath keeps its own operation, as in Photoshop.

Dropping "op" alone, as suggested, would replace the work path instead
of adding to it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 11:22:07 -06:00
Hector VillarrealandClaude Opus 5.5 28a563d3f3 Re-run CI
windows-latest unit failed in photocraft-compose's proptest the_split_route_agrees_with_the_exact_path, which this PR doesn't touch; main's CI is green.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 11:22:07 -06:00
Hector VillarrealandClaude Opus 5.5 ed7581a609 Path mode: a click that moved a little adds no subpath (CodeRabbit review on gesture.rs:92)
A Path-mode click skipped the Create dialog but fell through to
finish_shape, so a press and release a fraction of a pixel apart (still
a click) rounded to a 1 x 1 px box and added a speck of a subpath to the
work path. A click in Path mode now ends there, for every Shape tool.

Test: a_path_mode_click_that_moved_a_little_adds_no_subpath

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 11:22:07 -06:00
Hector VillarrealandClaude Opus 5.5 e81e7cd1dc Path mode: a click opens no Create dialog
CodeRabbit on #9456 (outside-diff comment, canvas.rs 6814): in Path mode
a click on Rectangle, Ellipse, Triangle or Polygon still opened the
Create dialog, whose OK makes a shape layer; Path mode never draws one.
The dialog now opens in Shape mode only.

Test: a_path_mode_click_opens_no_create_dialog

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 11:22:07 -06:00
Hector VillarrealandClaude Opus 5.5 9a0dd2a554 Path mode belongs to the Shape tools only
CodeRabbit on #9456 (inline 4372132651): with a shape layer selected,
Path Selection and Direct Selection reach the same options bar, and in
Path mode they lost Fill and Stroke and stopped editing the shape's
radius. They now always show their paint controls and keep main's fixed
Shape menu; only the six Shape tools follow Path mode.

Test: selection_tools_ignore_the_shape_tools_path_mode

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 11:22:07 -06:00
Hector VillarrealandClaude Opus 5.5 a8a3c39ea6 Path mode's Radius sets the next outline only
CodeRabbit on #9456: with a shape layer active, the Radius field in Path
mode read and edited that layer. In Path mode the options bar now has no
selected-shape target, so Radius only sets the next outline's radius.

Test: path_mode_radius_leaves_the_active_shape_layer_alone

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 11:22:02 -06:00
Hector VillarrealandClaude Opus 5.5 10ac3e3753 Keep the Shape tools' geometry options in Path mode
CodeRabbit on #9456: Path mode hid the whole shape options bar, including
Rectangle Radius, Polygon Sides, Line Weight and the Custom Shape picker.
Path mode now hides only Fill and Stroke, as Photoshop's Path tool mode does.

Test: path_mode_keeps_the_geometry_options_and_hides_paint

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 11:22:02 -06:00
Hector VillarrealandClaude Opus 5.5 638697199c feat(ui): Path mode for the Shape tools (part of #9453)
The Shape tools' mode dropdown offered only Shape, so a rectangle or an
ellipse could only become a shape layer. Photoshop's Shape tools have
Shape, Path and Pixels modes; Path adds the outline to the Work Path
and makes no layer.

The dropdown now offers Shape and Path (a tool option of its own,
`shape_mode`, Shape by default; the Pens keep their own mode). In Path
mode a drag adds its outline, custom shapes included, to the work path
as one more subpath, the preview shows the outline only, and the
fill/stroke options are hidden.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 11:21:50 -06:00
Hector VillarrealandClaude Opus 5.5 f4a87783a3 Docs: ui.set layerFilter lists the color filter (CodeRabbit review on crates/automation/src/server.rs:351)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 11:21:40 -06:00
Hector VillarrealandClaude Opus 5.5 7be3957476 Docs: UI parity lists the Layers panel's Color filter (CodeRabbit review on docs/ui-parity.md:248)
The filter-type dropdown row now reads Kind, Name, Mode and Color, the other five missing; status
line and revision history updated. No percentage changed; the scorecard has no row for it
(`cargo xtask scorecard` leaves docs/scorecard.md as it was).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 11:21:39 -06:00
Hector VillarrealandClaude Opus 5.5 1ce90f0ae0 Tests: Color filter with no matching layers and an unknown colour through ui.set (FredApps review)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 11:21:29 -06:00
Hector VillarrealandClaude Opus 5.5 7439eb7179 Layers filter: drive the Color filter through ui.set in the control test (CodeRabbit nitpick on layer_filter_ui/tests.rs:153-161)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 11:21:29 -06:00
Hector VillarrealandClaude Opus 5.5 7dadc3177d Layers panel: filter by Color, as in Photoshop (#5898)
The Layers panel's filter row gains Color after Kind, Name and Mode. Like
Photoshop's, it filters at once (by no colour at first) and lists the layers
whose label is the chosen colour; the colour menu is None plus the label
colours in Photoshop's order. ui.set's layerFilter takes "by": "color" and a
"color" label id.

Fixes #5898

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 11:21:29 -06:00
David MannandClaude Opus 5.5 43fab54950 Integration: the SVG clipboard service doc says ordinary paste reads it too; the bulk-load test checks the sets that stay loaded (#10704, #10601)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 17:56:07 +01:00
.CooCoo 289dd0a874 Format: take the .pcraft envelope from craft-pcraft-format (#10724)
* Format: take the .pcraft envelope from craft-pcraft-format

The manifest envelope, TileRef, Hash, FORMAT_VERSION, EXTENSION, the
entry names, tile_path and blob_path, is_valid_hash, the manifest
nesting and item checks and the migration runner now come from
craft-libs' craft-pcraft-format. photocraft-format re-exports them, so
callers do not change. Manifest is craft_pcraft_format::Manifest<DocM>.

Saved bundles keep the same bytes. A save still checks only the nesting
and the item count of its manifest, not its size, and the manifest
nesting limit is still computed from photocraft_doc::MAX_GROUP_DEPTH.

Tests: a save, load and save again gives the same bytes in every color
mode and depth, with and without previews; MAX_GROUP_DEPTH equals
craft_pcraft_format::MAX_GROUP_DEPTH.

* Format: pin craft-pcraft-format from storytold/craft-libs

* Format: read manifests with craft-pcraft-format's read_manifest_with

Pins craft-pcraft-format to dca870a0, the head of craft-libs #407.
Loading reads the manifest with read_manifest_with, which runs the
limit check, the version check, the migration steps and the envelope
read in one path; the layers are still decoded one at a time after the
rest of the document. A save builds the manifest with Manifest::new and
tile references with TileRef::new, and the bundle's directory names and
the .zst suffix come from the crate's constants. Saved bytes and error
messages are unchanged.

* Format: pin craft-pcraft-format to craft-libs #407's head 04dd1bd

04dd1bd changes only the crate's docs and a test, so photocraft-format
builds the same code.

* Format: pin craft-pcraft-format to craft-libs main at b8f7d93

craft-libs #407 merged as b8f7d93. Its read_manifest also refuses a
thumbnail other than thumb.png and a composite other than
composite/preview.png, the only names photocraft-format writes.
2026-11-02 11:43:46 -05:00
dotCooCoo 447f3d7afc Adjustments: Equalize's choices stay with their document, and a string selectedAreaOnly is not exported
Saving an action whose Equalize step has `selectedAreaOnly: "true"` wrote
a bare Equalize event, although the command refuses the string. Export
now accepts only the boolean `true` for that setting.

The Equalize dialog records the document it was opened for. OK while
another document is active leaves the dialog open and runs nothing.
2026-11-02 08:40:36 -08:00
Fabio Lissi 180cbe651a Merge current main into Batch branch 2026-11-02 10:18:27 -06:00
David MannandClaude Opus 5.5 379fcd81ac Integration: collapse the Paste As Pixels fallback condition (clippy collapsible_if) (#10704)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 17:11:58 +01:00
David MannandClaude Opus 5.5 719786c234 Merge main into feat/history-snapshot-options
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 17:00:59 +01:00
David MannandClaude Opus 5.5 5814cc0131 Merge main into feat/ui-217-4-columns-unit
Status lines and the prefs count follow main: 9 of 183 preferences do nothing with Column Size.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 17:00:36 +01:00
David MannandClaude Opus 5.5 0d7f9b7272 Tests: the Camera Raw localization test stills egui's animations directly, the preference is gone
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 16:52:30 +01:00
David MannandClaude Opus 5.5 a3fb11949f Merge main into fix/svg-filter-cost-9409
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 16:52:28 +01:00