Doc kit command
format.state
Formatting at Selection
Answers the character and paragraph formatting at the selection (font, size, bold, italic, style, alignment…), as the ribbon shows it; on Chinese, Japanese or Korean text (`eastAsian`) the Font box shows the East Asian font (`fontEa`), and `fontShown` names the family that draws the shown font when this engine has no face of that name.
- Kit
- Doc 0.1.0 (.docx)
- Changes the document
- no
Parameters
None.
Call through doc_run
text
doc_run {
"path": "<file>.docx",
"steps": [{ "command": "format.state" }]
}The required parameters, with placeholders for their types: not a tested example. doc_run answers the step’s result in completed[i].result.
Result
| Name | Type | Required | Description |
|---|---|---|---|
bold | boolean | no | |
border | boolean | no | |
color | string | no | |
eastAsian | boolean | no | |
font | string | no | |
fontEa | string | no | |
fontShown | any | no | |
highlight | any | no | |
italic | boolean | no | |
size | number | no | |
strike | boolean | no | |
style | string | no | |
styleName | string | no | |
subscript | boolean | no | |
superscript | boolean | no | |
underline | boolean | no |
Result JSON Schema
json
{
"additionalProperties": true,
"properties": {
"bold": {
"type": "boolean"
},
"border": {
"type": "boolean"
},
"color": {
"type": "string"
},
"eastAsian": {
"type": "boolean"
},
"font": {
"type": "string"
},
"fontEa": {
"type": "string"
},
"fontShown": {},
"highlight": {},
"italic": {
"type": "boolean"
},
"size": {
"type": "number"
},
"strike": {
"type": "boolean"
},
"style": {
"type": "string"
},
"styleName": {
"type": "string"
},
"subscript": {
"type": "boolean"
},
"superscript": {
"type": "boolean"
},
"underline": {
"type": "boolean"
}
},
"type": "object"
}Generated from the command list of @kition/[email protected] and the kit itself (doc_commands through @kition/[email protected], built from KitionAI/kition-doc@41e14a8). As data: commands.jsonl.