How do I change the default colors in a console? #12106
|
In a CMD console, with white text (37) on a black background (40), I can issue Microsoft Windows 10 Pro for Workstations |
Replies: 19 comments
|
|
|
I don't understand. Color 07 is the default when CMD is started. I want to change that to 70. But ^[[0m keeps changing it back to 07. |
|
Black on white: In registry (example of mine): And, this is for "dark" terminal color scheme. |
|
I want to change the default colors and I want ^[[0m to use the new default colors. |
Change color settings in console window preferences.
This end of escape-sequences -- reset to default |
|
I want to change the default for only the current console. I want ^[[0m to have a new meaning for only the current console. |
|
I want to change what ^[[0m means. |
|
|
Are you saying I cannot change the defaults (ESC[0m) on the fly and temporarily? |
|
You can but it is necessary to take into account the fact that |
|
If I can't change what ESC[0m does then I guess I can't change the defaults. In WindowsTerminal I can change the whole palette (OSC4, 10, 11, 12) and ESC[0m respects such a change. My conhost.exe (from Windows 10.0.19044.1415 (2009, 21H2)) does not accept those sequences. OpenConsole.exe (from WTPreview 1.12) does accept them. Do you know whether the conhost.exe from the latest insider build accepts them? |
Do not use
|
echo ^[]4;0;rgb:FD/F6/E3^G^[]4;7;rgb:93/A1/A1^G |
|
Thanks, Luan Vitor Simião Oliveira (@LuanVSO). Yesterday I tried getting the OSC sequences to work, but I couldn't. I should have remembered (and didn't) that "chaining" them (as in echo I have rather long (chained) sequences for each of WT's eight themes. Today I'll work on "un-chaining" them so they will work in the stock console. Can anyone comment on how the insider version of conhost behaves in this respect? |
|
Alright so this question got a little off the rails.
It's likely that the fix to allow for chaining this specific sequence is in Terminal #11126 also has some related discussion. I think that should answer your question? |
|
This issue has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for 4 days. It will be closed if no further activity occurs within 3 days of this comment. |






Alright so this question got a little off the rails.
It's likely that the fix to allow for chaining this specific sequence is in Terminal
openconsole.exe's but not ones that ship with the OS quite yet. There's a whole pile of issues about this that are broadly tracked in #942. I bet that #7578 was the PR that first implemented this in 1.5, but I don't think that's in the OS quite yet. There's not a rigorous timeline by which bugfixes flow from the Terminal repo to the OS one.#11126 also has some related discussion.
I think that should answer your question?