Gets or sets a value that determines the light-dark preference for the overall theme of an app.
Syntax
<application RequestedTheme="applicationThemeMemberName" .../>
Property value
Type: ApplicationTheme
A value of the enumeration.
Remarks
Windows Store apps support two built in themes: "Light" and "Dark". By default your application runs using the "Dark" theme. You can set the app's RequestedTheme property to specify which theme is used.
The theme can only be set when the app is started, not while it’s running. If you give the user an option to pick a theme, you must save the setting in the app data and apply it when the app is restarted.
This property is ignored if the user is running in high contrast mode. The high-contrast themes also include "Light" and "Dark" in the names but they're different themes and are enabled using a different API. See Supporting high contrast themes and XAML high contrast style sample.
A small number of resources that are theme-specific are defined in the ThemeDictionaries property of the primary ResourceDictionary that is used for control templates. This might be StandardStyles.xaml for an app, or generic.xaml for a custom control. Brush resources are also theme-specific, but these aren't defined in StandardStyles.xaml and ThemeDictionaries. Instead these are system theme resources, which you can reference but not override.
Requirements
|
Minimum supported client | Windows 8 |
|---|---|
|
Minimum supported server | Windows Server 2012 |
|
Namespace |
|
|
Metadata |
|
See also
Build date: 1/31/2013