231 Commits

Author SHA1 Message Date
David Mann b2db24400e Merge main at b1cfff9d3 into integration batch 10
Conflicts resolved as unions of both sides: codecs re-exports (PngRows + TiffBands), smart_cmds source imports
(main's source_surface_from_buffer and cache API with #8571's svg_source_image_in/convert_svg_source; main's
duplicate rendering import dropped), io flat.rs test modules (#8536's banded TIFF tests and main's PNG ones),
menus/invoke.rs (#8571's smart SVG intercept and main's layer.selectUnderCursor), state.rs (#8311's
type_box_overflow and main's type_insertion_style), the canvas_geom test keeps the is_finite guard, docs
status lines keep both change lists, i18n catalogs keep both sides' rows (hi.tsv: main's wording where both
added the same string).
2026-10-30 14:28:02 +01:00
FredApps 63637c4d80 Merge current main into trimmed integration, preserving exclusions and interpolation behavior 2026-10-29 21:31:18 +01:00
David Mann a3f8ef4816 Merge PR #8536: TIFF: images over 2^30 px open, decoded a group of rows at a time into the layer (#8169)
# Conflicts:
#	docs/file-format-parity.md
2026-10-29 21:06:41 +01:00
David Mann fefd90d576 Merge remote-tracking branch 'fork/integration-batch-10' into HEAD
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-29 19:16:12 +01:00
FredApps 255ecc81d0 Remove 21 requested PR contributions from the 108-PR integration
Retain 87 PRs. Reconcile overlapping integration fixes and update testing scope.
Removed: #7153 #7742 #5493 #9282 #3455 #9172 #3139 #3967 #4783 #5453 #8347 #1991 #3345 #4042 #4305 #4883 #4890 #5090 #6621 #5870 #5939.

Combined CI pending for this source; historical portable artifact is not applicable.
2026-10-29 18:49:17 +01:00
Khawar Zamman Wani a24e155a6f Merge upstream main into large TIFF fix 2026-10-29 22:39:27 +05:30
David Mann afacb057f7 Merge origin/main into pr-8571-fixup
Conflicts: svg.rs (main's bufread inflate and shared render helper, kept
with the PR's bounded raster path), psd_import.rs (the PR's vector
preview moved into main's smart_content), menus/invoke.rs (the SVG
intercept moved into main's split invoke_unguarded), rendering.rs and
the ui-egui import lists (main's explicit imports), Cargo.lock, docs
status lines (unions).
2026-10-29 16:38:24 +01:00
FredApps fd3a12dfde Merge approved PhotoCraft PR #3142: Read applied Sony RAW metadata and crop ILCE-6000 images
Port behavior and regression coverage into current modules; preserve current upstream behavior.
Integrate bounded Sony SR2 metadata decoding and ILCE-6000 image area; preserve newer bit-depth-aware camera profile application and explicit file crop precedence. Keep current parity counts and original metadata/crop tests.
2026-10-29 06:38:44 +01:00
FredApps c81347aaa8 Merge approved PhotoCraft PR #5493: Import Photoshop custom shape sets into the Shapes panel
Port behavior and regression coverage into current modules; preserve current upstream behavior.
Integrated bounded atomic CSH set parsing, unique shape/group naming and native Shapes panel import with inline-data authorization guards; preserved duplicate-name, inner-hole, malformed-second-record and preferences-reload regressions. Combined independent catalog additions and retained current parity metadata.
2026-10-29 05:47:45 +01:00
Khawar Zamman Wani 64422e7ef1 Merge main into save-for-web-webp 2026-10-28 21:09:35 +05:30
Khawar Zamman Wani 0ce7991aaa Merge origin/main into fix/8169-huge-tiff-open 2026-10-28 09:22:54 +05:30
David Mann 63e2c7d100 Merge PR #9031: fix(io): preserve Halftone Pattern smart filters in PSD/PSB
# Conflicts:
#	docs/file-format-parity.md
#	docs/gaps.md
2026-10-27 02:23:29 +01:00
David Mann 714b8f304d Integration: the reference application's Halftone Pattern keys HlSz/ScrT (#9031)
The PR read and wrote Halftone Pattern as `Sz  ` and `Ptrn` (enum `HlfT`:
`Dt  `/`Crc `/`Ln  `). The reference application's Filter Gallery uses `HlSz`
for the size and a `ScrT` enum (`ScrD` dot, `ScrC` circle, `ScrL` line), so a
Halftone Pattern saved there still opened as an opaque filter, and one we saved
lost its size and pattern there without a warning. The tests built their fixture
with the same keys as the code, so they passed either way.

Now the keys match, a default Halftone Pattern (HlSz 1, Cntr 5, ScrD) opens as
{size 1, contrast 5, dot} (fails before this commit), and descriptors with the
old keys stay verbatim. The docs no longer claim reopen checks in the reference
application.

Co-authored-by: denstu473 <63150090+denstu473@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-27 02:20:49 +01:00
Don Omondi c129dd50e0 Merge main and preserve original-format embedded vector save-back 2026-10-27 00:45:48 +03:00
jonathanwxh-cell 059940c993 Merge upstream main into the CSH shape import branch
Keep the custom-shape translations and the CSH import notes with main's newer format and gap status.
2026-10-26 09:50:13 +00:00
Khawar Zamman Wani 6fc599dea9 Merge origin/main into save-for-web-webp 2026-10-26 10:20:32 +05:30
Khawar Zamman Wani cdc3bdbd2f Merge origin/main into fix/8169-huge-tiff-open 2026-10-26 10:20:12 +05:30
Khawar Zamman Wani 08909ac143 Merge origin/main into save-for-web-webp 2026-10-25 21:25:58 +05:30
David Mann 38609e5615 Merge PR #8885: PSD: spot channels in Photoshop's polarity; PSDs from earlier PhotoCraft versions keep their ink
Merged with our fix-up branch pr-8885-fixup (8f6863f53) on the author's head 996b55eb4.

Conflicts resolved:
- crates/io/src/tiff_layers.rs: #9148's tiff_source (an empty LMsk gets Photoshop's 14 bytes)
  gives way to #8885's tiff_image_source, which writes the same bytes for an empty or short
  LMsk; #9148's test stays.
- crates/io/src/flat.rs: #8776's DDS alpha step and #8885's TIFF channel stamp both run.
- crates/io/Cargo.toml, Cargo.lock: #8402's zune dev-deps and #8885's tiff dev-dep.
- crates/io/tests/it/tiff_layers.rs, docs: unions; docs/scorecard.md kept as is, regenerated at
  the batch gate.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-25 16:28:00 +01:00
David Mann 14693eb085 Integration: merge main 528491f9a, resolve conflicts
- crates/engine/src/edit_cmds.rs: copy_mask keeps #3297's filter-mask target and takes main's
  clipboard `source` (#8945).
- crates/cms/src/lutfile.rs: #9183's shaper doc comment next to main's UTF-16 decode_text (#9129).
- contributors/people.toml, docs: unions.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-25 16:26:06 +01:00
David Mann 8f6863f536 Integration: a kept 1053 doesn't hide an earlier PhotoCraft's spot ink (#8885)
Earlier PhotoCraft versions kept the 1053 of a Photoshop file they opened
and wrote it back unchanged, while storing spot channels added there
straight. A transparent Photoshop document carries 1053 = [0], so a white
plate added to it in 0.16.0 or earlier sat behind a 1053, and the rule
read that file in Photoshop's polarity: the added spot opened inverted.

A 1053 that lists fewer channels (non-zero ids; 0 is the transparency's)
than the file has after its transparency now counts as kept, with the
PhotoCraft 1057 and DisplayInfo spot conditions unchanged. Planes the
kept 1053 lists stay in Photoshop's polarity (they are the Photoshop
file's own); the ones after them are read straight. Photoshop and this
version write one id per extra channel, so their files are unaffected.
Known limit, as before: channels reordered there, or as many deleted as
added, can't be told apart from the Photoshop file's own.

The earlier versions are 0.1.0 to 0.16.0, not 0.11.1: every release
since writes the same 1057 and straight spot planes without a 1053.

Co-authored-by: jasallen <615848+jasallen@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-25 16:22:13 +01:00
David Mann 4365c0537d Integration: merge main, resolve conflicts (#8885)
psd_import.rs keeps main's warning for an incomplete merged extra channel
next to the PR's Photoshop spot polarity. people.toml takes main's entries
plus jasallen's own. Docs take both sides' status lines and revision rows;
docs/scorecard.md is regenerated.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-25 16:07:44 +01:00
.CooCoo 09dc629b42 Codecs: save Amiga IFF (.iff) as 24-bit ILBM (#9080)
Photoshop reads and writes IFF; PhotoCraft opened Amiga IFF/ILBM files
but had no writer. Saving as .iff now writes a FORM ILBM with a BMHD and
a ByteRun1-compressed BODY of 24 bitplanes (red, green and blue, least
significant bit first), one plane row at a time. An image with alpha
also gets a mask plane (masking 1): alpha of 128 or more is opaque, and
when any pixel is not fully opaque the export warns that alpha is
reduced to on/off transparency. Gray is expanded to RGB, 16-bit and
float images are reduced to 8 bits, and images wider or taller than
65535 pixels are refused.

The reader also opens 24-bitplane ILBMs, so a saved file reopens with
the same pixels. A transparent color index in a 24-bitplane file is
refused as unsupported.

IFF leaves ASYMMETRIC_EXCEPTIONS, Save As offers Amiga IFF, and the
codecs README, file-format parity and G10 are updated.
2026-10-25 10:20:09 -04:00
David Mann 5c51830482 Merge PR #8877: PSD: recognise Photoshop's MTrn merged-transparency marker
# Conflicts:
#	docs/file-format-parity.md
2026-10-25 14:26:41 +01:00
David Mann c8847e84b2 Merge PR #9128: fix(#9098): preserve PSD byte order in layered TIFF text descriptors
# Conflicts:
#	docs/file-format-parity.md
2026-10-25 14:26:21 +01:00
David Mann 927ca567e0 Merge PR #9148: Layered TIFF: write Photoshop's global layer mask block (#9095) 2026-10-25 14:26:10 +01:00
David Mann a60b72483e Integration: merge main, resolve conflicts (#8658)
docs/file-format-parity.md: main's PSD row with the round-trip count
258/258. docs/scorecard.md: regenerated with `cargo xtask scorecard`.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-25 12:46:18 +01:00
David Mann 9a345bb6a8 Integration: the Photoshop corpus has 258 files everywhere (#8658)
The PR fixes the stale Photoshop corpus count (256 -> 258, the pinned
manifest xtask/photoshop-corpus.sha256 lists 258 PSDs) in
docs/development.md and docs/scorecard.md. The same stale number was
left in the io corpus test comment, docs/file-format-parity.md,
docs/roadmap.md ("258/256" round-trip floor) and ATTRIBUTION.md.

Co-authored-by: Simone <185146821+Lucenx9@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-25 12:42:43 +01:00
Khawar Zamman Wani 43a6b30354 TIFF: refuse an image too large for free memory instead of being OOM-killed (#8536 review)
Limits::banded() lifted the 2^30 px cap, and the only failure left was a
tile allocation error. Linux overcommits, so the tiles were allocated
anyway and writing them had the out-of-memory killer end the app and
every open document. A valid all-black Deflate RGB8 TIFF declaring
100,000 x 100,000 px (30 GB of pixels) is a few tens of MB on disk and
passes the bomb guard.

- io memory.rs: memory::available() is MemAvailable plus free swap on
  Linux, capped by the process's cgroup v2 memory.max (and those above
  it) and memory.swap.max; None elsewhere (Windows refuses past its
  commit limit, which the importer already reports). check_fits refuses
  when the need plus a 512 MiB reserve doesn't fit.
- tiff_to_document checks the layer's tiles plus the working copies of
  one group before allocating anything: "not enough memory to open this
  100000 x 100000 px image: it needs about 41.7 GB and 7.8 GB is free".
- codecs TiffBands::group_bytes gives the largest group; a single-strip
  file is one group (the whole image), which the check now counts.
- TiffBands puts Truncated before MorePages, as the whole-image decode.
- raster: try_write_interleaved reports a wrong length as
  AllocationError::LengthMismatch { expected, got }, not SizeOverflow.
- Comments and docs no longer name another editor.

Tests: io a_tiff_larger_than_free_memory_is_refused (300,000^2 black
RGB8, Linux) was OOM-killed in a 4 GB cgroup without the check; memory
unit tests for the policy and the meminfo/cgroup parsing; codecs
a_cut_off_page_of_several_warns_in_the_whole_image_order and
group_bytes_is_the_largest_group_handed_over.
2026-10-25 06:55:51 +05:30
Hector Villarreal ed9382d78a Layered TIFF: write Photoshop's global layer mask block (#9095)
A layered TIFF carried an empty `LMsk` block in its ImageSourceData
(tag 37724). Photoshop rejects that: it reports a problem reading the
layer data and opens only the composite. Photoshop writes 14 bytes there
itself (overlay colour space 0, colour 65535/0/0/0, opacity 50, kind 128).
The TIFF writer now uses those bytes when the model's global layer mask is
empty. PSD output is unchanged; an empty block is fine there.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-24 09:21:25 -06:00
Roni Balthazar 81d842d307 fix(tiff): preserve PSD byte order in layered TIFF text descriptors (#9098) 2026-10-24 13:37:31 +01:00
Khawar Zamman Wani 55a6ce34fa Merge remote-tracking branch 'origin/main' into fix/8169-huge-tiff-open
# Conflicts:
#	crates/io/src/flat.rs
#	docs/file-format-parity.md
#	docs/gaps.md
2026-10-24 13:37:01 +05:30
jonathnwxh 050ac592d4 Merge main preserving CSH, ASL and contour imports and translations 2026-10-24 15:57:08 +08:00
Khawar Zamman Wani 6a74abbe09 Merge remote-tracking branch 'origin/main' into save-for-web-webp 2026-10-24 12:04:57 +05:30
denstu473 fc29726a5d fix(io): preserve Halftone Pattern smart filters in PSD/PSB 2026-10-24 02:37:26 +02:00
Jason D e4acb3c5ca Merge PR 3 (now on current main) into PR 4
Brings split/tiff-channels-io at f53aa0b9 (PR 1 and PR 2 on main
1695f323). Resolutions:
- PsdExportOptions: main's read_linked_files kept; PR 3's
  photoshop_spot_polarity switch stays removed, as this branch does.
- crates/io/src/lib.rs: main's import_psd(), calling
  psd_to_document_decoded without the removed PsdImportOptions.
- docs: PR 3's and main's text, with this branch's PSD statements
  re-applied (dated 2026-10-23). docs/scorecard.md is regenerated next.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-23 09:10:08 -04:00
Jason D e5be3083a7 Merge PR 1 (codecs, now on current main) into PR 3
Brings split/tiff-extra-samples-codecs at e6fca054, which merged main
1695f323. Conflicts:
- crates/io/src/lib.rs: main moved PSD import into import_psd(); it now
  passes PsdImportOptions::default().
- PsdExportOptions (psd_export.rs, tiff_layers.rs): main's new
  read_linked_files next to this branch's photoshop_spot_polarity.
- docs: main's newer status lines and rows, with this branch's TIFF
  statements re-applied (dated 2026-10-23). docs/scorecard.md is main's
  and is regenerated after PR 2 is merged too.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-23 08:48:35 -04:00
Jason D 4e8605aea9 Merge current main into split/psd-mtrn-marker
Resolves docs/file-format-parity.md: main's newer status line and
revision rows, with this branch's MTrn entry on top (dated 2026-10-23).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-23 08:40:38 -04:00
David Mann 8d23a06eae Merge PR #6094: Fix legacy PSD point-text placement after font resolution 2026-10-22 23:40:19 +02:00
David Mann c436f61d53 Merge PR #7202: fix(atn): import a recorded Save As with its destination (#7102) 2026-10-22 23:40:18 +02:00
David Mann 018d3605b1 Integration: merge main (#6094)
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-22 21:13:36 +02:00
Khawar Zamman Wani 5b0edf4aeb Merge origin/main into fix/8169-huge-tiff-open
Main now builds each crate's integration tests as one binary (#8644), so this
branch's tests/tiff_bands.rs and tests/tiff_banded_import.rs move into tests/it/
and are registered in its main.rs.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01UmLxt3PeAHUmPEQjSjYqj6
2026-10-23 00:06:23 +05:30
David Mann 9487065314 Integration: merge main (one test binary per crate, #8644)
# Conflicts:
#	docs/file-format-parity.md
#	docs/gaps.md
#	docs/scorecard.md
#	scorecard/file_compat.toml
2026-10-22 19:55:06 +02:00
David Mann f5533e5d82 Integration: merge main into batch 6
Main merged #5940, #6472, #7838 and #7922 directly. Kept from the batch:
the snapshot/History-follow identity at the history limit (#5940,
c7ef3676a; main still had the 3-tuple HistorySpot) and the strokeless
shape at a 0 px width step (#6472, 962539607; main still added the
stroke). Main already carries the other two fix-ups (34c9d0ea4, dff8bfd0e).

Overlaps with main resolved:
- #5842 vs main's #5568: one path, apply_color, tool-gated as #5842
  has it, with #5568's float fill, kept fill opacity and lock skip;
  shape_fill_ui's duplicate foreground_changed/gesture dropped; #5568's
  tests run with a shape tool.
- #6230 vs main's #5180: one Type tool path click (path_target), no
  second type.attachToPath; vertical type does not start type on a path,
  as main has it; main's path_at/path_cursor and canvas arm dropped.
- #5452 moved the shape swatch to shape_paint_ui.rs: main's hex field
  (#6201) ported there.
- type_extra_cmds::with_text takes main's dpi form, pub(crate) for
  type_area_cmds.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-22 19:20:26 +02:00
Khawar Zamman Wani 4c80a98dff Merge remote-tracking branch 'origin/main' into save-for-web-webp
# Conflicts:
#	docs/file-format-parity.md
2026-10-22 22:36:41 +05:30
Khawar Zamman Wani 1fb9c61062 Merge remote-tracking branch 'origin/main' into fix/8169-huge-tiff-open
# Conflicts:
#	docs/file-format-parity.md
#	docs/gaps.md
2026-10-22 22:35:33 +05:30
aiongg ffa400c754 Keep tests correct and docs current with one test binary per crate
- gpu: the test modules share one GPU_LOCK, and timing and vector_mask
  take it too, so one process drives one wgpu device at a time.
- ui-egui: the wgpu tests in pattern_preview_canvas, adjust_preview_gpu,
  marquee_autoscroll and layout_perf take gpu_lock().
- affinity compound_limits: the child process selects its test by the
  module path (compound_limits::<name>); with --exact, the bare name
  matches no test and the child passes without running the check.
- xtask scorecard reads crates/io/tests/it/corpus.rs.
- Docs and comments name the new test paths and the --test it filters.
2026-10-22 16:55:34 +00:00
David Mann 6d3092f243 Integration: merge main, resolve conflicts, JPEG Options docs and encoder test (#7883)
Merges main (8f09d122d). Conflicts: the replay_save doc comment (main added
file.export.exportAs replay) and the status lines and history rows of
docs/file-format-parity.md and docs/gaps.md; both sides kept.

The docs called FILE-215-19 done and said only Save As and Save a Copy ask.
Photoshop's JPEG Options also has Matte, the progressive scan count
(Scans 3-5) and the size preview, none of which is offered, and Baseline
Optimized writes the same file as Baseline for RGB (4:2:0). The row is now
partial with those gaps named, and the docs say File > Save asks too.
docs/scorecard.md is regenerated.

Adds jpeg_options_ui::tests::the_answer_reaches_the_encoder. Every UI test
used a fake exporter, so dropping `opts.encode.jpeg_format` from
ExportSettings::io_options (the desktop and web save path) left them all
green; this test writes a real JPEG through io_options and fails without it.

Co-authored-by: Michael Higgins <55243596+Higgs32584@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-22 15:45:30 +00:00
David Mann b526378de4 Integration: 32-bit Hue/Saturation with Photoshop's saturation factor, finite at lightness 1 (#5781)
The 32-bit branch cut the slider to floor(|s| * 255) / 255, which only matches
Photoshop near 25 and 50 %: measured at every whole percent from -100 to +100
on a 32-bit document, Photoshop lowers by 1 - floor(|s| * 256) / 256 and raises
by 255 / (255 - floor(s * 254)) taken to 1/256 and capped at 32767/256 (201 of
201 exact). +100 gave 512x where Photoshop gives 128x, +90 9.8x for 9.44x.

It also kept the HSL saturation unclipped, which is inf at HSL lightness 1 and
0 and negative above 1: (2, 0, 0), red at +1 stop, turned NaN with any edit,
Hue +40 alone included, where Photoshop gives (2, 1.333, 0). The 32-bit branch
now scales the chroma around the lightness instead (same result in gamut),
on the CPU and in the shader, in whole numbers on both. Colorize clamps its
saturation before the 32-bit scaling, so a PSD's out-of-range value renders
the same on the GPU.

Tests (fail without this): thirty_two_bit_saturation_steps_match_photoshop,
thirty_two_bit_hue_saturation_keeps_bright_colours, the GPU parity
hdr_hue_saturation_bright_colours. Photoshop-oracle floor 188 -> 190 of 258,
measured after merging main.

Co-authored-by: Timothy Daly <100327160+timothydaly1@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-22 15:42:03 +00:00
aiongg 576ba0e02b Integration: track t12
# Conflicts:
#	contributors/people.toml
#	crates/compose/src/lib.rs
#	crates/compose/src/tests.rs
#	crates/engine/src/print_cmds.rs
#	crates/engine/src/print_cmds/tests.rs
#	docs/target-app-parity.md
2026-10-22 15:38:33 +00:00