如何更改 VSCODE 中括号之间的缩进引导线颜色?

2024-05-13

我想更改两个括号之间的线的颜色。

其实我想要这个

这就是我想要的

有谁知道这是怎么做到的吗?

非常感谢


vscode v1.81 的更新(现在在 Insiders 中,大概在 2023 年 8 月上旬发布稳定版):

These colorCustomizations已添加,以便您可以单独为前 6 个缩进指南着色 - 从代码中的最左侧到右侧计数,请参阅演示):

  "workbench.colorCustomizations": {

    "editorIndentGuide.activeBackground1": "#ffc400",
    "editorIndentGuide.activeBackground2": "#ff0000",
    "editorIndentGuide.activeBackground3": "#a51283",
    "editorIndentGuide.activeBackground4": "#ff8c00",
    "editorIndentGuide.activeBackground5": "#ffc400",
    "editorIndentGuide.activeBackground6": "#ffc400",

           // non-active indent guide colors
    "editorIndentGuide.background1": "#0066ff",
    "editorIndentGuide.background2": "#00e5ff",
    "editorIndentGuide.background3": "#00e5ff",
    "editorIndentGuide.background4": "#00e5ff",
    "editorIndentGuide.background5": "#00e5ff",
    "editorIndentGuide.background6": "#00e5ff"
  }

请注意editorIndentGuide.activeBackground1 and editorIndentGuide.background1请参阅最左侧的缩进指南等。一次只有一个 activeBackground 被着色 - 无论它恰好位于左侧的哪一层。


VSCode v.1.23(2018 年 5 月发布)添加了为活动和其他非活动缩进指南着色的功能:

"workbench.colorCustomizations": {
    "editorIndentGuide.activeBackground": "#ff0000",
    "editorIndentGuide.background": "#ff00ff"
}

See 发行说明缩进指南 https://code.visualstudio.com/updates/v1_23#_highlighted-indent-guides

如果您只希望活动参考线可见,请将非活动参考线的背景设置为透明ala:

"workbench.colorCustomizations": {
    "editorIndentGuide.background": "#fff0"
}
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

如何更改 VSCODE 中括号之间的缩进引导线颜色? 的相关文章

随机推荐