
In App.xaml, create a ThemeDictionaries collection with both a Default and a HighContrast ResourceDictionary (a Light ResourceDictionary is not necessary for this example). Creating theme dictionariesĪ ResourceDictionary.ThemeDictionaries object can indicate theme colors that are different from the system-defined colors by specifying brushes for the Default (Dark), Light, and HighContrast contrast themes.Ĭontrast theme refers to the feature in general, while HighContrast refers to the specific dictionary being referenced. You can programmatically check if the current theme is a contrast theme through the AccessibilitySettings class (you must call the AccessibilitySettings constructor from a scope where the app is initialized and is already displaying content).

If you are using brushes correctly, this setting should be turned off. This sets all text color to white with a solid black highlight behind it, ensuring sufficient contrast against all backgrounds. Windows apps have HighContrastAdjustment turned on by default.

If you have not selected a theme previously, the Aquatic theme is used by default (shown in the following image). You can also press the left-Alt key + Shift key + Print screen (PrtScn on some keyboards) to quickly turn contrast themes on or off.
