Reputation: 21316
I just installed VS Code 1.70.0 on a new machine, and imported settings by copying settings.json
from the old machine. I opened a Markdown (.md
) file, and oddly the code segments marked with backtick characters are very hard to see. For example, both "foo" and "bar" below appear to be the same style.
foo `bar`
I zoomed in with the magnifier, but even then the style looks almost identical to the other text—the red color is very faint. This is the same monitor as before, so maybe it is related to the video driver on the new computer.
Is there some way to tweak the syntax highlighting just for inline code formatting for Markdown in VS Code?
Upvotes: 2
Views: 5993
Reputation: 3256
Yes, you can tweak the color by:
Go to Command Palette and find "Preferences: Open User Settings (JSON)"
In the settings.json
that it opened, add the following field:
"editor.tokenColorCustomizations": {
"[YOUR COLOR SCHEME]": {
"textMateRules": [
{
"scope": "markup.inline.raw.string.markdown",
"settings": {
"foreground": "#aaff00", // <-- Change your color here
}
}
]
}
}
In the 2nd line of the above code, change YOUR COLOR SCHEME
to the name of the color scheme you are using. For example, my color scheme is called "Monokai Pro" so the 2nd line would be:
"[Monokai Pro]" : {
Change the color to whatever you like in the "foreground"
field. For example, I'm using #aaff00
(lime color) and this is how it looks like:
You may wonder how do I know that the "scope"
field should be "markup.inline.raw.string.markdown"
. To see which TextMate scope that the markup inline code belongs to:
Open Command Palette and search for "Developer: Inspect Editor Tokens and Scopes"
Place your mouse caret inside the markdown inline code
Upvotes: 16