2

So, to change the color scheme of normal cmd and powershell windows I used this, and it works:

https://wiki.mbirth.de/know-how/software/windows/tango-colours-console.html

However, I cannot find any way to change the color scheme of powershell windows opened from the Win+X menu, they always use the default colors, is there any way to do this?

The shortcuts are under:

C:\Users\rkito\AppData\Local\Microsoft\Windows\WinX\Group3

I tried replacing them, but that doesn't work, they are some kind of special .lnk files.

1
  • C:\Users\rkito\AppData\Local\Microsoft\Windows\WinX\Group3 when opening from here the power shell windows opens in black color and from win key+x it opens in blue color ...so??
    – Elmo
    Jul 15 '19 at 10:15
4

When you are launching it manually and it works, it is done as admin user rkito, and that is indeed HKEY_CURRENT_USER in the registry. But Win+X stuff is ran under NT_AUTHORITY\SYSTEM so we will have to modify their registry keys, also.

Two HKEY_USERS subkeys are used by SYSTEM: S-1-5-19 is LocalService and S-1-5-20 is NetworkService. I also modify DEFAULT (==18) just to apply the setting to newly created users. And just to be safe. Blanket firing across all namespaces.

Solution: Replace HKEY_CURRENT_USER with HKEY_USERS\S-1-5-18 .. HKEY_USERS\S-1-5-20 to apply the color setting to all accounts.

Here is the entire *.reg file:

Windows Registry Editor Version 5.00

[HKEY_USERS\S-1-5-20\Console] ; Black "ColorTable00"=dword:00000000 ; Blue "ColorTable01"=dword:00a46534 ; Green "ColorTable02"=dword:00069a4e ; Cyan "ColorTable03"=dword:009a9806 ; Red "ColorTable04"=dword:000000cc ; Magenta "ColorTable05"=dword:007b5075 ; Yellow "ColorTable06"=dword:0000a0c4 ; White "ColorTable07"=dword:00cfd7d3 ; Dark Gray (Light Black) "ColorTable08"=dword:00535755 ; Light Blue "ColorTable09"=dword:00cf9f72 ; Light Green "ColorTable10"=dword:0034e28a ; Light Cyan "ColorTable11"=dword:00e2e234 ; Light Red "ColorTable12"=dword:002929ef ; Light Magenta "ColorTable13"=dword:00a87fad ; Light Yellow "ColorTable14"=dword:004fe9fc ; Light White "ColorTable15"=dword:00eceeee

[HKEY_USERS\S-1-5-19\Console] ; Black "ColorTable00"=dword:00000000 ; Blue "ColorTable01"=dword:00a46534 ; Green "ColorTable02"=dword:00069a4e ; Cyan "ColorTable03"=dword:009a9806 ; Red "ColorTable04"=dword:000000cc ; Magenta "ColorTable05"=dword:007b5075 ; Yellow "ColorTable06"=dword:0000a0c4 ; White "ColorTable07"=dword:00cfd7d3 ; Dark Gray (Light Black) "ColorTable08"=dword:00535755 ; Light Blue "ColorTable09"=dword:00cf9f72 ; Light Green "ColorTable10"=dword:0034e28a ; Light Cyan "ColorTable11"=dword:00e2e234 ; Light Red "ColorTable12"=dword:002929ef ; Light Magenta "ColorTable13"=dword:00a87fad ; Light Yellow "ColorTable14"=dword:004fe9fc ; Light White "ColorTable15"=dword:00eceeee

[HKEY_USERS\S-1-5-18\Console] ; Black "ColorTable00"=dword:00000000 ; Blue "ColorTable01"=dword:00a46534 ; Green "ColorTable02"=dword:00069a4e ; Cyan "ColorTable03"=dword:009a9806 ; Red "ColorTable04"=dword:000000cc ; Magenta "ColorTable05"=dword:007b5075 ; Yellow "ColorTable06"=dword:0000a0c4 ; White "ColorTable07"=dword:00cfd7d3 ; Dark Gray (Light Black) "ColorTable08"=dword:00535755 ; Light Blue "ColorTable09"=dword:00cf9f72 ; Light Green "ColorTable10"=dword:0034e28a ; Light Cyan "ColorTable11"=dword:00e2e234 ; Light Red "ColorTable12"=dword:002929ef ; Light Magenta "ColorTable13"=dword:00a87fad ; Light Yellow "ColorTable14"=dword:004fe9fc ; Light White "ColorTable15"=dword:00eceeee

[HKEY_USERS\.DEFAULT\Console] ; Black "ColorTable00"=dword:00000000 ; Blue "ColorTable01"=dword:00a46534 ; Green "ColorTable02"=dword:00069a4e ; Cyan "ColorTable03"=dword:009a9806 ; Red "ColorTable04"=dword:000000cc ; Magenta "ColorTable05"=dword:007b5075 ; Yellow "ColorTable06"=dword:0000a0c4 ; White "ColorTable07"=dword:00cfd7d3 ; Dark Gray (Light Black) "ColorTable08"=dword:00535755 ; Light Blue "ColorTable09"=dword:00cf9f72 ; Light Green "ColorTable10"=dword:0034e28a ; Light Cyan "ColorTable11"=dword:00e2e234 ; Light Red "ColorTable12"=dword:002929ef ; Light Magenta "ColorTable13"=dword:00a87fad ; Light Yellow "ColorTable14"=dword:004fe9fc ; Light White "ColorTable15"=dword:00eceeee

Edit reason: \. escape sequence caught me off guard.

3
  • 1
    for whatever reason it did not work for me, but I just converted the values to decimal and set it manually and then it works Sep 5 '19 at 20:19
  • Thank you for the follow-up. By manually setting it do you mean you did it via regedit, or simply using the "Defaults" GUI of cmd.exe? The one titled: Console Windows Properties / "Command Prompt" Properties
    – 3ICE
    Sep 6 '19 at 21:49
  • I used the properties menu of the console. I clicked on the colors and put in the decimal values. I did this twice, once for running powershell from win+r and once for the powershell menu entry, which also worked for win+x entry. Sep 8 '19 at 13:35
0

"powershell windows opened from the Win+X menu, they always use the default colors" - not true I just changed it. near window title Right click >Properties>Colors Tab . then select the color you want.Close and open again.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.