Theme.Win10Dark Field
The Win10Dark theme.
Namespace: DevExpress.Xpf.Core
Assembly: DevExpress.Xpf.Core.v24.2.dll
NuGet Package: DevExpress.Wpf.Core
Declaration
Field Value
Type | Description |
---|---|
Theme | The Win10Dark theme (part of the Win10Category). |
Remarks
Apply Windows Colors to a Win10Dark/Light Theme
Pass a Win10Palette object as a parameter to a Theme.CreateTheme method to generate a theme based on a Win10Dark or Win10Light DevExpress theme. The palette allows you to get the following Windows theme settings, listen to their changes, and apply them to your application:
- Accent color
- App Mode (Dark/Light)
Refer to the following Microsoft help topic for more information: Change colors in Windows
The Win10Palette works with Windows 10 and higher. If the palette cannot find a Windows accent color or an app mode, the application accent color and app mode are set to #FF0078D7
and Light
, respectively.
The following code sample generates a new theme (based on the Win10Dark theme) with the Windows accent color and applies the theme on application startup:
protected override void OnStartup(StartupEventArgs e) {
var palette = new Win10Palette();
var theme = Theme.CreateTheme(palette, Theme.Win10Dark);
Theme.RegisterTheme(theme);
ApplicationThemeHelper.ApplicationThemeName = theme.Name;
base.OnStartup(e);
}