Module: delite/hc

delite/hc

Test if computer is in high contrast mode (i.e. if CSS color settings are ignored) Defines has("highcontrast") and sets d-hc CSS class on <body> if machine is in high contrast mode.

Normally this code should not be used. As long as widgets or applications avoid using background images for icons, the browser will do everything for high contrast mode automatically. The exception is for SVG, which the browser does not adjust.

If the OS is in high contrast mode and the browser obeys the OS setting, has("highcontrast") is the color that text appears as. Otherwise, has("highcontrast") is null.

Module returns has() method.

Show inherited