Vector kit command
path.freehand
Pencil
Draws a freehand path through points (with optional pen pressure), smoothed by fidelity, as the Pencil or Paintbrush does; can extend an existing path.
- Kit
- Vector 0.1.0 (.kvector)
- Changes the document
- yes
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
closed | boolean | no | |
extend | object | no | |
fidelity | number | no | points; 1.5 |
fill | boolean | no | |
points | any[] | no | pen pressure 0..1: the stroke keeps it, for Calligraphic brushes with Pressure variation; a point without one presses fully |
pressure | number | no | read by the command beside its listed parameters |
style | "pencil" | "brush" | no | |
x | number | no | read by the command beside its listed parameters |
y | number | no | read by the command beside its listed parameters |
Call through vector_run
text
vector_run {
"path": "<file>.kvector",
"steps": [{ "command": "path.freehand" }]
}The required parameters, with placeholders for their types: not a tested example. Optional: closed, extend, fidelity, fill, points, pressure, style, x, y. vector_run answers the step’s result in completed[i].result.
Result
The kit gives no result schema for this command.
Parameter schema
json
{
"additionalProperties": false,
"properties": {
"closed": {
"type": "boolean"
},
"extend": {
"additionalProperties": true,
"properties": {
"end": {
"enum": [
"start",
"end"
],
"type": "string"
},
"id": {
"description": "object ID",
"type": "integer",
"x-khp-role": "object",
"x-khp-types": [
"Node"
]
}
},
"type": "object"
},
"fidelity": {
"description": "points; 1.5",
"type": "number"
},
"fill": {
"type": "boolean"
},
"points": {
"description": "pen pressure 0..1: the stroke keeps it, for Calligraphic brushes with Pressure variation; a point without one presses fully",
"type": "array"
},
"pressure": {
"description": "read by the command beside its listed parameters",
"type": "number"
},
"style": {
"enum": [
"pencil",
"brush"
],
"type": "string"
},
"x": {
"description": "read by the command beside its listed parameters",
"type": "number"
},
"y": {
"description": "read by the command beside its listed parameters",
"type": "number"
}
},
"returns": "{id}",
"type": "object"
}Generated from the command list of @kition/[email protected] and the kit itself (vector_commands through @kition/[email protected], built from KitionAI/kition-vector@7cf908f). As data: commands.jsonl.