IF virtual.hasColorDisplay
AND WindowManager.colorDisplayOn
THEN {
m: Terminal.ColorMode = Terminal.GetColorMode[virtual];
IF m.full OR m.bitsPerPixelChannelA<4 THEN RETURN;
[] ← Terminal.SetColorCursorPresentation[virtual, onesAreWhite];
ColorMap.SetRGBColor[index: 0, r:0, g:0, b:0]; -- [black] background
ColorMap.SetRGBColor[index: 1, r:0, g:1, b:0]; -- [green] diff
ColorMap.SetRGBColor[index: 2, r:0, g:0, b:1]; -- [blue] met
ColorMap.SetRGBColor[index: 4, r:1, g:0, b:0]; -- [red] poly
ColorMap.SetRGBColor[index: 8, r:0.9, g:0.9, b:0];
ColorMap.SetRGBColor[index: 3, r:0, g:0.4, b:0.7]; -- met+diff
ColorMap.SetRGBColor[index: 5, r:0.8, g:0.3, b:0]; -- poly+diff
ColorMap.SetRGBColor[index: 6, r:0.5, g:0, b:0.5]; -- poly+met
ColorMap.SetRGBColor[index: 7, r:0.8, g:0.3, b:0.6]; -- poly+diff+met
ColorMap.SetRGBColor[index: 9, r:0.9, g:0.8, b:0.9]; --nearly background
ColorMap.SetRGBColor[index: 10, r:0.8, g:0.9, b:0.8]; -- nearly background
ColorMap.SetRGBColor[index: 11, r:0.0, g:0.9, b:0.8];
ColorMap.SetRGBColor[index: 12, r:1, g:0.2, b:0.2];
ColorMap.SetRGBColor[index: 13, r:1, g:1, b:0.2];
ColorMap.SetRGBColor[index: 14, r:1, g:1, b:0.0]; -- [yellow] imp
ColorMap.SetRGBColor[index: (IF m.bitsPerPixelChannelA=8 THEN 255 ELSE 15), r:1, g:1, b:1];
};