Layout kit command

prefs.set

Preferences

Sets application preferences: hidden characters, typographer's quotes, polygon sides, stroke scaling and more.

Kit
Layout 0.1.0 (.klayout)
Changes the document
yes

Parameters

Parameters of prefs.set
NameTypeRequiredDescription
absolutePageNumbersbooleanno
autocorrectbooleannoread by the command beside its listed parameters
autocorrectListany[]noread by the command beside its listed parameters
dimensionsIncludeStrokebooleanno
favoriteFontsstring[]no
highlightCustomTrackingbooleanno
highlightHjbooleanno
highlightKeepsbooleanno
highlightSubstitutedFontsbooleanno
polygonSidesintegerno
recoveryMinutesnumbernoread by the command beside its listed parameters
richBlackOutputbooleanno
scaleStrokesbooleanno
showAddedTextbooleannoread by the command beside its listed parameters
showFontNamesInEnglishbooleanno
showHiddenCharactersbooleanno
showNoteAnchorsbooleannoread by the command beside its listed parameters
showTextThreadsbooleannoread by the command beside its listed parameters
smartTextReflowbooleannoread by the command beside its listed parameters
starInsetnumberno
storyintegernoread by the command beside its listed parameters
transformationsAreTotalsbooleanno
typographersQuotesbooleanno

Call through layout_run

text
layout_run {
  "path": "<file>.klayout",
  "steps": [{ "command": "prefs.set" }]
}

The required parameters, with placeholders for their types: not a tested example. Optional: absolutePageNumbers, autocorrect, autocorrectList, dimensionsIncludeStroke, favoriteFonts, highlightCustomTracking, highlightHj, highlightKeeps, highlightSubstitutedFonts, polygonSides, recoveryMinutes, richBlackOutput, scaleStrokes, showAddedText, showFontNamesInEnglish, showHiddenCharacters, showNoteAnchors, showTextThreads, smartTextReflow, starInset, story, transformationsAreTotals, typographersQuotes. layout_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": {
    "absolutePageNumbers": {
      "type": "boolean"
    },
    "autocorrect": {
      "description": "read by the command beside its listed parameters",
      "type": "boolean"
    },
    "autocorrectList": {
      "description": "read by the command beside its listed parameters",
      "type": "array"
    },
    "dimensionsIncludeStroke": {
      "type": "boolean"
    },
    "favoriteFonts": {
      "items": {
        "type": "string"
      },
      "type": "array"
    },
    "highlightCustomTracking": {
      "type": "boolean"
    },
    "highlightHj": {
      "type": "boolean"
    },
    "highlightKeeps": {
      "type": "boolean"
    },
    "highlightSubstitutedFonts": {
      "type": "boolean"
    },
    "polygonSides": {
      "type": "integer"
    },
    "recoveryMinutes": {
      "description": "read by the command beside its listed parameters",
      "type": "number"
    },
    "richBlackOutput": {
      "type": "boolean"
    },
    "scaleStrokes": {
      "type": "boolean"
    },
    "showAddedText": {
      "description": "read by the command beside its listed parameters",
      "type": "boolean"
    },
    "showFontNamesInEnglish": {
      "type": "boolean"
    },
    "showHiddenCharacters": {
      "type": "boolean"
    },
    "showNoteAnchors": {
      "description": "read by the command beside its listed parameters",
      "type": "boolean"
    },
    "showTextThreads": {
      "description": "read by the command beside its listed parameters",
      "type": "boolean"
    },
    "smartTextReflow": {
      "description": "read by the command beside its listed parameters",
      "type": "boolean"
    },
    "starInset": {
      "type": "number"
    },
    "story": {
      "description": "read by the command beside its listed parameters",
      "type": "integer",
      "x-khp-types": [
        "Story"
      ]
    },
    "transformationsAreTotals": {
      "type": "boolean"
    },
    "typographersQuotes": {
      "type": "boolean"
    }
  },
  "returns": "all application preferences",
  "type": "object"
}

Generated from the command list of @kition/[email protected] and the kit itself (layout_commands through @kition/[email protected], built from KitionAI/kition-layout@8767a18). As data: commands.jsonl.