Recolor: recolor.apply with a color group keeps art linked to the group's global swatches

Art linked to a global swatch of the group that recolor.apply rewrites stays
linked when the swatch takes its row's new color: it shows that color at its
tint, and a later swatch.edit still reaches it. Before, the art took the new
color unlinked. With group, the reply adds relinked, the count of other linked
paints that followed the group's new colors.
This commit is contained in:
dotCooCoo
2026-10-24 17:46:15 +07:00
committed by bflatastic
parent 640ddbd4c0
commit 5100a52a12
4 changed files with 117 additions and 9 deletions
+4 -1
View File
@@ -1692,7 +1692,10 @@ the others turn by the same hue). `limitTo` snaps new colours to a swatch librar
`recolor.randomize {map, order?, saturationBrightness?, seed?}` shuffles or varies new colours; a row with
`exclude: true` keeps its colours. `swatch.editGroup {group, colors, rename?}` rewrites a colour group in one undo
step (art linked to its global swatches follows), and `recolor.apply` with `group` recolours the art and rewrites the
group together.
group together. Art linked to one of the group's global swatches stays linked when the swatch is rewritten with its
row's new color (the default without `groupColors` when the rows follow the group's order), so a later `swatch.edit` still
reaches it; the reply's `relinked` counts the other linked paints that took the group's new colors. Without `group`,
the swatch keeps its color and the recolored art is no longer linked to it.
```json
{"name":"run_command","arguments":{"command":"recolor.reduce","params":{"colors":2,"preserve":{"grays":true}}}}