2

I couldn't find a solution so I ask a new question for this. I need to change the color of my error messages in visual studio code.

enter image description here

The problem is that the text color of the error message doesn't have enough contrast. Unfortunately I can't find out what I need to change in my settings.json. I was looking for something like:

"workbench.colorCustomizations" : {
    "terminalCursor.errorColorFont" : "#ffffff"
}

Thanks for your help!

EvilBurrito
  • 823
  • 8
  • 14
  • 1
    Probably [this answer](https://stackoverflow.com/a/55077651/9110128) may help? – Joey May 06 '19 at 22:27
  • I don't think that it is the perfect solution, because whenever the program uses this defined color somewhere else it will also be different there. For the moment your solution helps. Thank you! – EvilBurrito May 07 '19 at 10:57

3 Answers3

4

Same problem here. This worked for me.

"workbench.colorCustomizations" : {
    "terminal.ansiRed": "#f88"
}
Simon Bingham
  • 1,205
  • 11
  • 15
  • nice color pick btw – Shanimal Jul 23 '20 at 18:50
  • 2
    "terminal.ansiBrightRed": "#FF7F50" The color is Coral which displays well on dark backgrounds when you remote into a desktop. Due to the bitmap compression Red on Blue is difficult to see. – AMissico Jul 16 '21 at 21:01
0

The following setting helped me: Terminal › Integrated: Minimum Contrast Ratio

When set the foreground color of each cell will change to try meet the contrast ratio specified. Example values:

1: The default, do nothing. 4.5: WCAG AA compliance (minimum). 7: WCAG AAA compliance (enhanced). 21: White on black or black on white.

I changed the value to 7 and the dark red became a coral color with good contrast. The advantage of this is it will also apply to other low-contrast background/foreground combinations.

Pines
  • 396
  • 1
  • 8
0

The best solution to this problem is go to settings type "color custo" go to appearance select settings.json file under "workbench.colorCustomizations" paste the following key : value as shown

//"terminal.background":"#000000",
        "terminal.foreground":"#10e92d",
        "terminalCursor.background ":"#E0E0E0",
        "terminalCursor.foreground":"#E0E0E0",
        "terminal.ansiBlack":"#000000",
        "terminal.ansiBlue":"#6FB3D2",
        "terminal.ansiBrightBlack":"#e41c1c",
        "terminal.ansiBrightBlue":"#6FB3D2",
        "terminal.ansiBrightCyan":"#76C7B7",
        "terminal.ansiBrightGreen":"#A1C659",
        "terminal.ansiBrightMagenta":"#D381C3",
        "terminal.ansiBrightRed":"#FB0120",
        "terminal.ansiBrightWhite":"#FFFFFF",
        "terminal.ansiBrightYellow":"#FDA331",
        "terminal.ansiCyan":"#76C7B7",
        "terminal.ansiGreen":"#A1C659",
        "terminal.ansiMagenta":"#D381C3",
        "terminal.ansiRed":"#FB0120",
        "terminal.ansiWhite":"#E0E0E0",
        "terminal.ansiYellow":"#FDA331"
   

I hope this will meet your requirements.

Peter Csala
  • 17,736
  • 16
  • 35
  • 75
nqvadi
  • 1
  • 1
  • Your answer could be improved with additional supporting information. Please [edit] to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers [in the help center](/help/how-to-answer). – Community Mar 09 '22 at 08:02