function GetDisplayColors: integer; var tHDC: hdc; begin tHDC := GetDC(0); result := GetDeviceCaps(tHDC, 12) * GetDeviceCaps(tHDC, 14); ReleaseDC(0, tHDC); end;