Commit Graph
11425 Commits
Author SHA1 Message Date
bazmarth 26ae488262 Merge remote-tracking branch 'origin/main' into feat/apply-color-to-selection
# Conflicts:
#	docs/ui-parity.md
2026-10-15 13:17:33 +00:00
bazmarth 7978cbc1ee Merge remote-tracking branch 'origin/main' into feat/polygon-corner-radius
# Conflicts:
#	docs/ui-parity.md
2026-10-15 13:17:31 +00:00
Vikram Bhaskaran 2af160d65f Merge remote-tracking branch 'origin/main' into feat/iff-read
# Conflicts:
#	apps/photocraft-web/src/web.rs
#	apps/photocraft/src/services.rs
#	crates/codecs/README.md
#	crates/codecs/src/format.rs
#	crates/codecs/src/lib.rs
#	crates/codecs/tests/detect_caps.rs
#	docs/gaps.md
2026-10-16 00:17:24 +11:00
Omar Saidahmed 65ca7c1bbd remove unused deps and dead code 2026-10-15 09:00:20 -04:00
Marco Arnulfo 1b74873991 i18n: Frequency Separation… in the Serbian catalog (#1714) 2026-10-15 14:56:17 +02:00
Marco Arnulfo fa91c4804a i18n: Frequency Separation… in the Hungarian and Turkish catalogs (#1714) 2026-10-15 14:56:17 +02:00
Marco Arnulfo 4083eee2c5 Filter > Other > Frequency Separation (#1714)
A one-step setup of frequency separation for retouching: from the active pixel layer it builds a
"Frequency Separation" group right above it with a "Low Frequency" layer (Gaussian Blur at the
chosen radius, the same pixels Filter > Blur > Gaussian Blur makes) and a "High Frequency" layer,
High = (Source - Low) / 2 + 0.5 per colour channel on Linear Light, which composites back to the
source: within one level at 8 bits (as Photoshop's Apply Image recipe), exactly at 16 and 32 bits
for values in 0..1. One history step; the source layer is left as it was and High is targeted.

The command (layer.frequencySeparation, {"radius":0.1..1000=4}) gets the schema dialog for its
radius and sits in Filter > Other after Color to Alpha; it is no filter.* command because it adds
layers rather than filtering the target (no mask or channel routing, Fade or Last Filter). It is
refused on non-pixel and empty layers, a targeted channel or mask, and in CMYK and Lab, where
Linear Light does not rebuild the source.
2026-10-15 14:56:08 +02:00
mroxso 33372650fe Merge branch 'storytold:main' into main 2026-10-15 14:55:11 +02:00
David MannandClaude Opus 5.5 caa28cb7ab CI: run only the font tests in the craft-fonts pass (#6120)
The pass reran every test in the workspace, but CRAFT_FONTS is only read in photocraft-text,
photocraft-io (svg) and photocraft-ui-egui. The build selection stays the same (the disk warning
above still applies); a nextest filter runs those three packages' tests: ~3,800 of ~8,900.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-15 14:41:12 +02:00
David MannandClaude Opus 5.5 e22c4ec7ab CI: run the tests with cargo nextest (#6117)
cargo test runs the ~258 test binaries one at a time; nextest runs them in parallel. Its new `ci`
profile stops at the first failure (a red PR frees its runner early), fails a test that hangs for
10 minutes instead of letting it hold the runner, and repeats every failure at the end of the log;
the GPU test group still applies. Same --workspace --locked --features heif selection, so the build
is unchanged. Doctests stay on cargo test --doc.

postscript_only_style_shows_actual_subfamily relied on another test in the same process having
started the font scan; under nextest it runs alone, so it starts the scan itself (as #2933 does).

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-15 14:40:15 +02:00
David MannandClaude Opus 5.5 9660dca263 CI: run clippy, layers and scorecard checks before the tests (#6119)
They take about 1.5 min together but ran after all the test passes, so a clippy failure (15 s)
showed red only 41-48 min into the job. Same steps, reordered: no cost on a green run.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-15 14:22:13 +02:00
David Mann 4a228a28f9 Merge remote-tracking branch 'fork/fix/snapshot-followups' into fix/snapshot-followups 2026-10-15 14:18:39 +02:00
David MannandClaude Opus 5.5 71deb68582 Merge branch 'pr3567new' into fix/snapshot-followups
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-15 14:18:23 +02:00
David MannandClaude Opus 5.5 2ab37e7e55 Scorecard: regenerate after merging main (TOOL-214-12 done, #5846)
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-15 14:06:00 +02:00
David MannandClaude Opus 5.5 ad273614f8 History Options: keep unrecorded visibility, roll back exactly in non-linear history
- With Make Layer Visibility Changes Undoable off, Undo, Redo, a History row and
  non-linear Delete keep every layer's visibility as the user left it.
- History::rollback takes the last record back exactly (also the later states it
  moved in non-linear history); Transform Again on a copy, New Frame from Layers,
  the Free Transform take-back and an abandoned Alt-drag copy use it via
  Session::rollback. The Alt-drag fold keeps the moved later states.
- Non-linear Delete reaches a later (dimmed) state; the History panel lets those
  rows be dragged onto the trash.
- Reword the snapshot-option comments: they come with #3634.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-15 14:02:57 +02:00
David MannandClaude Opus 5.5 42e831fa30 History Options: no duplicate snapshot when saving an unchanged document (#2966)
Automatically Create New Snapshot When Saving adds no row when the document
is unchanged since the snapshot the previous save added (and that snapshot
is still there), so Ctrl+S on a clean document doesn't stack duplicates.
The new snapshot's tiles are trimmed against the history budget at once,
and its memory cost is documented: snapshots count against History & Cache
by dropping the oldest states, but are never dropped themselves.

Tests: the engine dedupe, and the desktop save path (a save adds one, Save a
Copy none, a background save finishing on another document snapshots the
document it saved). The purge test from main deletes the first snapshot so
it measures only the snapshot it takes.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-15 14:00:07 +02:00
David MannandClaude Opus 5.5 8435a4586f History Brush source: snapshot sources, size check, purge and budget fixes
- Edit > Purge > Histories resets a state source to the default instead of
  leaving every document without one (History::clear).
- The pinned source state counts against the history byte budget first; the
  newest states fill what remains, so trimming stays within max_bytes.
- The History Brush and Fill > History refuse a source of another canvas size
  (after Crop, Canvas Size or Image Size) instead of painting shifted pixels.
- Snapshots can be the source: history.setSource {snapshot}, a source column on
  snapshot rows, HistorySource::State|Snapshot in the engine; deleting the
  snapshot leaves no source, Purge > Histories keeps it.
- paint.historyBrush and Fill > History take History panel rows for `state`
  (redo rows included), as history.setSource does, and accept `snapshot`.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-15 13:58:10 +02:00
David MannandClaude Opus 5.5 e23840f516 History panel menu: review fixes (floating steps, cleared-state memory, clean undo, New Snapshot)
- Step Backward in the History panel puts a floating selection back like Edit > Undo; Step
  Forward and Edit > Redo put it back and step instead of dropping it first (which recorded a
  Move and wiped the redo states); with nothing to step to the piece keeps floating.
- Memory figures and the byte budget count the states Clear History keeps for its undo.
- Undoing Clear History keeps a saved document clean.
- New Snapshot... in the panel menu runs history.newSnapshot.
- Tests: Clear on one document leaves the others alone, and each fix above.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-15 13:57:54 +02:00
Vikram Bhaskaran 6b7f08fcd6 Merge remote-tracking branch 'origin/main' into fix/5258-psd-open
# Conflicts:
#	crates/io/src/lib.rs
2026-10-15 22:56:14 +11:00
Vikram Bhaskaran 26cdfae307 IO: route declared Photoshop extensions through is_psd_input.
The helpers-only use made cargo clippy -p photocraft-io --all-targets
flag is_psd_input as never used; import_stages now calls it for the
extension branch, keeping the magic-first order that lets an Affinity
file renamed .psd stay with the Affinity loader.
2026-10-15 22:55:05 +11:00
Muhammad Saad f116c3230a Retouch: guard every stroke command, not only Pattern Stamp (#6110)
Pattern Stamp was the only retouch command that refused a stroke it could not
render. Clone Stamp, Healing Brush, Spot Healing and Remove all reach the same
dense conversion: coverage is accumulated in tiles, but dense_coverage()
materialises the whole bounding box, and the retouch paths read a Region over
that box for every channel. The box comes from the stroke's own points, which
are validated against MAX_COORD rather than the document, so it is not bounded
by the canvas. Both allocations go through the infallible vec!, which aborts
instead of returning an error.

With the guards now shared in retouch_cmds, apply them to the rest:
reject_huge_stroke before anything is rendered, and reject_bounds before the
dense region read where the command can return one. spot_heal_surface returns a
Rect, so Spot Healing charges the stroke in the command; Remove builds a list,
so each stroke is charged as it is parsed.

The allowance is unchanged, so no stroke that worked before starts failing.

Test: every retouch stroke refuses the oversized box, leaves the pixels alone,
and still accepts a stroke across the whole canvas.
2026-10-15 15:47:38 +04:00
David MannandClaude Opus 5.5 15753a69a1 History snapshots: follow-ups to #3567 (#6087)
- New Snapshot dialog: snapshot_dialog::open returns None while a Free
  Transform is open, so the Alt-click (and any other caller) no longer
  opens it under the transform box.
- A cleared Name in the dialog now takes the next default snapshot name
  instead of failing; the engine still rejects an empty name from agents.
- Snapshot thumbnails remember the snapshot document they show: a
  document reopened with the same id, or a refreshed first snapshot,
  gets a fresh thumbnail, and closing a document drops its thumbnails
  (sync_views). Pruning deleted snapshots runs once per panel draw,
  not per row.
- Session::refresh_type_layers also re-renders the type layers of the
  first snapshot (the document as opened), so returning to it keeps the
  served font.
- Housekeeping: snapshot_rows doc comment, the dialog's select-all uses
  field_tab::select_all, and the New Snapshot block no longer splits
  the Free Transform comment from its code. cargo fmt also reformats two
  test lines in rotate_view.rs and wheel_nav.rs that came in with main.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-15 13:43:18 +02:00
Gustavo Ziger 0684657a92 Merge main into feat/zoom-animation-566 2026-10-15 08:35:41 -03:00
jonathnwxh de095be6cb perf(compose): track the last covered sample to reset empty sums 2026-10-15 19:26:04 +08:00
David MannandClaude Opus 5.5 cb8f2808d2 Merge origin/main into feat/history-snapshot-options
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-15 13:23:37 +02:00
jonathnwxh 0e431aaf6d fix(compose): keep empty blur tails empty before effect noise 2026-10-15 19:21:26 +08:00
jonathnwxh c4f383e190 test(compose): reproduce noise in empty effect blur tails 2026-10-15 19:18:39 +08:00
David MannandClaude Opus 5.5 5f795b0b37 Merge main into fix/history-options
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-15 13:11:16 +02:00
itsF4LCON 862fa0c9a8 Merge remote-tracking branch 'upstream/main' into feat/2966-snapshot-dialog
# Conflicts:
#	crates/ui-egui/src/panels.rs
#	docs/control-protocol.md
#	docs/ui-parity.md
2026-10-15 13:08:02 +02:00
syrrevshin4202-prog b980a40eed docs(ar): add beginner guide, tool examples and glossary
Add three linked Arabic help chapters with a card exercise, 15 tools and
28 terms. Keep current English UI labels for navigation and distinguish
editable projects from exports. Add RTL language wrappers and link the
chapters from the book, repository README and Arabic localization notes.

Validated with mdBook 0.4.52 and 74 local link/anchor checks.
2026-10-15 14:05:04 +03:00
David Mann ce5af000f2 Merge remote-tracking branch 'origin/main' into fix/history-panel-menu 2026-10-15 13:03:07 +02:00
David Mann 2bc49845a7 Merge remote-tracking branch 'origin/main' into fix/history-brush-source 2026-10-15 13:03:04 +02:00
Hasan 3b97dc4f2c Free Transform: picking another tool or layer applies a background commit (#5665, #5667)
In the desktop app Free Transform commits as a background job. When
another tool or layer was picked, end_if_left committed the box (#1400)
and then, seeing it still open while the job ran, cancelled it as if
the engine had refused the commit. Cancelling the job threw the
transform away: an existing layer went back to where it was, and a
dropped file was taken back, or, after New Layer, kept untransformed
because its place was no longer the latest step (#5667). The tests
commit inline, so they never saw it.

A commit still running now ends the session when it lands. If the
engine refuses it then, the box ends as Esc would, as an inline
refusal already did.

A transformed place folds into its Place Embedded step only when the
place is the step just before the transform. After New Layer, the
place, the new layer and the transform stay three steps, instead of the
new layer being folded into the transform and labelled Place Embedded.
2026-10-15 11:02:37 +00:00
itsF4LCON d065c874e5 Merge remote-tracking branch 'upstream/main' into fix/5996-help-search-mnemonics 2026-10-15 12:58:26 +02:00
itsF4LCON 248ba66057 Merge remote-tracking branch 'upstream/main' into fix/6015-marquee-fixed-size 2026-10-15 12:58:24 +02:00
adrdsouza c71e3f94ad fix(psd): refine legacy point anchors after font resolution 2026-10-15 16:27:30 +05:30
syrrevshin4202-prog e6bc2d1472 i18n(ar): stage Arabic catalog and review checklist
Add 348 original Arabic entries for menus, tools and New Document with
catalog and staging regression tests. Keep Arabic outside LANGUAGES
until bidi, caret and font delivery are verified. Document native font
fallback and remaining validation; no shipped coverage change.
2026-10-15 13:52:41 +03:00
nrq6993-a11y 8be3269fe1 style: rustfmt 2026-10-15 13:51:51 +03:00
David MannandClaude Opus 5.5 0a83e25489 WIP: History snapshots: follow-ups to #3567 (#6087)
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-15 12:48:20 +02:00
nrq6993-a11yandCursor 579e0f1d28 Workspace: list saved workspaces in Window › Workspace and the switcher (storytold/photocraft#5610)
Saved workspaces get dynamic Window › Workspace items after the presets
(window.workspace.saved.<index>), checked while current and selecting
the workspace; the top-bar dropdown lists them after the presets.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-10-15 13:40:49 +03:00
nrq6993-a11yandCursor b18f6ea008 History panel: scroll to the current state on document change.
Fixes storytold/photocraft#5909 when new edits land off-screen in a short dock.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-10-15 13:40:39 +03:00
David Mann d6b6b52c74 Merge remote-tracking branch 'origin/main' into fix/5692-tsl-off-blend 2026-10-15 12:12:39 +02:00
David Mann 43d8572c9f Merge remote-tracking branch 'origin/main' into feat/tool-214-12-shape-feather
# Conflicts:
#	docs/scorecard.md
#	docs/ui-parity.md
2026-10-15 12:12:20 +02:00
David Mann 9e532faa3a Merge remote-tracking branch 'origin/main' into fix/5559-bitmap-dialog
# Conflicts:
#	crates/ui-egui/src/i18n/cs.tsv
#	crates/ui-egui/src/i18n/de.tsv
#	crates/ui-egui/src/i18n/el.tsv
#	crates/ui-egui/src/i18n/es.tsv
#	crates/ui-egui/src/i18n/fr.tsv
#	crates/ui-egui/src/i18n/hu.tsv
#	crates/ui-egui/src/i18n/id.tsv
#	crates/ui-egui/src/i18n/it.tsv
#	crates/ui-egui/src/i18n/ja.tsv
#	crates/ui-egui/src/i18n/ko.tsv
#	crates/ui-egui/src/i18n/nl.tsv
#	crates/ui-egui/src/i18n/pl.tsv
#	crates/ui-egui/src/i18n/pt-br.tsv
#	crates/ui-egui/src/i18n/ru.tsv
#	crates/ui-egui/src/i18n/sr.tsv
#	crates/ui-egui/src/i18n/tr.tsv
#	crates/ui-egui/src/i18n/uk.tsv
#	crates/ui-egui/src/i18n/vi.tsv
#	crates/ui-egui/src/i18n/zh-hans.tsv
#	crates/ui-egui/src/i18n/zh-hant.tsv
2026-10-15 11:55:20 +02:00
David MannandClaude Opus 5.5 24a86a3f6f Image: Bitmap dialog with Output resolution and per-method settings (#5559)
Image > Mode > Bitmap now opens a dialog laid out like Photoshop's:
Resolution (Input, read-only; Output in pixels/inch or pixels/centimeter),
Method (50% Threshold, Pattern Dither, Diffusion Dither, Halftone Screen,
Custom Pattern) with a pattern picker enabled for Custom Pattern, and the
Halftone Screen settings (Frequency, Angle, Shape) shown only for that method.

The image.mode.bitmap command gains `resolution` (resamples to the Output
resolution keeping the print size, then sets it) and the `customPattern`
method (threshold map ranked from the pattern's lightness, tiled from the
top-left). The halftone screen is laid out at the output resolution. The
live preview keeps the canvas size.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-15 11:54:35 +02:00
David MannandClaude Opus 5.5 869b2556d3 io: drop the Photoshop version from the gradient opacity comments (#1954)
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-15 11:49:50 +02:00
PanPDXandClaude Opus 5.5 566a501bb8 fix(ui): keep the Type tool's path pointer in step with what a click does
Over existing type that sits on a path, the pointer showed the area or
path-type cursor while the press edited the type layer, because the
hover never asked the hit test pointer_down uses. The hover now goes
through hover_path_target, which shares hit_layer with the press and
keeps Photoshop's plain I-beam there (a shifted press still starts new
type on the path). hit_layer and layout borrow the document instead of
cloning it, since the hover calls them; the type hit only runs once a
path is under the pointer.

A one-anchor subpath is no longer an on-path target (type.attachToPath
rejects it, so the cursor promised type it could not place), and paths
over 4096 anchors are skipped so the per-frame segment hit stays cheap;
pointer and click use the same rule.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 02:49:21 -07:00
Skyfuller1303 e22a9baedc fix: preserve tiny pattern scales and account for cached tiles 2026-10-15 11:47:12 +02:00
David Mann 0335545ebe Merge remote-tracking branch 'origin/main' into fix/4381-psd-frame-stroke 2026-10-15 11:42:42 +02:00
David MannandClaude Opus 5.5 f8e6d9666a PSD: Frame layers keep their stroke (#4381)
A Photoshop Frame is a group whose record carries the frame outline as a
vector mask and its Properties > Stroke as a shape-style `vstk`. We dropped
that `vstk`, so frames lost their stroke. `Group::frame_stroke` now holds it:
read from and written back to PSD (byte-identical while unchanged), saved in
.pcraft, and drawn along the vector mask above the frame's content by the CPU
compositor and the GPU planner.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-15 11:42:40 +02:00