14.1 内置语言标识

  arkts astro batch c clojure cmake common-lisp cpp csharp css csv dart diff dockerfile
dotenv elixir erlang fish fsharp go graphql groovy haskell hcl html http ignore ini jai
java javascript json julia kotlin latex less liquid log lua makefile markdown matlab
mermaid nix nunjucks objective-c objective-cpp ocaml perl php powershell properties
protobuf python r ruby rust sass scala scss shell sql svelte svg swift toml tsv tsx
typescript typst vue wxml wxs wxss xml yaml zig
  

完整列表以所用 Winc 版本状态栏中的语言列表为准。语言标识区分大小写。

14.2 常用内置命令标识

类别标识
导航showCommands quickOpen goToSymbol goToLine goToDefinition findReferences goBack goForward
文件newFile openFile openFolder save saveAs saveAll closeTab reopenClosed
标签与分栏nextTab previousTab splitRight splitDown unsplit nextPane
编辑toggleComment deleteLine moveLinesUp moveLinesDown copyLinesDown joinLines indentLines outdentLines
多光标addCursorAbove addCursorBelow addNextOccurrence selectAllOccurrences
文本变换transformToUppercase transformToLowercase sortLinesAscending trimTrailingWhitespace prettyPrintJson
格式化format formatSelection fix
查找find replace findInFiles replaceInFiles
折叠fold unfold toggleFold foldAll unfoldAll
书签toggleBookmark nextBookmark previousBookmark listBookmarks
界面toggleSidebar showFiles showOutline zoomIn zoomOut settings keyboardShortcuts

完整列表见「设置 → 键盘快捷键」。

14.3 主题颜色键

位置键
colorsframe card popup text textMuted textDim accent accentFill selection error warning
colors.gutternormal current
colors.gitmodified added deleted conflict
colors.syntaxtext keyword type string number comment function decorator property interpolation
colors.ansiblack red green yellow blue magenta cyan white brightBlack brightRed brightGreen brightYellow brightBlue brightMagenta brightCyan brightWhite

内置主题标识包括 winc-day、winc-paper、sky、paper、vermilion、mist、veil-snow、veil-linen、winc-night 等,完整列表以「设置 → 外观」为准。

14.4 相关配置项

文件配置项说明
用户 config.jsonplugins.enabled插件模块开关,默认为 false
用户 config.jsonplugins.active插件标识到启用状态的映射
用户 config.jsonplugins.settings插件标识到设置值的映射
用户 config.jsonplugins.dev开发插件目录的路径列表
state.jsonapprovedPlugins批准记录,由 Winc 维护
state.jsonpluginInputs按项目记住的运行时输入值
项目 .winc/config.jsonplugins.active按项目启用或关闭插件

14.5 清单字段一览

  plugin.json
├── id                 字符串    必需   小写字母、数字、. - _
├── name               字符串    必需
├── version            字符串    必需   语义化版本
├── winc               字符串    必需   比较式,以逗号分隔
├── description        字符串    可选
├── permissions        数组      可选   "process" 或 { kind, command }
└── contributes        对象      可选
    ├── themes             [路径]
    ├── languages          [{ language, extensions?, fileNames? }]
    │                      [{ id, name, extensions?, fileNames?, lineComments?, blockComments?,
    │                         nestedComments?, indentUnit?, indentAfter?, singleQuotes?,
    │                         backticks?, tripleQuotes?, surround?, nameChars?, grammar? }]
    ├── grammarFragments   [路径]
    ├── languageServers    [{ language, command }]                             启动程序
    ├── formatters         [{ language, command }]                             启动程序
    ├── fixers             [{ language, command }]                             启动程序
    ├── snippets           [{ language, path }]
    ├── keybindings        [{ key, command | snippet, language? }]
    ├── commands           [{ id, title, command, args?, cwd?, env?, in }]     启动程序
    ├── menus              [{ command, where, title?, when? }]
    ├── buttons            [{ command, where, title, icon?, when? }]
    ├── settings           [{ key, title, description?, type, default, options?, optionLabels? }]
    ├── inputs             [{ key, title, description?, type, default?, required?, remember?,
    │                         placeholder?, min?, max?, options?, optionLabels?, extensions? }]
    └── dialogs            [{ id, title, description?, fields?, footer?, platforms? }]