Like the reference application, a click or drag on a layer with Lock
transparent pixels on erases to transparency and leaves the lock on.
Lock image pixels and Lock all still refuse. The live preview mixes
dabs back without the lock so it shows what the commit does.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The options bar's Tolerance field stores whole numbers in 1..100. A value
typed past the range becomes the closest one and, once the field is left,
an alert with OK says "An integer between 1% and 100% is required. Closest
value inserted." paint.backgroundEraser clamps tolerance to 1..100 and its
params doc says so. The brush chip, Limits, Tolerance and Protect
Foreground Color get the reference application's tooltips.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Measured in the reference application: in View > Pattern Preview the
Clone Stamp and Healing Brush carry a stroke on across the canvas edges.
Blur, Sharpen, Smudge, Dodge, Burn, Sponge, Color Replacement, Background
Eraser, Pattern Stamp and History Brush show "Symmetry and Pattern Preview
are not supported with this tool ... does not perform wrap-around" and
stop at the edge; Spot Healing stops at the edge too.
Keep the Healing Brush wrap (commit and live preview, through
periodic::stroke) and drop the wrap from the other tools: their commands,
WorkTiles' wrap tile, photocraft_paint::wrap and the canvas params go
back to main's code. Tests: the tiling checks stay for Clone Stamp and
Healing Brush; new tests check that the other tools' strokes, live and
committed, stop at the edge and that the canvas sends `wrap` only for
the two tools that wrap.
Co-Authored-By: VoiceLessQ <44067308+VoiceLessQ@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
CodeRabbit found three things after the last fix-up:
- `engine.execute` and action steps without `name` replied `selected: []`
while the panel listed the layers its kept Name text matches. `run` now
fills in the panel's Name text for every path, as the menu did.
- With Filter Options > Hide, Find Layers left a focus request that took
the caret once the row was shown again. In the reference application the
row stays hidden and showing it later does not focus the field, so the
request is only made for a drawn row.
- The control protocol said the selection never changes; the Name filter
deselects a selected layer it hides (#10879). The doc now says so and
describes each entry point and the reply.
Tests for the first two fail without the fix.
Co-Authored-By: NaufalDzz <NaufalDzz@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Conflicts: psd_import.rs (main's vector_preview field kept, the SmartObject
still built as a binding so pin_puppet_meshes runs), smart_cmds/rendering.rs
(main's JobCtx argument kept next to the PR's placed_puppet_params).
Co-Authored-By: Tungtono <Tungtono@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Also point the module comments at #10710's table: mapped events leave docs/atn.md's measured table (CodeRabbit review on docs/atn.md:1002).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Straighten Layer was offered wherever a ruler line existed, so its button was
live for every target and the command turned whatever it was pointed at: it
rotated and cropped the canvas on the Background, turned several selected
layers or a group, failed on a locked layer with `layer "..." is locked`, and
rotated pixels nobody could see on a hidden layer. The reference application
(#12033) keeps the button off for the Background, a multi-layer selection, a
group, Lock All and Lock Position, and answers a hidden target layer with its
alert and no change at all. The command's own `enabled` check now says the
first set, so the options bar, the CLI, the control channel and an action step
all agree about what is offered; the hidden layer stays enabled and is refused
by the command, before it reads anything for the edit, so a refused click
leaves the document, its History and the ruler line exactly as they were. The
states the ticket marks *not measured* keep today's behaviour.
In an Indexed Color or a Bitmap document Photoshop keeps no type layer: the
Type tool still lets you click and type and shows the text while editing, but
committing it leaves a selection in the shape of the glyphs and no layer, as
one history state named "New Type Layer", and paints nothing.
commit_here already made that result for the Type Mask tools, with
type.createSelection and removeLayer in the typing session's one step, so the
commit now runs it for a new Type tool layer in those two modes as well, and
names the step back after type.create's own label. The mode check is the
engine's (type_cmds::commits_as_selection) and not the type.create command's:
that command is the primitive the tools make their working layer with, on the
first click already with text in it while the placeholder preference is on, so
a mode branch there would leave nothing to type into.
Tests: cmd::type_indexed_mode_tests pins the commit in both modes (no type
layer, the selection the Type Mask of the same text makes, one state named
"New Type Layer", every pixel unchanged, one undo back), RGB, Grayscale, CMYK
and Lab at 8, 16 and 32 bit, the command's own role, and a refused conversion;
editing.rs pins the tool's commit and its cancel through the canvas' own
pointer_up, insert and commit.
Fixes#12041
Resolves the status-line conflicts in docs/gaps.md and
docs/target-app-parity.md (both sides kept) and the module list in
crates/engine/tests/it/main.rs.
Co-Authored-By: arjen <76012639+ArjenS-LA@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Create Droplet (CrtD) loads as file.automate.createDroplet for the form
the droplet plays the same way (a Folder destination with Override
Action "Save As"), plays, and saves back as recorded; subfolders, Save
and Close, custom naming, an error log or suppressed dialogs keep the
Photoshop step. The Gradient tool's Make + Set of a gradient fill layer
already map since #10771; a test now covers that recorded form. Print
stays a kept step: its two recorded steps would print twice.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Main moved the files this PR changed (engine/src/cmd/edit_menu_cmds/fade.rs,
ui-egui/src/canvas/filter_preview.rs, dialogs/filter_dialog.rs) and Fade now also
fades alpha channels and the Quick Mask. The preview is ported onto that:
- engine: fade_preview captures the blend (FadePreview) from the session; render()
blends it on a copy that shares the document's tiles, so only the faded area is
blended and rewritten (review: no whole-surface copy).
- ui-egui: the blend and the flatten run on the filter preview worker in the
desktop app, like every filter preview, and inline on the web.
- tests: the preview matches OK for alpha channels and the Quick Mask too; the
dialog test previews, cancels (document, history and Fade unchanged), then OKs
on both the worker and the inline path.
Co-Authored-By: Korg1ch <Korg1ch@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>