Commit Graph
829 Commits
Author SHA1 Message Date
Hector VillarrealandClaude Opus 5.5 0f6524ffbd Copy CSS: write no border-radius for an unequally scaled rounded rectangle (CodeRabbit review on layer_css_cmds.rs:144)
Scaled 200 % across and 100 % down, a live rounded rectangle keeps one
radius per corner (r times the smaller scale), while its path, which is
what renders, has r·sx by r·sy elliptical corners. The rule wrote the
single circular radius. It now writes border-radius only when the path's
anchors are the ones the live radii draw (in any order, so a flipped
shape still writes its corners); otherwise none, as the module doc says.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-07 23:23:58 -06:00
Hector VillarrealandClaude Opus 5.5 13e7b0fe0e Copy CSS: test a rounded rectangle's border-radius after a 2x scale (CodeRabbit review on layer_css_cmds/tests.rs:165)
No test checked the copied border-radius after `shape.edit`'s
`transform` scales the live radii. With radii 12 and a uniform 2x scale
the rule now has to say `border-radius: 24px;`, so a regression in that
scaling fails the test.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-07 23:23:58 -06:00
Hector VillarrealandClaude Opus 5.5 1bdba8264d Copy CSS: write border-radius: 50% for a live ellipse (CodeRabbit review on layer_css_cmds.rs:147)
A solid live ellipse got the plain rectangle rule, so pasting it showed a
rectangle. It now writes `border-radius: 50%;` where a rounded rectangle
writes its radii, before the fill. The module doc lists it, and lists the
geometry of other shapes (live polygons, stars and lines, custom paths)
as not written.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-07 23:23:58 -06:00
Hector VillarrealandClaude Opus 5.5 d4622f78f2 Copy CSS: test a comment closer in a name and a layer with a drop shadow (FredApps review)
A layer named `a */ b` writes no `*/` outside its quoted image name and a
sanitised class; a layer with a drop shadow writes the same rule as
without it, with no shadow and no panic.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-07 23:23:58 -06:00
Hector VillarrealandClaude Opus 5.5 64fa77d5a6 Copy CSS: say exactly what the module writes and what it doesn't (FredApps review)
The module doc said it writes CSS "as Photoshop writes it", but strokes,
layer effects, CSS gradients, blend modes and fill opacity are never
written. List what each kind of layer gives, in order, and what is left
out.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-07 23:23:58 -06:00
Hector VillarrealandClaude Opus 5.5 38337c8c6d Copy CSS: write a live rounded rectangle's border-radius (FredApps review)
A shape layer that is still a live rectangle with rounded corners now gets
`border-radius` before its fill, as Photoshop writes it: one value when all
four corners are equal, else top-left, top-right, bottom-right,
bottom-left, in px. Sharp rectangles write none.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-07 23:23:58 -06:00
Hector VillarrealandClaude Opus 5.5 fc49818c58 Copy CSS: place paragraph text at its box and give it a size (CodeRabbit review on crates/engine/src/cmd/layer_css_cmds.rs:78)
Every type layer was written like point text: no width or height, placed at its first pixel.
Photoshop 2025 writes paragraph text differently. For a 200 × 120 box at (60, 40) whose two
lines span 156 × 51 px it writes `left: 59.937px; top: 36.948px; width: 156px; height: 51px;`:
placed at the box (within a few px, from its font metrics), moved down by an explicit leading
(36 px gives `top: 72.948px`), and sized by its text rather than the box (centred "Hi" in the
same box: `width: 19px; height: 17px;`). Do the same; point text keeps its position only.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-07 23:23:58 -06:00
Hector VillarrealandClaude Opus 5.5 fc66229188 Copy CSS: escape layer and font names in quoted values (CodeRabbit review on crates/engine/src/cmd/layer_css_cmds.rs:73)
A `"` in a layer name ended `url("…")` early, a backslash started an escape, and a `"` in a font
family was turned into `'`, which names another font. Write each name as a CSS string the way
CSSOM serializes one (`\"`, `\\`, hex escapes for control characters). Photoshop 2025 writes
these names unescaped (`url("Say "hi".png")`); ordinary names come out exactly as before.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-07 23:23:58 -06:00
Hector VillarrealandClaude Opus 5.5 69305189f0 Copy CSS: start class names that begin with a digit with _ (CodeRabbit review on crates/engine/src/cmd/layer_css_cmds.rs:37)
A layer named "2nd Box" gave `.2nd_Box`, which isn't a valid class selector. Photoshop 2025
writes `._2nd_Box`: it puts a `_` in front of a leading digit and turns a hyphen into `_` like
the other punctuation ("-2x" is `._2x`, "my-box" `.my_box`). Do the same.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-07 23:23:58 -06:00
Hector VillarrealandClaude Opus 5.5 4cd60bc06b Layer › Copy CSS
Photoshop's Layer › Copy CSS puts CSS for the selected layers on the
clipboard. The new engine command layer.copyCSS writes each layer as a
class named after it (characters CSS doesn't allow become _): a type
layer's font size, family, colour, line height and alignment, a solid
fill or shape's background colour, or an image named after the layer;
then its opacity under 100 %, its absolute position and size (none for
type) and its z-index from the bottom, in Photoshop's format and order.
The Layer menu item copies the result to the clipboard.

Fixes #9372

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-07 23:23:58 -06:00
David Mann ed893ea812 Merge pull request #12188 from davidmann4/fix/11909-bg-eraser-tolerance-field
Background Eraser: Tolerance takes whole numbers 1-100 with an alert, bar tooltips (#11909)
2026-11-08 02:54:43 +01:00
David Mann 4a7d746c0a Merge pull request #11823 from davidmann4/fix/11812-brush-opacity-minimum
Brush: opacity minimum 1 % and "00" sets 100 % (#11812)
2026-11-08 02:49:28 +01:00
David Mann 9ac3fa22b2 Merge pull request #9280 from davidmann4/fix/crop-invalid-rect
Crop: refuse an invalid explicit rectangle instead of cropping to the selection (#9279)
2026-11-08 01:50:23 +01:00
David Mann 940b352ca0 Merge pull request #9256 from davidmann4/fix/scale-effects-bevel-texture
Scale Effects and Image Size scale Bevel & Emboss Texture's scale (#9254)
2026-11-08 01:50:08 +01:00
David MannandClaude Opus 5.5 4750447f23 Floor an imported brush's opacity at 1 % when it is selected
Importing an .abr with select picked its first brush without the 1 %
opacity floor, so a preset saved at 0 % showed 1 % but painted nothing
(#11812).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-08 01:03:17 +01:00
David MannandClaude Opus 5.5 6547fadccd Floor a restored brush's opacity at 1 %
A brush remembered at 0 % opacity (saved before the 1 % floor) read back
at 0: the options bar showed 1 % but strokes painted nothing. Restoring
now floors opacity at 1 %, like tools.setBrush (#11812).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-08 01:24:18 +00:00
David Mann 1d9c654b3a Merge remote-tracking branch 'origin/main' into fix/11812-brush-opacity-minimum 2026-11-08 00:57:07 +00:00
David Mann 49eabafbcb Merge pull request #11238 from NaufalDzz/layer-filter-find-layers
Select › Find Layers opens the Layers panel's Name filter (#10884)
2026-11-08 00:13:30 +01:00
David Mann 6d5254d319 Merge pull request #12134 from hectorviov/fix/atn-droplet-print-gradient-tool
Actions: map Create Droplet and cover the Gradient tool's recorded steps (#10710)
2026-11-08 00:01:17 +01:00
David Mann d438e97467 Merge pull request #10766 from yoriswind/codex/atn-menu-intent
Add five Classic Actions panel commands
2026-11-07 23:59:31 +01:00
David Mann 5d0c8ce8c3 Merge pull request #8140 from Tungtono/feat/psd-puppet-warp-2
PSD: Photoshop's Puppet Warp smart filter, drawn with the mesh the file stores
2026-11-07 23:29:51 +01:00
David Mann 0a184f4a60 Merge pull request #8261 from Korg1ch/fix/8230-fade-preview
fix(ui): live preview in the Fade dialog (#8230)
2026-11-07 23:24:45 +01:00
David Mann 6c9031da01 Merge pull request #10429 from hectorviov/fix/path-selection-chords
Paths: ⇧⌥⌘↩ intersects the path with the selection (#7726)
2026-11-07 23:22:16 +01:00
David MannandClaude Opus 5.5 b697d52ca0 Background Eraser: Tolerance takes whole numbers 1-100 with an alert, bar tooltips (#11909)
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 <[email protected]>
2026-11-07 22:42:13 +01:00
David MannandClaude Opus 5.5 3bc095040f Merge main into 11823
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-07 20:45:18 +01:00
8bf381f2d9 Find Layers: keep the Name text on every run path; no focus for a hidden filter row (#11238)
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 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-07 20:24:22 +01:00
5de6aa4e04 Merge origin/main into feat/psd-puppet-warp-2 (PR #8140)
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 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-07 20:18:37 +01:00
Hector VillarrealandClaude Opus 5.5 e1d7429266 Actions: Create Droplet steps follow a renamed loaded action, as Batch steps do (CodeRabbit review on steps_droplet.rs:59)
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 <[email protected]>
2026-11-07 12:39:36 -06:00
David Mann 0f0e76c44b Merge remote-tracking branch 'origin/main' into pr-11238
# Conflicts:
#	crates/ui-egui/src/panels/layer_filter_ui.rs
#	docs/control-protocol.md
2026-11-07 19:37:29 +01:00
David MannandClaude Opus 5.5 25b62801e5 Merge main into fix/scale-effects-bevel-texture
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-11-07 19:35:28 +01:00
David Mann b919607cd8 Merge main into #10445 2026-11-07 19:24:49 +01:00
yoriswind 99653a4626 fix(actions): preserve the Equalize dialog on recorded playback 2026-11-07 10:24:40 -08:00
David Mann f8ab0858e7 Merge pull request #9604 from dotCooCoo/feat/equalize-entire-image
Equalize: with a selection, choose the selected area only or the entire image based on it
2026-11-07 19:12:42 +01:00
David MannandClaude Opus 5.5 cd26d1f9d2 Merge main into fix/11812-brush-opacity-minimum
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-07 19:10:23 +01:00
David Mann 67e903786a Merge pull request #11710 from TrevorBrown-dev/fix/magnetic-lasso-composite-11686
Magnetic Lasso: the edge comes from the visible composite, not the active layer (#11686)
2026-11-07 18:59:02 +01:00
David Mann b9e8859f89 Merge pull request #11545 from TrevorBrown-dev/feat/artboard-options-bar-11385
The Artboard tool's options bar gets the iPhone 8/7/6 default size, a background control, the Align panel and the gear menu (#11385)
2026-11-07 18:56:12 +01:00
David Mann 7d18bc5217 Merge pull request #11675 from hnoerenberg/feat/reset-transform-smart-object-11662
feat: Layer > Smart Objects > Reset Transform (#11662)
2026-11-07 18:51:10 +01:00
Hector VillarrealandClaude Opus 5.5 67da143139 Actions: map Create Droplet; cover the Gradient tool's steps (#10710)
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 <[email protected]>
2026-11-07 10:55:16 -06:00
dotCooCoo e207210745 Merge main into feat/equalize-entire-image 2026-11-07 08:24:11 -08:00
55142c407d Merge main into #8261: Fade preview on main's layout, off the UI thread
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 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-07 17:08:19 +01:00
David Mann f3f1610750 Merge remote-tracking branch 'origin/main' into pr-10429
# Conflicts:
#	crates/engine/src/cmd/vector_cmds.rs
2026-11-07 16:03:16 +01:00
FredApps e1e2a48b71 Merge pull request #10947 from vangel76/fix/render-video-frame-cap-6103
Render Video: cap the total an animated GIF keeps staged (#6103)
2026-11-07 15:40:04 +01:00
Trevor Brown 5c49acf7c0 Merge remote-tracking branch 'upstream/main' into fix/magnetic-lasso-composite-11686 2026-11-07 09:39:38 -05:00
Trevor Brown dc20b80858 Merge remote-tracking branch 'upstream/main' into feat/artboard-options-bar-11385 2026-11-07 09:39:36 -05:00
Hartmut Nörenberg 76326721f0 Merge remote-tracking branch 'upstream/main' into feat/reset-transform-smart-object-11662 2026-11-07 15:33:24 +01:00
Trevor BrownandClaude Fable 5.1 d52290b05a Magnetic Lasso: the docs say when to rebuild the edge source and what a non-RGB document follows (#11686)
Co-Authored-By: Claude Fable 5.1 <[email protected]>
2026-11-07 09:26:44 -05:00
David Mann 67e3457b02 Merge pull request #10001 from indy2kro/feat/8064-psd-maximize-compatibility-param
Saves take maximizeCompatibility for a PSD/PSB's merged image (#8064)
2026-11-07 14:44:52 +01:00
David Mann e18900e5fb Merge pull request #10443 from hectorviov/fix/replace-color-add-subtract
Replace Color: Add to Sample and Subtract from Sample (#6280)
2026-11-07 14:44:38 +01:00
David Mann ae84be356a Merge pull request #10557 from hectorviov/fix/save-for-web-slices
Save for Web: show slices in the preview and export selected slices
2026-11-07 14:44:21 +01:00
David Mann adac9ca7cf Merge pull request #10549 from hectorviov/fix/drag-mask-to-layer
Drag a layer mask onto another layer or group to move it, ⌥ to copy it (#10485)
2026-11-07 14:43:04 +01:00