`vectorcraft-cli thumbnail` wrote OUT with `write_atomic`, which copies
into the target when the folder refuses the temporary file or the
rename, so a run stopped by the time limit during that copy could leave
a partial PNG. It now writes a temporary file beside OUT and renames it
over OUT; when the rename fails it returns the error, removes its own
temporary file and leaves OUT unchanged. A file already at the
temporary name is left in place.
docs/target-app-parity.md names the DLL in the `regsvr32 /u` command.
addon.pathtools.shape.create and addon.pathtools.shape.set take sliceStart
and sliceEnd, in degrees clockwise from the shape's top (0 to 360). The
shape is cut from the start clockwise to the end and back through its
center; a ring's slice runs back along its hole. The angles are measured
as if the shape were as high as it is wide, so 45 degrees is a
rectangle's top right corner and a slice keeps its place when the shape
is stretched along its own axes. The same start and end leave the whole
shape, rounded corners are rounded before the cut, and the arrow, cross,
heart, gear and speech bubble ignore both values. A value outside 0 to
360 is refused. The values are kept with the shape's other numbers and
with the Parametric Shape Tool's options.
A scatter brush takes a Brightness Jitter amount from 0 to 100 percent (0
by default). Each copy moves the brightness of its solid fills and
strokes, type included, by its own amount up to that many points either
way, after the colorization and the hue and saturation jitter. The
amounts come from the stroke's path and the brush name, drawn apart from
the hue and saturation jitter's, so a stroke draws the same colors on
every redraw, after Save and Open, and in export, and turning it on does
not change their amounts.
A color keeps its hue and saturation and moves in its own model: RGB in
the HSB of its values, Gray by its ink, Lab by its lightness with a and b
kept, and CMYK by its K over the brightness its C, M and Y leave. A CMYK
color that goes brighter than its C, M and Y show with no K loses its K
and takes less C, M and Y. The brightness stops at black and at full.
White, black and grays move too. A brush at 0 saves no brightness_jitter
key; a brush without the key reads as 0.
- brush.options takes brightness_jitter, and brush.get shows it for every
scatter brush. Brush Options shows a Brightness Jitter field
(ui.brushOptions field brightnessJitter).
- Options of Selected Object sets a path's own brightness_jitter
(brush.objectOptions).
- The brightness goes through the per-copy recolor step hue and
saturation jitter use, with its own salt.
- The .ai editing data writer does not write the amount, so such a brush
is left out of the Brushes panel there and reported.
Docs: docs/mcp.md, docs/target-app-parity.md.
File › Open and File › Place read layered raster .pcraft documents
through craft-doc and store them as one PNG, sized by the document's
resolution. A placed file links like any image.
- The image is the file's full-size composite when it has one.
- Without one, the layers are combined at the canvas size when the
document is RGB at 8 or 16 bits and every visible layer is a raster
layer that blends Normal, with no clipping, layer effects, vector
mask, frame, advanced blending or feathered layer mask. Hidden layers
are not read, and an RGB ICC profile the document names is kept.
- Otherwise the composite preview comes in at the canvas's size, and
Open, Place, links.update, links.relink and links.replaceEmbedded
warn when it has fewer pixels than the canvas, naming both sizes and
why the layers were not combined.
- A full-size composite or preview the file names but doesn't hold,
can't decode or, for the full-size one, of another size than the
canvas is an error. The Links commands decode the kept PNG before
taking it.
The import fuzz tests cover mutated bundles and manifests.
A click on a path's direction handle picks it, a Shift-click adds it to
the picked handles or takes it away, and Escape lets them go. Picked
handles show ringed. Dragging one of two or more picked handles moves
all of them, on one path or several, by the same offset in one undo
step. A Shift-press on a handle reshapes only once the pointer has moved
3 pixels, so a Shift-click leaves the handle where it is.
The new command path.moveHandles does the move: an anchor with one
handle listed places it as path.setHandle does, an anchor with both
listed moves both and becomes a corner, and independent (Alt during the
drag) makes every listed handle's anchor a corner.
Docs: docs/mcp.md, docs/target-app-parity.md.
A scatter brush takes a Saturation Jitter amount from 0 to 100 percent (0
by default). Each copy moves the saturation of its solid fills and
strokes, type included, by its own amount up to that many points either
way, after the colorization and the hue jitter. The amounts come from the
stroke's path and the brush name, drawn apart from the hue jitter's, so a
stroke draws the same colors on every redraw, after Save and Open, and in
export, and turning it on does not change the hue jitter's amounts.
A color keeps its hue and brightness and moves in its own model: RGB in
the HSB of its values, CMYK over C, M and Y with K kept, Lab by moving its
chroma with its lightness and hue angle kept (a and b stay within 127).
The saturation stops at none and at full. White, black and grays stay as
they are. A brush at 0 saves no saturation_jitter key; a brush without
the key reads as 0.
- brush.options takes saturation_jitter, and brush.get shows it for every
scatter brush. Brush Options shows a Saturation Jitter field
(ui.brushOptions field saturationJitter).
- Hue and saturation jitter share one per-copy recolor step, which takes
a salt and a color adjustment.
- Options of Selected Object showed Hue Jitter but dropped a change to it
on OK, since a path could not set it for itself. A path now sets its own
hue_jitter and saturation_jitter (brush.objectOptions).
- The .ai editing data writer does not write the amount, so such a brush
is left out of the Brushes panel there and reported.
Docs: docs/mcp.md, docs/target-app-parity.md.
The Parametric Shape panel read Shape, Count, W, H, Rotation, the kind's
own values and Corner Radius with value(), which carries each proposed
value but not the value a cancel restores. With no shape selected, a W
typed and then canceled with Escape stayed as the tool option, so the
next shape drawn had the canceled width. With a shape selected, each
keystroke was its own undo step and Escape left the shape edited.
- With a shape selected, each field's gesture runs in one undo scope
(EditPath::Scope, as the Live Shape panel's fields do): Enter keeps the
edit as one undo step, and Escape reverts it.
- With no shape selected, the fields send the value they land on
(events.landed(), as the Corner and Shared Edge sections do since
#9773), so Escape restores the opening tool option.
- With no shape selected, a highlighted Shape entry applies only once it
is chosen: a new kind resets the kind's own count and values, which a
restored kind would not bring back.
- A field left empty still ends its gesture, so its undo step closes.
Docs: docs/mcp.md (Parametric Shape Tool), docs/ui-parity.md.
path.moveAnchors with dx and dy both 0 (omitted, null or 0) ran the edit
anyway and added a Move step that changed nothing. It now returns before
the edit, as object.nudge does for a move by 0, and its params text
says so.
layer.setProps with no options, or with every option a row already has,
added a Layer Options step that changed nothing. It now applies the
options to a copy of each row first and records no step when no row
changes. As object.setProps does, a call that hides, locks or makes a
template still deselects the art that is no longer editable.
The Command Palette test that checks what a pick of a left-out command
does no longer skips the two commands.
Create Object Mosaic refused an image changed by Perspective Distort or
Free Distort. It now places each tile's cell of pixels between the
image's corners through the image's projective map, so the tiles are
four-sided shapes that follow the perspective. A new size scales them
from the top left of the image's bounds, as it does for any image, and
the spacing and Use Ratio measure a pixel by the mean length of the
image's two sides along each axis. Plain images are tiled as before.
Docs: docs/mcp.md (Create Object Mosaic and the distorted-image
paragraph), docs/target-app-parity.md.
The new apps/vectorcraft-thumbnail-handler crate builds
vectorcraft_thumbnail_handler.dll, a thumbnail handler (IThumbnailProvider
with IInitializeWithStream) for .vectorcraft, .drawcraft and .vctemplate
files. Explorer passes it the file's bytes. It writes them to a file in
%USERPROFILE%\AppData\LocalLow\VectorCraft\Thumbnails (the temp folder when
that can't be made), runs `vectorcraft-cli thumbnail --size N` from the DLL's
folder on that file, and returns the PNG as a top-down 32-bit bitmap with
premultiplied alpha, at most 1024 pixels on its longer side. A file larger
than 256 MiB, a failed run, or a run longer than 25 seconds returns an error,
and Explorer shows the file's icon. Explorer gives the handler the file's
bytes and not its path, so a linked image found only relative to the
document's folder shows the preview saved with it.
`regsvr32 vectorcraft_thumbnail_handler.dll` registers the handler for the
current user under HKCU\Software\Classes, and `regsvr32 /u` removes the class
key and each extension's ShellEx key that names it. The Windows packages do
not build, ship or register the DLL yet.
The COM code is Windows-only and has a module-scoped unsafe_code allowance.
The registry values, the stream limit, the PNG conversion and the
vectorcraft-cli run build on every system, and their tests run in CI.
Each thumbnail test now writes its documents and PNGs into its own
tempfile::TempDir, which is removed when the test ends, instead of a
per-process folder in the temp folder that was never removed. The
progress-doc line now says the tests cover everything but the
20-second limit.
A path made into a guide paints no strokes, but painted_box still measured its
stroke, so a Use Preview Bounds dimension of a whole guide reached past its
outermost points. painted_box now returns None for a guide, which covers both
preview_extents and reach. The parity note says W and H match only when the
path has no geometry effect, in line with docs/dimensions.md.
Rename Button now opens through the craft UI framework: the dialog is a
hosted parameter dialog like New Toolbar, its OK is held while the label
is refused, and an OK after switching workspaces is refused. The button
context menu item and the button face use the framework Menu and Button;
the face paints the label of its own while the accessible name keeps the
command name after it. Tests drive the dialog through panel_harness.
object.setLiveShape rewrote only the path after a new Rectangle, Ellipse
or Polygon Angle, Polygon Radius, Side Length, Make Sides Equal, Line
Length or Line Angle, so a linked opacity mask, placed gradients and
pattern tiles stayed where they were. The edit now applies the transform
between the old and new shape to the object, as object.scale and
object.rotate do, and then sets the new shape. Scale Strokes & Effects
and Transform Patterns come from the new `strokes` and `patterns` params
or the preferences. Corner radii in the mask keep their size, an object
named twice moves once, and the bounding box keeps its angle.
Transform Patterns is now noted in the journal when only the art of a
linked opacity mask uses a pattern, so a replay of object.move,
object.scale and the other transforms moves those tiles alike.
The Polygonal Lasso Tool joins the Lasso group in both shipped
toolbars, after the Enclosing Lasso, and stays in Object › Plug-ins ›
Polygonal Lasso. The All Tools drawer lists it once, under Select,
instead of under a heading of its own, and Edit › Keyboard Shortcuts ›
Tools lists it once. It has no default shortcut, and the Lasso keeps Q.
A toolbar the user already edited keeps its saved layout; Reset Toolbar
adds the tool. A Lasso group torn off the Tools panel shows it too.
The Enclosing Lasso moved the same way in #8333.
- Adding a control or an item, and removing items, builds both arrays
before the first write, so a run that ends at the heap limit leaves the
lists and the dialog's counts as they were.
- A listener registered after an event started does not hear it in a later
phase, a capturing container's re-registration included.
- show() reads the dialog again when a getter changes a list item's text
after the item was read.
- Enter and Escape skip an OK or Cancel button inside a hidden or disabled
container.
- A resource string of a name and a type without braces throws a
SyntaxError, and a \u escape pair of surrogates reads as one character.
- In the app, queued events wait while another dialog is open over the
script's dialog, and the run's own questions wait while a popup, such as
an open drop-down list, is over it. ui.dialog.confirm and
ui.dialog.cancel take only the dialog, ui.dialog.set needs a field or an
action and answers with the dialog it set, and OK is refused while a
dialog open over it waits. A cancel after typed text clicks the cancel
button the dialog has when its turn comes, and an immediate cancel the
run refuses is an error.
- A click on a list box row gives the list the keyboard focus.
- The vc hint test names BridgeTalk, since Window now exists; the params
text and docs/mcp.md say that a show() in a handler notify runs throws
only in the app, and define_script_ui says when end is not called.
The deb, rpm and tar.gz packages install
share/thumbnailers/ai.storyteller.vectorcraft.thumbnailer for
application/x-vectorcraft and application/x-vectorcraft-template. It runs
the new `vectorcraft-cli thumbnail --size N IN OUT`, which opens the
document as the app does and writes an 8-bit RGBA PNG of the first
artboard, N pixels (1 to 1024, default 256) on its longer side.
A file larger than 256 MiB, one that can't be opened, a document that
shows nothing, or a run longer than 20 seconds writes no PNG and exits
non-zero, so the file manager keeps the file's icon. The Nightly deb and
rpm leave the entry out, as they leave out the MIME package.
The render moves into vectorcraft_render::encode::first_artboard, which
the embedded native preview also uses.
With a group selected, a Direct Selection Shift-click on the fill of one of its paths ran
select.toggle on the path, which added the path beside the group. The path stayed selected
through the group, and so did everything else in it.
The new select.remove command takes each target out of the selection. For a target inside a
selected group or compound path, Selection::expand_to first selects the objects inside the
outermost selected one on the way down to the target, in its place, so the rest of the group
stays selected. Hidden and locked objects and a Shaper Group's original shapes are left out. Direct Selection's Shift-click on such a path runs select.remove, and a
Shift-drag from there moves nothing. A Shift-click on one of the path's anchors runs
select.anchors with mode toggle, which now opens the group the same way and deselects only that
anchor. A path selected beside the group around it, as Group Selection leaves it, is taken out
with the group.
No public documentation describes this case, so this is VectorCraft's own rule.