mirror of
https://github.com/storytold/vectorcraft.git
synced 2026-10-30 12:47:13 -06:00
M3.62: thirty more generated arrowheads with rendered previews
Arrowhead gains 30 original shapes generated in code, appended after the first ten so saved names stay stable: Barbed, Half Arrow (left/right), Concave, Double Arrow, Chevron, Feather, Swallowtail, Reverse Triangle, Triangle to Bar, Kite, Leaf, Drop, Half Circle, Oval, Target, Tag (+ open), Diamond (open), Hexagon (+ open), Star, Cross, Plus, Double Bar, Dot on Bar, Slash, Double Slash, Bracket and Fork. Each is drawn in local units of the head's weight inside the usual 4 x 4 box, with its own stop for the stroke under it. Arrowhead::label() names them in the menus. The Stroke panel's arrowhead dropdowns render every head as the canvas draws it (cached textures, a shared widgets::doc_preview that the Brushes panel now uses too) in a scrolling list. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
3e73ad8581
commit
fdad11a99c
@@ -499,3 +499,11 @@ and `stroke.widthProfile.reset` removes every saved one. `stroke.set {profile}`
|
||||
{"name":"run_command","arguments":{"command":"stroke.widthProfile.add","params":{"name":"Ribbon"}}}
|
||||
{"name":"run_command","arguments":{"command":"stroke.set","params":{"ids":[9],"profile":"Ribbon"}}}
|
||||
```
|
||||
|
||||
## Arrowheads
|
||||
|
||||
`stroke.set {startArrow, endArrow}` takes any of 40 generated heads by name (the params doc lists them; `null` for
|
||||
none): arrows (`Arrow`, `Barbed`, `Concave`, `DoubleArrow`, `HalfArrowLeft`/`Right`, `Chevron`, `Feather`,
|
||||
`Swallowtail`…), filled and open shapes (`Triangle`, `Circle`, `Oval`, `Target`, `Tag`, `Diamond`, `Hexagon`, `Star`,
|
||||
the `…Open` rings…) and marks (`Bar`, `DoubleBar`, `DotOnBar`, `Slash`, `DoubleSlash`, `Bracket`, `Fork`, `Cross`,
|
||||
`Plus`). Each head fits a box about four times its weight (stroke weight × `arrowScale`) long and wide.
|
||||
|
||||
Reference in New Issue
Block a user