英文:
VSCode Color Theme customization for golang method-parameters
问题
我正在尝试找到一种在VSCode中为'foo'、'a'和'b'着色的方法(语言:golang):
func (foo *Foobar) Subscribe(a string, b int) {
logger.Log(a)
logger.Log(b)
}
我该如何实现这一目标?我已经尝试编辑settings.json并添加了以下内容:
[...]
"workbench.colorTheme": "Slack Theme Dark Mode",
"editor.tokenColorCustomizations": {
"[Slack Theme Dark Mode]": {
"textMateRules": [
{
"scope": "variable.parameter.function",
"settings": {
"foreground": "#e21313"
}
}
]
}
}
参数没有采用我设置的颜色。
英文:
I'm trying to find a way to color 'foo', 'a' and 'b' in VSCode (language: golang):
func (foo *Foobar) Subscribe(a string, b int) {
logger.Log(a)
logger.Log(b)
}
How can I go about achieving this? I have tried editing settings.json and added this:
[...]
"workbench.colorTheme": "Slack Theme Dark Mode",
"editor.tokenColorCustomizations": {
"[Slack Theme Dark Mode]": {
"textMateRules": [
{
"scope": "variable.parameter.function",
"settings": {
"foreground": "#e21313"
}
}
]
},
}
The parameters don't pick up the color I set.
答案1
得分: 1
很抱歉,不支持翻译代码部分。你只能将 source.go
部分进行高亮显示。
英文:
Unfortunately it's not supported, all you can do is highlight source.go
.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论