File › Open with a PSD or PSB file's layers as objects now reads the
nvrt, thrs and post blocks of the PSD file format specification and
merges each such adjustment layer with the visible layers below it in
its group, changing their colors. Clipped to a layer, it changes only
that layer and the layers clipped to it. In a pass-through group with
nothing below it in the group, it changes what is below the group when
the group is merged.
Each channel is taken as an 8-bit sRGB value: Invert turns v into
255 - v, Threshold compares the Rec. 709 luminance with its level, and
Posterize maps each channel to the nearest of its evenly spaced levels.
The adjusted color is composited in the layer's blend mode at its
opacity and fill opacity, through its layer mask.
A hidden one is left out. One that layers are clipped to, one clipped
to another adjustment layer, one whose data can't be read and one
whose merge needs more memory than allowed are not applied and are
counted in the existing adjustment-layer warning. Other adjustment
kinds are still not applied.
Docs: docs/mcp.md, docs/target-app-parity.md.
A press on one part of a dimension now also checks its other parts for
a geometry effect, so an effect on an extension line keeps the drag
from moving the dimension (and from drawing the parts again without
the effect). In isolation mode, only art inside the isolated object is
compared with the dimension when the press decides between them.
The settings and cache imports could move up to 1 GiB a run while the
instruction budget charged only for the calls themselves. The bytes they
read or write now cost the run one instruction per 64 bytes, counted
over the whole run so that splitting a transfer into calls costs the
same. A get also pays for the bytes it copies into the module's memory
that the store didn't count, such as a setting answered from memory.
A storage call pays from the store's fuel and from the part of the
budget not yet handed out. The meter it gives the storage holds no more
bytes than those instructions pay for, so a read or write the run can't
pay for doesn't happen, and the run ends with "instruction budget". A
read or write past the 1 GiB still returns -7. Bytes beyond the current
slice are read or written only before the deadline and Cancel, and the
host checks the deadline and Cancel after every storage call, so a run
past either stops after the call instead of at the next slice.
The plug-in fuzz test now also makes writes of up to about 1 MiB on
small instruction budgets.
Docs: docs/plugins.md.
A group or layer whose raster effects are not all shadows and outer
glows (a blur, feather or inner glow) becomes one image of what it
draws, and the groups and layers in it make no images of their own. The
Safe Mode plug-in check still looked into every group with a raster
effect inside it, so a hidden blurred group there holding a plain symbol
instance with a plug-in effect in its art stopped the expansion. The
check now stops at such a group. Under shadows and outer glows the
members still expand on their own, so their groups are still checked.
The image a group's or layer's raster effect makes is drawn with
templates skipped, so it leaves out template layers, guides and ruler
guides with everything in them. The Safe Mode plug-in check still looked
into a template sublayer, so a plain symbol instance there whose symbol
art holds a plug-in effect stopped Expand Appearance of the layer. The
check now skips them as the renderer does.
The image a group's or layer's raster effect makes leaves out hidden
objects and everything in them, as the renderer does. The Safe Mode
plug-in check looked into every object of such a group, so a hidden
plain symbol instance whose symbol art holds a plug-in effect stopped
Expand Appearance of the group. The check now skips hidden objects
inside the group's image. The group itself still counts when it, or a
group around it, is hidden, since expansion still makes its image.
With no points or lines picked, a press within 8 pixels of what a
visible, unlocked dimension draws (its lines, arrowheads and label),
where it is the topmost object that can be edited, followed by a drag
moves that dimension as one undo step. A segment of the art as near
the press as the dimension's lines and label, or nearer, takes the
press instead, and a click there without a drag still picks a point.
The part grabbed follows the pointer: a linear dimension's line moves
as far across as the pointer moves, an angular arc moves as far as the
pointer moves away from or toward the vertex, and a radius or diameter
line turns about the center as the pointer turns, or toward the
pointer when grabbed at the center. The dimension keeps what it
measures and its link to the art. With Smart Guides on, a linear
dimension's line lands on the level of a parallel dimension line, as
when it is placed, and of two lines on one level the one nearer the
pointer along it wins. Isolation mode, clipping masks and locked artboards
apply as they do to a click; with a part of a dimension isolated, the
dimension is not dragged. A dimension that a geometry effect on it, on
one of its parts or on a group around it draws elsewhere is not
dragged, except in Outline view and on a layer whose Preview is off.
dimension.update takes `at: [x,y]`, which puts a linear dimension's
line through the point, gives an angular arc a radius of the point's
distance from the vertex (at least 12 pt), or turns a radius or
diameter line toward it. With Real-time Drawing off, a dimension.update
preview that names its dimensions outlines only those dimensions.
A dimension pasted into a document that had none now marks the
document as holding dimensions (Document::insert), so the Dimension
tool drags it like one drawn there and edits refresh it. Opening a
native file sets the flag from the objects it holds, which covers files
saved after such a paste.
Docs: docs/dimensions.md, docs/target-app-parity.md.
A linear dimension line placed near another dimension's line lands on its
level only when that line is parallel. Before, the check compared the two
directions only, so a long line at a slight angle passed it: with its first
end within the snapping tolerance, the new line landed on a level the other
line had already left, and the guide ran at an angle between the lines. A
line is now parallel when it moves off its level by no more than 0.000001 pt
across the span of both lines.
A level that would put the line more than 1,000,000 pt from its points is
passed over. Before, the tool took it, the preview failed validation and
was not sent, and a click committed the earlier preview position. The next
level within reach is taken instead, or the line goes where the pointer is.
The level guide also needs Smart Guides on when it is drawn, so turning
Smart Guides off before the next pointer move hides it.
The nonparallel case in the placement test now puts the pointer within
reach of the first line's end, so it fails without the parallel check, and
the guide test expects exactly one guide.
colored_revolve_faces_leave_no_alpha_holes_at_one_to_one compared each
representation only with its own 3x render, so a 60% opacity lost or
applied twice by SVG or PDF import passed at both scales. The test now
also reads the alpha inside the body: 153 within 3 levels with a fill
opacity of 60%, 214 within 3 levels with 60% gradient stops (front and
back faces at 60% each), and 255 when opaque.
docs/target-app-parity.md gets a line for the file.write report on a
File object's length, hidden and readonly and for the test that lists
every name the script host adds, with the tests that cover them. The
test's comment on vc no longer names another app.
Setting a File object's length truncates or pads the file, and setting
readonly or hidden changes it, but script.check reported no outside
category for those assignments. It now reports file.write and
filesWritten for them: plain and compound assignment, ++ and -- before
or after, and the property name as a string literal in brackets.
A new integration test lists every global and member the script host
adds to the JavaScript engine (the own properties of the global object,
of each object or function it holds and of each function's prototype,
compared with a plain engine) and fails when one has no row. Each name
that reaches outside the document has a probe script, and the test
checks that script.check gives it the expected outside id. vc is listed
as not checked: script.check reads scripts written for the reference
app's scripting, and what vc.run does depends on the command. The test
also checks that the checker lists every preprocessor directive the
host reads, through the new DirectiveName::ALL.
File object properties:
https://extendscript.docsforadobe.dev/file-system-access/file-object/
* refactor(cdr): depend on shared craft-cdr from craft-libs (#1665)
Replaces the local crates/cdr (vectorcraft-cdr) crate with craft-cdr
from storytold/craft-libs#2697 (storytold/craft-libs#778), keeping
VectorCraft's document/artboard/layer/shape mapping in crates/engine.
Co-authored-by: dotCooCoo <RobertLeeLW@gmail.com>
* build(cdr): pin craft-cdr to craft-libs main (75d179f8df)
* build(cdr): pin craft-cdr to craft-libs main (9b28b56bc7)
* docs(cdr): point CDR/CMX provenance and test paths to craft-cdr
---------
Co-authored-by: dotCooCoo <RobertLeeLW@gmail.com>
Part of #1210.
- `cargo xtask corpus --scripts` fetches 397 scripts and 1 included file
from 19 MIT and Apache-2.0 repositories at pinned commits into
corpus/scripts, each repository's license file beside its scripts.
xtask/script-corpus.txt lists every file with its size and SHA-256; a
download replaces the previous copy only when both match. One more
candidate is listed as excluded because it is over the 1 MiB limit for
one script. The fetch caps 64 MiB of scripts and 128 MiB of transfer,
refuses `..`, absolute paths, reserved names, case-fold collisions and
links, and holds a lock file while it runs.
- `cargo xtask corpus` takes at most one of --download, --affinity and
--scripts, and refuses other arguments with the usage text.
- `cargo xtask scripts --pass-rate [--report <path>]` runs each script in
a process of its own (the ignored `row` test in
crates/engine/tests/script_corpus.rs): a new document, 5,000,000
instructions, no dialog answers, file reads only in the script's
repository folder and a new folder of its own, file writes only in that
folder, stopped after 10 seconds. It writes a JSON report with the pass
rate overall, per repository and for scripts without dialogs or
windows, how many parse, and each script's outcome, with local folders
removed from messages. Script failures never fail the command, and
without the corpus it prints a skip line and exits 0.
A plain symbol instance does not expand on its own, so the Safe Mode
plug-in check skipped its symbol's art. When a group or layer around the
instance has a raster effect (its own, or on one of its fills or
strokes), the group's image draws that art, plug-in effect included, and
Expand Appearance committed pixels without the plug-in effect instead of
returning the Safe Mode error. The check now looks into every object of
such a group or layer, symbol art included.
Show the native point marker at the existing cut target, respecting consumer endpoint eligibility/canonicalization and current snapping/selection. Keep cut commands unchanged.
Closes#8655.
A handle drag kept the Alt and Cmd/Ctrl state it had before Space was
pressed, so pressing Alt or releasing Cmd/Ctrl during a Space translation
changed nothing until Space was released and the pointer moved. Both
modifiers are now read on every drag event. The Space translation still
keeps the accepted handle position.
The handle drag that keeps Space translation sent path.setHandle without
`symmetric`, so Cmd/Ctrl no longer mirrored the opposite handle on an
ordinary path. The drag now records the mirror with the handle it accepts
and sends it on every preview, so the opposite handle stays mirrored while
Space moves the anchor. Alt still takes priority.