Modern WPF Themes (like Visual Studio 2012 or later).
Modern WPF Themes (like Visual Studio 2012 or later).
UI control libraries for create WPF window like Visual Studio 2012/2013/2015.
Install NuGet package(s).
PM> Install-Package MetroRadianceusing MetroRadiance.Interop;// Get system dpi
var systemDpi = window.GetSystemDpi();
if (PerMonitorDpi.IsSupported)
{
// Get monitor dpi.
var hwndSource = (HwndSource)PresentationSource.FromVisual(this);
var monitorDpi = hwndSource.GetDpi();
}using MetroRadiance.Platform;// Get Windows accent color
var color = WindowsTheme.GetAccentColor();
// Subscribe accent color change event from Windows theme.
var disposable = WindowsTheme.RegisterAccentColorListener(color =>
{
// apply color to your app.
});
// Unsubscribe color change event.
disposable.Dispose();using MetroRadiance.Media;// Get Windows accent color (using MetroRadiance.Platform;)
var rgbColor = WindowsTheme.GetAccentColor();
// Convert from RGB to HSV color.
var hsvColor = rgbColor.ToHsv();
hsvColor.V *= 0.8;
// Convert from HSV to RGB color.
var newColor = hsvColor.ToRgb();MetroRadiance.Chrome.WindowChrome
MetroRadiance.Chrome.WindowChrome.Top / .Left / .Right / .Bottom
// Change theme.
ThemeService.Current.ChangeTheme(Theme.Dark);
// Change theme (sync Windows)
ThemeService.Current.ChangeTheme(Theme.Windows);
// Change Accent
ThemeService.Current.ChangeAccent(Accent.Blue);
// Change accent (sync Windows)
ThemeService.Current.ChangeAccent(Accent.Windows);
// Change accent (from RGB Color)
var accent = Colors.Red.ToAccent();
ThemeService.Current.ChangeAccent(accent);This library is under the MIT License (MIT).
No open issues yet, or sync has not completed.