At plug-in API level 2 a command may give `menu`: `{"path": [...],
"after"?: label}`. The menus list it in that menu, right after the
built-in item `after` names (either label of an item that switches
between two), or at the end of the menu, with the plug-in's name in
parentheses after its label. Keyboard Shortcuts, the command palette
and `command_list` list it under that menu, and `plugin.list` gives its
`menu` with `after` escaped.
A manifest may name 14 menus of Edit, Object, Type, Select, Effect and
View. File, Window, Help, the application menu and the submenus that
list files, fonts, panels or plug-ins are refused when the module is
installed, as is any other `menu`, an `after` that is not 1-64
printable characters and a repeated `menu`. A command whose label with
the plug-in's name reads like a built-in item or submenu of that menu,
or like a command a plug-in with a lower id places there, stays in its
plug-in's submenu, and `plugin.list` and `plugin.inspect` mark it
`placed: false`. The desktop app and `vectorcraft-cli` give the same
result. Commands of several plug-ins at one spot are listed in plug-in
id order and then manifest order. A plug-in whose commands are all
placed elsewhere is a single item in Object › Plug-ins. At API level 1
the key is ignored, repeated or not.
wat::module and wat::sectioned give a module at least one page of
initial memory, so the first vc_alloc block does not start at 0, which
the host refuses. wat::with_field adds its field after a module's $name
when the module has one, so a named module stays valid WebAssembly text.
With a twist, a band cuts each edge into pieces whose cut corners lie on
the art's curve, but the smoothed mesh normals and the 60 degree crease
test were worked out on straight chords between the edge's corners. On
a curved outline the normals then described quads other than the faces
the mesh holds. The corner rule is now one function, cut_corner, which
curved_band and smoothed_rows both use, so each piece's smoothed normal
comes from the quad that is built. Straight and uncut edges are as
before.
The test a_twisted_round_bevels_smoothed_normals_follow_its_curved_pieces
checks that each smoothed corner of a twisted, rounded bevel on a circle
is the mean of the normals of the two faces that meet there, with and
without perspective.
- PageItem.editable is false for art on a locked artboard, as remove()
refuses it. A group on a locked artboard is measured once for all its
members.
- The lists of page items are kept for the last four documents read, so
a script that reads two documents in turn does not walk each one again
on every index.
- crates/engine/src/store.rs: each stored plug-in's load reports how
much of its file it read. What a failed read did not read goes back to
the 512 MiB the stored plug-ins may read together, on every platform;
the permission check before the loads is removed. A file that what is
left does not cover, but would if earlier reads failed, waits until
those reads are done, so the files still install in file-name order.
Disabled files and file stamps are taken once, when the store is
listed. A file's content is compared with its loaded module at install
only when the file was modified less than 2 s before the store was
listed; the clock is read only when a file was listed. A grant the load
removed goes back for a later file with the same id only when the
grants file has no entry for the id, and each install turn reads the
grants file once. At quit, a stored load takes no locks and a folder
load does not wait for the store's turn or for another window that is
changing the plug-ins.
- crates/engine/src/cmd/plugin.rs and crates/plugins/src/registry.rs:
when a folder load turns off the file of a plug-in disabled by its id,
the disabled list is saved in the same install turn, not only when the
load ends. A change made in another window while the folder is being
listed is one the load does not undo.
- crates/ui-egui: an export and File > Open install the plug-ins still
loading before they look up the formats, and a control request waiting
for the loads no longer asks for a frame of its own.
- crates/engine/src/file_access.rs: `ScopeHandle::capture` is as on
`main` again. The new `ScopeHandle::capture_now` keeps the process's
automation roots in force at capture time, and only the Additional
Plug-ins Folder's per-file check uses it.
- New tests: a stored file replaced with one of the same length and
modified time while it loaded is skipped; another window's
`plugin.list` reports a folder still loading as loading; a grant given
elsewhere after the load removed one is kept.
- docs/plugins.md: a module whose read and load take 10 s or longer is
skipped also when it would have finished later, and at quit the app
waits for the modules already loading, for at most 10 s. File > Open
waits for the loads. The Loading
paragraph and the docs/mcp.md lines are rewrapped.
Preferences › General › Display Print Size at 100% Zoom is now on by
default, also for saved preferences that predate the key; a saved
choice to turn it off stays off.
A document floating in an OS window of its own counts 100% from the
display that shows that window. A move of the main window leaves the
zoom of floating windows alone, and a window that moves to a display of
another density keeps its zoom percentage.
The desktop app lists the displays once a second while the preference
is on and reads their physical sizes on a background thread when the
list changes; the UI thread does not wait for the X11 or Wayland
queries. RandR is asked for its version before the CRTC and output
queries. A reading that fails is tried again after 10 seconds, and the
displays are read again a minute after the last reading, so a display
replaced by one that lists the same gets its own size.
The Navigator's zoom field, slider and thumbnail clicks count the zoom
from Actual Size, as the status bar's zoom field does; before, a click
on the thumbnail with the preference on changed the zoom. ui.inspect
gives screenPpi and printPpi. The preference's description is updated
in every catalog.
With Preferences › General › Display Print Size at 100% Zoom on, 100%
took 96 screen points to an inch on every display, so a ruler held to
the screen measured more or less than the document said on any display
of another density. The desktop app now measures the density of the
display that shows the main window from the physical size the system
reports (CGDisplayScreenSize on macOS, the monitor's raw DPI on
Windows, the RandR output's millimeters on X11, the wl_output geometry
on Wayland), and measures it again when the window moves to another
display, where every document window keeps its zoom percentage so the
art keeps its physical size. Actual Size, the zoom field, the zoom
stops and the tab titles count 100% from that density. Where the
system reports no size, or a size no display has (zero, an aspect
ratio given as the size, or axes that disagree), an inch stays 96
points, as on the web.
Zoom stepping takes the density from the app instead of a
process-wide flag, and the last zoom stop in each direction stays in
the zoom range.
encoded_len reports the bytes it decoded and stops at what the budget still
pays for; the skip charges them (one operation per 256 bytes). read_rows
charges what it decoded also when the data fails part way.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
A filter's `notice` made only of default-ignorable characters that the
host keeps as they are (U+034F combining grapheme joiner, the Hangul
fillers, variation selectors, invisible operators, tags and the like) was
accepted and showed an empty status message. Such a notice now refuses the
output, as one of only zero-width characters already did. The visible
character must also fall within the part the status bar shows: a notice
whose visible text comes after the 200-character cut is refused instead of
showing only the ellipsis. Text with a visible character keeps these
characters, and its bidirectional ones are still escaped.
A painted live effect that returned `notice` was refused and drew its
input unchanged, while the docs said the key is ignored. The painted
decoder now ignores a top-level `notice` and still refuses any other
unknown top-level key; the message and its catalog rows say so.
A plug-in step of an action or a `command.batch` now shows its notice in
the status bar too; when several steps report one, the last shows. The
run's result carries `pluginName`, the name of the plug-in that ran, next
to `notice`, so the status bar names the right plug-in even when a later
step of the batch removes or replaces it. The `plugin.run` and plug-in
command params text lists the new keys.
Docs: docs/plugins.md, docs/mcp.md.
A length drag that changed the length and then came back to where it
started previewed the path again at its first length, so letting go
recorded an undo step for an unchanged path. A drag that ends at the
length the piece started with is now taken back as Escape takes it
back, on the path being drawn and on a selected path.
The two tests that check a stale hover's Smart Guides stay hidden with
Smart Guides off counted every overlay other than the path's points as
a guide. The length handles at the ends of the path being drawn now
show there too, so the tests failed although the guides were hidden.
The shared check accepts a handle and the line to it from the path's
end, and still fails when the tool shows a stale hover's guides.
With ES2015 scripts, a function declaration was judged by a property the
global object inherits, so a fixed property on Object.prototype stopped
`function name() {}`. The check now reads the global object's own
property, as ECMA-262 2015 section 8.1.1.4.16 does, and declares nothing
when the global object is not extensible and has no property of that
name. Indirect eval code makes the same check for all of its functions
before it declares any of them, and a function declaration never adds a
property to a global object that is not extensible.
A filter, or a live effect with commands, at plug-in API level 3 lists
`context` (settings, artboards, layers, swatches) with `doc.read` in its
permissions. Each filter or command run is then given those parts of the
active document in `_context.document`, whether or not anything is
selected: the document's name without its folder, color mode, units,
active artboard size, bleed and raster effects resolution; every
artboard's id, index, name, rectangle and whether it is active; every
layer and sublayer with its parent, depth, name, visibility, lock,
template, color and whether it is current; and every swatch as
swatch.list lists it. It holds no path, object or write handle, and
live-effect drawing, exporters and importers get none.
More than 10,000 rows or 4 MiB of them fail the run before the plug-in
starts, with the document unchanged, and each row takes 1,000
instructions from the run's budget. The install prompt names the wider
read. API_LEVEL is now 3, so older hosts refuse such a manifest.
plugin.list and plugin.info give `context`, and their params text names
it and API level 3.
The plug-in fuzz tests add hostile `context` manifests, installed and
run with and without a selection.
Docs: docs/plugins.md (Document information), docs/mcp.md,
docs/target-app-parity.md.
A call to a function with a rest parameter built the array of its extra
arguments without reserving room for it, so `f.apply(null, big)` could
push the heap estimate past the limit. The call now counts the rest
array, its binding and one property per extra argument in the room it
reserves before the function's environment is made.
Spreading a concatenated string (`[...s]`, `f(...s)`) flattened it before
any limit was checked, so a script could make the host build the whole
copy before the per-element fuel and heap accounting ran. The spread now
flattens through the same counted helper the string built-ins use, which
ends the run with the heap limit before the copy is made.
When defining the UnitValue members fails part way, the realm turns the
unit operators off again and restores the global UnitValue to what it was
before the call, so a second add_unit_values() installs everything.
A filter's output may hold `notice`, one string reporting what the run did.
It needs no permission and no host import. Once the output is applied,
plugin.run and plug-in commands return it as `notice`, and the desktop app
and the web build show it in the status bar as `Plug-in “name”: notice`.
The status bar translates the words around it and never the notice.
The host trims the notice, escapes control, bidirectional and separator
characters, and cuts it at 200 characters, escapes included. A notice that
is not a string or has no visible character refuses the output, and nothing
changes. A run that declines, fails, is refused or is canceled shows none,
and a live effect's notice is ignored.
Docs: docs/plugins.md, docs/mcp.md, docs/target-app-parity.md.
- The searches for all the selected objects share one limit of
134,217,728 distances from a point to an edge, as Add Bounding Circle
shares its splits, and each cell is measured only when the limit has
room for it. One search keeps at most 1,048,576 cells waiting. The
pathops crate adds inscribed_circle_within for a shared budget.
- The search stops once its best center is within the precision of half
the box's narrower side, so a long rectangle ends at its first cells,
and cells that cannot beat the best center are no longer queued.
- A fill much smaller than the precision still gets a circle: the
search keeps splitting until it finds a center inside the outline.
- The precision also follows the box of the area the fill rule leaves.
- Flattening stops at the first curve past the edge limit. An outline
that flattening closes up, or whose center lands outside the curves,
is flattened up to four times, 16 times finer each time; one it still
cannot resolve is too complex to measure, not empty. Areas are summed
from each contour's own first point.
- An outline with more than 262,144 anchors in its filled subpaths is
refused before it is resolved.
- A selected layer is refused like any other object that is not a path,
and inside an isolated compound path the circles join it, as Tangent
Circle's do.
- The menu item uses a named constant, and a UI test checks that it
runs the command with no dialog and selects a new live circle in each
selected shape, as one undo step.
- The params text and docs say that the 0.02 pt bound holds before the
circle is drawn 0.03% smaller, that a shape under 10 pt across is
measured to a five-hundredth of its narrower side, when long curves
are flattened more coarsely, and that edges can move by 1e-6 pt as in
the other path operations.
Shape Builder regions (#937) and Asset Export borders (#983, #1037) are
fixed; the item now names what docs/roadmap.md keeps (#864's unit
preference, #885) with its 6-13 h estimate.
A function declared in a block sets the enclosing variable of its name
only when that declaration itself is eligible, so a declaration inside
a let of the same name no longer assigns the variable because another
declaration of that name elsewhere in the body is eligible.
Spread of an object with a length property reads the length with
ToLength, so a negative or NaN length adds no elements instead of
wrapping to a count near 2^32. A function body's environments stay on
the collector's roots while its scope, functions and arguments object
are made.
Global code runs in the realm's lexical scope in either language, so a
function an earlier ES5.1 run, an indirect eval or the Function
constructor made can read a let or const a later .js run declares. With
the ES2015 option, a script whose function cannot replace a property of
the global object throws a TypeError before any of its let or const
names is declared, so a failed run leaves no name uninitialized.
The other character a shape read as a combining mark also is was kept
by the shape's id. The parts of a compound path share that id, so with
two such marks in one compound the second mark's character replaced the
first's, and a split that left the first mark first on a line set it as
the second mark's character (a dot below became a small tilde). The
character is now kept by the part's own glyph match, and the new test
moves a dot below and a tilde off their base into one compound path.
With two colors and some pixels transparent, Black & White still built
both black and white entries next to the transparent one, so the palette
held three entries. When only one entry is left, Black & White now takes
black or white, whichever leaves the opaque pixels nearer the palette with
the locked colors included, and skips an end that is already locked.
curved_band took eight arguments once it gained the mesh's band data,
and an allow attribute silenced clippy's too_many_arguments lint. It now
takes the partner rings as one [a, b] array, and the allow attribute has
been removed.
With a twist, each edge of a band is cut into pieces, and the mesh gave
those pieces their flat face normals, so a rounded or custom bevel with
a twist was exported faceted. The smoothed normals are now worked out
for each piece of each edge, from the same pieces the band is cut into,
and every piece takes its own.
The test a_twisted_rounded_bevel_keeps_its_normals_smoothed_on_every_piece_of_a_cut_edge
checks that where the pieces of two bevel bands meet, the two bands
give each piece one normal.
The merge of main brought in code that indexes the anchor list while
smooth_open now keeps it in an EditsFromEnd, which has no indexing, so
the engine did not build. The anchors at both ends of a run and of its
neighboring segments are now read from the span that EditsFromEnd::get
returns.
Extrude & Bevel's caps, Rotate's plane and Inflate's front and back took
their texture coordinates in the bounds of each part's own rings, so a
part smaller than its object had its coordinates stretched to its own
extent and did not line up with the object's other parts. They now use
the bounds the solid is built with, which every part of one object
shares, as the Turn, Placing and Camera transforms already do.
The test the_parts_of_one_object_place_their_caps_and_planes_in_its_shared_bounds
builds a small part inside a larger object's bounds with each effect and
checks every front and back corner against the shared bounds.
A New Document profile file that is a link or a folder is no longer read:
the read is exempt from a script's file gate, which never checked where a
link leads. file.new reports it as a profileError with the reason "not a
plain file".
Reading a DocumentPreset setting now counts the value it returns toward
the data a run may pass, as assigning it does, and addDocument counts the
preset's settings before copying them.
The removeAll() test on a locked artboard now also holds an object on an
unlocked artboard and checks it is still there after the call throws.
docs/mcp.md now says the measuring spacing is a target (at least 4 and at
most 1,024 pieces per curved segment, fewer on subpaths of more than 256
segments) and gives the acceptance test as formulas: t1 <= t0 + 0.001 * s
and fewer anchors, t0 - t1 >= 0.000001 * s, or b0 - b1 > 0.0001 * b0,
with s the larger of t0 and 1. The roughness doc comment says the points
are about `step` apart.
The expected value multiplied 1e307 by 1000 before dividing, which
overflows to infinity, so the closeness check accepted any finite
result. The expected value now divides the factors first.
vectorcraft-js gains Options::es2015, which reads and runs these
ECMAScript 2015 forms: let and const with block scope and their
temporal dead zone, a new let binding for each loop iteration,
function declarations scoped to their block (with the Annex B.3.3
variable outside strict mode code), arrow functions, template
literals and tagged templates, default and rest parameters, and
spread in array literals, calls and new. Spread reads arrays,
strings by code point and objects with a length, by index, and
throws a TypeError for anything else until iterators are added.
Eval code outside strict mode code cannot declare a var that clashes
with a let or const around it, or with a parameter inside a default
value. Spread, template objects and the new scopes take fuel and
count against the heap limit, and nested arrows and templates count
against the depth limit.
script.run sets the option for a .js file; eval, Function, #include
files, $.evalFile and a kept #targetengine read code the way the
running script does. A .jsx file and a source string stay ES5.1.
The test262 runner gains an ES2015 subset run, read without and with
the option. docs/mcp.md and docs/target-app-parity.md describe the
new forms.