Vector kit command

text.areaOptions

Area Type Options…

Sets area type options of the selected type: frame size, rows, columns, gutter, inset, first baseline, vertical alignment and auto-fit.

Kit
Vector 0.1.0 (.kvector)
Changes the document
yes
Acts on
ids (a list of ids), which a run step’s on fills

Parameters

Parameters of text.areaOptions
NameTypeRequiredDescription
columnsintegerno
firstBaseline"ascent" | "capHeight" | "xHeight" | "leading" | "fixed"no
firstBaselineMinnumbernopoints
fit"none" | "autoHeight" | "shrinkText"no
fitMinPercentintegerno10 to 100
gutternumbernopoints
heightnumbernopoints
idintegernoobject ID
idsinteger[]noobject IDs
insetnumbernopoints
rowsintegerno
verticalAlign"top" | "center" | "bottom" | "justify"no
widthnumbernopoints

Call through vector_run

text
vector_run {
  "path": "<file>.kvector",
  "steps": [{ "command": "text.areaOptions" }]
}

The required parameters, with placeholders for their types: not a tested example. Optional: columns, firstBaseline, firstBaselineMin, fit, fitMinPercent, gutter, height, id, ids, inset, rows, verticalAlign, width. 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": {
    "columns": {
      "type": "integer"
    },
    "firstBaseline": {
      "enum": [
        "ascent",
        "capHeight",
        "xHeight",
        "leading",
        "fixed"
      ],
      "type": "string"
    },
    "firstBaselineMin": {
      "description": "points",
      "type": "number"
    },
    "fit": {
      "enum": [
        "none",
        "autoHeight",
        "shrinkText"
      ],
      "type": "string"
    },
    "fitMinPercent": {
      "description": "10 to 100",
      "type": "integer"
    },
    "gutter": {
      "description": "points",
      "type": "number"
    },
    "height": {
      "description": "points",
      "type": "number"
    },
    "id": {
      "description": "object ID",
      "type": "integer",
      "x-khp-types": [
        "Node"
      ]
    },
    "ids": {
      "description": "object IDs",
      "items": {
        "type": "integer"
      },
      "type": "array",
      "x-khp-types": [
        "Node"
      ]
    },
    "inset": {
      "description": "points",
      "type": "number"
    },
    "rows": {
      "type": "integer"
    },
    "verticalAlign": {
      "enum": [
        "top",
        "center",
        "bottom",
        "justify"
      ],
      "type": "string"
    },
    "width": {
      "description": "points",
      "type": "number"
    }
  },
  "returns": "the first object's options, plus overflow (the text doesn't fit its frame) and fitScale (Shrink Text's factor, 1 unshrunk)",
  "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.