Scripts: removeAll cannot leave an image first in a group named Image Trace

textFrames.removeAll() and the removeAll() of a group's pageItems,
groupItems and compoundPathItems checked only clip groups whose mask
they release. Deleting the type or art below an image in an ordinary
group named Image Trace left the image first, so the group was read as
a tracing and the image dropped out of pageItems. Both now throw
"Only Image Trace can make a tracing" and delete nothing, checking the
whole set being deleted at once.
This commit is contained in:
dotCooCoo committed 2026-12-02 22:58:00 -08:00
1 parent 72e99d1c3b
commit 3d69c8d49a
5 files changed
+73 -2

No files matched your search

+3 -1
View File
@@ -3246,7 +3246,9 @@ through `$`:
delete the clipping path of a clip group or clipping layer also release that clipping mask in the same undo step,
so the object above the clipping path does not become the new clipping path; a deletion that leaves the clipping
path keeps the mask. When the released group is named `Image Trace` and an image would be left at its bottom, they
throw `Only Image Trace can make a tracing` and delete nothing. The `removeAll()` of a layer's or group's
throw `Only Image Trace can make a tracing` and delete nothing. `textFrames.removeAll()` and the `removeAll()` of a
group's `pageItems`, `groupItems` or `compoundPathItems` throw the same error and delete nothing when they would
leave an image at the bottom of an ordinary group named `Image Trace`. The `removeAll()` of a layer's or group's
`pageItems`, and of any `groupItems` or `compoundPathItems`, does not release a mask: it throws as described
above. Setting `width` or `height` scales the object along
the page's axes, so a rotated object then reads back the size that was set. `index` and `getByName` throw