mirror of
https://github.com/storytold/vectorcraft.git
synced 2026-10-24 09:46:59 -06:00
M8.15: Envelope dialogs, Reset with Warp/Mesh, full Envelope Options
Make with Warp and Make with Mesh open dedicated dialogs (style dropdown, orientation, bend and distortion sliders; rows and columns) with live preview; while an envelope is selected the menu shows Reset with Warp / Reset with Mesh instead, which switch the envelope's kind and keep its content (Maintain Envelope Shape samples the current surface). Envelope Options is a full dialog prefilled from the selection (Anti-Alias, Preserve Shape, Fidelity, Distort Appearance, Distort Linear Gradients, Distort Pattern Fills); with nothing selected it sets the defaults for new envelopes. object.envelope.info reads the settings. Release returns the warp or mesh shape as a gradient mesh and keeps opacity, blend mode and mask; Expand keeps name, knockout, isolation and mask; Object > Expand expands envelopes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
6994f248b2
commit
fe6d6640fb
@@ -455,3 +455,13 @@ dialog prefilled from the grid. Its fields are those of `perspective.grid.define
|
||||
`gridline`, `angle`, `distance`, `horizonHeight`, `thirdVp`, `leftColor`, `rightColor`, `groundColor`, `opacity`;
|
||||
lengths in `units`, so setting `units` converts them). `ui.dialog.confirm` runs `perspective.grid.define`; a refused
|
||||
value keeps the dialog open.
|
||||
|
||||
Object → Envelope Distort's dialogs open through their menu items or `ui.menuDialog {command}`. Make with Warp…
|
||||
(`object.envelope.makeWithWarp`) opens `envelopeWarp` (fields `style`, `horizontal`, `bend`, `h`, `v`, `preview`, and
|
||||
`reset`); while an envelope is selected the menu shows Reset with Warp… instead, and the same item, shortcut or
|
||||
`object.envelope.resetWithWarp` opens it with `reset: true` and the envelope's values. Make with Mesh… / Reset with
|
||||
Mesh… open `envelopeMesh` (`rows`, `cols`, `reset`, and `maintainShape` when resetting). Envelope Options…
|
||||
(`object.envelope.options`) opens `envelopeOptions` (`antiAlias`, `preserveShape`, `fidelity`, `distortAppearance`,
|
||||
`distortLinearGradients`, `distortPatternFills`) with the selected envelope's values, or with nothing selected the
|
||||
defaults for new envelopes. They preview live while an envelope is involved, and `ui.dialog.confirm` keeps the result
|
||||
as one undo step.
|
||||
|
||||
+28
@@ -1764,3 +1764,31 @@ the viewing angle, so the vanishing points sit at `x − distance/tan(angle)` an
|
||||
{"name":"run_command","arguments":{"command":"perspective.grid.get","params":{}}}
|
||||
{"name":"run_command","arguments":{"command":"perspective.grid.define","params":{"units":"inches","gridline":0.5,"angle":30,"distance":6,"horizonHeight":3}}}
|
||||
```
|
||||
|
||||
## Envelopes
|
||||
|
||||
Object → Envelope Distort wraps the selection in a live envelope: `object.envelope.makeWithWarp` (`style`: arc,
|
||||
arcLower, arcUpper, arch, bulge, shellLower, shellUpper, flag, wave, fish, rise, fisheye, inflate, squeeze or twist;
|
||||
`bend`, `h` and `v` in % from -100 to 100; `horizontal` or `orientation`), `object.envelope.makeWithMesh` (`rows`,
|
||||
`cols`: 1–50) and `object.envelope.makeWithTopObject` (the topmost selected path becomes the envelope).
|
||||
`object.envelope.info` reads the selected envelope's settings (`type`, the warp's or mesh's values, `fidelity` and
|
||||
the options, `editing`), or with no envelope selected the options new envelopes get. With an envelope selected,
|
||||
`object.envelope.resetWithWarp` and `object.envelope.resetWithMesh` (`rows`, `cols`, `maintainShape`: true keeps
|
||||
the current shape) switch its kind and keep its content. `object.envelope.options` sets `fidelity` and the options
|
||||
(`antiAlias`, `preserveShape`: clippingMask or transparency, `distortAppearance`, `distortLinearGradients`,
|
||||
`distortPatternFills`; the last two need `distortAppearance`); with no envelope selected it sets them for new
|
||||
envelopes. New envelopes start with Distort Appearance on, as in the reference app; envelopes saved before these
|
||||
options existed keep their old look (appearance applied after the distortion).
|
||||
|
||||
`object.envelope.release` gives back the content and the envelope's shape (a grey gradient mesh for warp and mesh
|
||||
envelopes, the path for a top-object envelope); the content keeps the envelope's opacity, blend mode and opacity mask
|
||||
(a group around it carries them when there are several objects). `object.envelope.expand`, and `object.expand` with
|
||||
`object` on, replace envelopes by groups of their distorted content that keep the name, transparency, knockout and
|
||||
opacity mask.
|
||||
|
||||
```json
|
||||
{"name":"run_command","arguments":{"command":"object.envelope.makeWithWarp","params":{"style":"arch","bend":40}}}
|
||||
{"name":"run_command","arguments":{"command":"object.envelope.resetWithMesh","params":{"rows":3,"cols":3,"maintainShape":true}}}
|
||||
{"name":"run_command","arguments":{"command":"object.envelope.options","params":{"fidelity":80,"distortAppearance":true,"distortLinearGradients":true}}}
|
||||
{"name":"run_command","arguments":{"command":"object.envelope.info","params":{}}}
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user