Test Area Index

Windows & Web Colour Setting Bugs

This page illustrates the difficulties involved in using a Windows colour scheme based on white text on a black background.  It uses legacy Windows 2000 Professional & the then current W7 Beta, and Microsoft websites as examples, but, as far as I am aware, every version of Windows since 3 to the present day has suffered from this sort of problem, and the number of websites that fail to set colours properly is so large that the only realistic explanation is that there is at least one major piece of web-authoring software, more probably several, that still fail in this respect.

Note:

I suggest the following rules for getting this right:

  1. NEVER set just one or other colour explicitly and let the other default, either set both explicitly or let them both default.
  2. If you want to set colours explicitly via CSS, but avoid multiple explicit rules covering obscure situations not all of which you will manage to predict, you could try experimenting with the following rules at the top of your stylesheet:
    * { color:inherit; background-color:inherit; }
    @media screen { body { color:#<RRGGBB>; background-color:#<RRGGBB>; } }
    @media print { body { color:#000000; background-color:#FFFFFF; } }
    This may entail redesigning your colour scheme from the top down, and there will still be elements such as <hr /> and, particularly, form elements for which colour inheritance may be ignored by some browsers (so any such elements used will need to be included after the body selector), nevertheless the above usually results in a simpler rule set while giving more general confidence that things will only look different when a rule explicitly tells them to, rather than content becoming unreadable in obscure situations.
  3. Specifically test the result on a PC where you have set the desktop colour scheme to have white text on a black background, for example you could try the W2k settings listed (although they may not work on more recent versions of Windows), which come from the registry key:
    HKEY_CURRENT_USER\Control Panel\Colors

Results

Windows 2000
Control PanelResulting Settings
Windows 2000 Professional - Control Panel Colour Settings "ActiveBorder"="131 153 177"
"ActiveTitle"="79 101 125"
"AppWorkSpace"="128 128 128"
"Background"="0 0 0"
"ButtonAlternateFace"="192 192 192"
"ButtonDkShadow"="0 0 0"
"ButtonFace"="131 153 177"
"ButtonHilight"="193 204 217"
"ButtonLight"="131 153 177"
"ButtonShadow"="79 101 125"
"ButtonText"="255 255 255"
"GradientActiveTitle"="128 180 208"
"GradientInactiveTitle"="176 188 208"
"GrayText"="79 101 125"
"Hilight"="79 101 125"
"HilightText"="255 255 255"
"HotTrackingColor"="0 0 255"
"InactiveBorder"="131 153 177"
"InactiveTitle"="128 128 128"
"InactiveTitleText"="193 204 217"
"InfoText"="0 0 0"
"InfoWindow"="255 255 255"
"Menu"="131 153 177"
"MenuText"="0 0 0"
"Scrollbar"="193 204 217"
"TitleText"="255 255 255"
"Window"="0 0 0"
"WindowFrame"="0 0 0"
"WindowText"="255 255 255"
Web Result
Windows 2000 Pro - Firefox 3 - Microsoft Forum Thread
Windows 7 Beta
Control PanelResulting 'Settings'
Windows 7 Beta - Control Panel Colour Settings "ActiveBorder"="43 85 85"
"ActiveTitle"="29 56 56"
"AppWorkSpace"="0 0 0"
"Background"="0 0 0"
"ButtonAlternateFace"="0 0 0"
"ButtonDkShadow"="105 105 105"
"ButtonFace"="43 85 85"
"ButtonHilight"="128 191 191"
"ButtonLight"="43 85 85"
"ButtonShadow"="29 56 56"
"ButtonText"="0 0 0"
"GradientActiveTitle"="43 85 85"
"GradientInactiveTitle"="0 0 0"
"GrayText"="128 128 128"
"Hilight"="0 0 128"
"HilightText"="255 255 255"
"HotTrackingColor"="255 255 0"
"InactiveBorder"="43 85 85"
"InactiveTitle"="128 128 128"
"InactiveTitleText"="192 192 192"
"InfoText"="255 255 255"
"InfoWindow"="0 128 128"
"Menu"="43 85 85"
"MenuBar"="240 240 240"
"MenuHilight"="51 153 255"
"MenuText"="0 0 0"
"Scrollbar"="128 191 191"
"TitleText"="255 255 255"
"Window"="0 0 0"
"WindowFrame"="100 100 100"
"WindowText"="255 255 255"
Web Result
Windows 7 Beta - IE 8 Beta - Microsoft Forum Thread