public static void SetMahApps(this ResourceDictionary resourceDictionary, ITheme theme, BaseTheme baseTheme)
        {
            resourceDictionary.SetMahAppsBaseTheme(baseTheme);

            resourceDictionary.SetBrush("HighlightBrush", theme.PrimaryDark.Color);
            resourceDictionary.SetBrush("AccentColorBrush", theme.PrimaryDark.Color);
            resourceDictionary.SetBrush("AccentColorBrush2", theme.PrimaryMid.Color);
            resourceDictionary.SetBrush("AccentColorBrush3", theme.PrimaryLight.Color);
            resourceDictionary.SetBrush("AccentColorBrush4", theme.PrimaryLight.Color, 0.82);
            resourceDictionary.SetBrush("WindowTitleColorBrush", theme.PrimaryDark.Color);
            resourceDictionary.SetBrush("AccentSelectedColorBrush", theme.PrimaryDark.GetForegroundColor());
            resourceDictionary.SetBrush("ProgressBrush", new LinearGradientBrush(theme.PrimaryDark.Color, theme.PrimaryMid.Color, 90.0));
            resourceDictionary.SetBrush("CheckmarkFill", theme.PrimaryDark.Color);
            resourceDictionary.SetBrush("RightArrowFill", theme.PrimaryDark.Color);
            resourceDictionary.SetBrush("IdealForegroundColorBrush", theme.PrimaryDark.GetForegroundColor());
            resourceDictionary.SetBrush("IdealForegroundDisabledBrush", theme.PrimaryDark.GetForegroundColor(), 0.4);
        }
Example #2
0
        public static void SetMahApps(this ResourceDictionary resourceDictionary, ITheme theme, BaseTheme baseTheme)
        {
            resourceDictionary.SetMahAppsBaseTheme(baseTheme);

            resourceDictionary.SetBrush("Theme.ShowcaseBrush", new SolidColorBrush(theme.SecondaryMid.Color));

            resourceDictionary.SetColor("MahApps.Colors.HighlightLight", theme.PrimaryLight.Color);
            resourceDictionary.SetColor("MahApps.Colors.Highlight", theme.PrimaryMid.Color);
            resourceDictionary.SetColor("MahApps.Colors.HighlightDark", theme.PrimaryDark.Color);
            resourceDictionary.SetColor("MahApps.Colors.AccentBase", theme.SecondaryDark.Color);
            resourceDictionary.SetColor("MahApps.Colors.Accent", theme.SecondaryMid.Color);
            resourceDictionary.SetColor("MahApps.Colors.Accent2", theme.SecondaryMid.Color);
            resourceDictionary.SetColor("MahApps.Colors.Accent3", theme.SecondaryLight.Color);
            resourceDictionary.SetColor("MahApps.Colors.Accent4", theme.SecondaryLight.Color);

            resourceDictionary.SetColor("MahApps.Colors.ProgressIndeterminate1", Color.FromArgb(0x33, 0x87, 0x87, 0x87));
            resourceDictionary.SetColor("MahApps.Colors.ProgressIndeterminate2", Color.FromArgb(0x33, 0x95, 0x95, 0x95));
            resourceDictionary.SetColor("MahApps.Colors.ProgressIndeterminate3", Color.FromArgb(0x4C, 0x00, 0x00, 0x00));
            resourceDictionary.SetColor("MahApps.Colors.ProgressIndeterminate4", Color.FromArgb(0x4C, 0x00, 0x00, 0x00));

            resourceDictionary.SetBrush("MahApps.Brushes.Control.Background", (Color)resourceDictionary["MahApps.Colors.White"]);
            resourceDictionary.SetBrush("MahApps.Brushes.White", (Color)resourceDictionary["MahApps.Colors.White"]);
            resourceDictionary.SetBrush("MahApps.Brushes.Black", (Color)resourceDictionary["MahApps.Colors.Black"]);
            resourceDictionary.SetBrush("MahApps.Brushes.Text", (Color)resourceDictionary["MahApps.Colors.Black"]);
            resourceDictionary.SetBrush("MahApps.Brushes.Label.Text", (Color)resourceDictionary["MahApps.Colors.Black"]);
            resourceDictionary.SetBrush("MahApps.Brushes.WhiteColor", (Color)resourceDictionary["MahApps.Colors.White"]);
            resourceDictionary.SetBrush("MahApps.Brushes.BlackColor", (Color)resourceDictionary["MahApps.Colors.Black"]);

            resourceDictionary.SetBrush("MahApps.Brushes.WindowTitle", (Color)resourceDictionary["MahApps.Colors.HighlightDark"]);
            resourceDictionary.SetBrush("MahApps.Brushes.WindowTitle.NonActive", Color.FromRgb(0x80, 0x80, 0x80));
            resourceDictionary.SetBrush("MahApps.Brushes.Border.NonActive", Color.FromRgb(0x80, 0x80, 0x80));

            resourceDictionary.SetBrush("MahApps.Brushes.Highlight", (Color)resourceDictionary["MahApps.Colors.Highlight"]);
            resourceDictionary.SetBrush("MahApps.Brushes.DisabledWhite", (Color)resourceDictionary["MahApps.Colors.White"]);

            resourceDictionary.SetBrush("MahApps.Brushes.TransparentWhite", Color.FromArgb(0x00, 0xFF, 0xFF, 0xFF));
            resourceDictionary.SetBrush("MahApps.Brushes.SemiTransparentWhite", Color.FromArgb(0x55, 0xFF, 0xFF, 0xFF));
            resourceDictionary.SetBrush("MahApps.Brushes.SemiTransparentGray", Color.FromArgb(0x40, 0x80, 0x80, 0x80));
            resourceDictionary.SetBrush("MahApps.Brushes.Controls.Disabled", Color.FromArgb(0xA5, 0xFF, 0xFF, 0xFF));

            resourceDictionary.SetBrush("MahApps.Brushes.AccentBase", (Color)resourceDictionary["MahApps.Colors.AccentBase"]);
            resourceDictionary.SetBrush("MahApps.Brushes.Accent", (Color)resourceDictionary["MahApps.Colors.Accent"]);
            resourceDictionary.SetBrush("MahApps.Brushes.Accent2", (Color)resourceDictionary["MahApps.Colors.Accent2"]);
            resourceDictionary.SetBrush("MahApps.Brushes.Accent3", (Color)resourceDictionary["MahApps.Colors.Accent3"]);
            resourceDictionary.SetBrush("MahApps.Brushes.Accent4", (Color)resourceDictionary["MahApps.Colors.Accent4"]);

            resourceDictionary.SetBrush("MahApps.Brushes.Gray1", (Color)resourceDictionary["MahApps.Colors.Gray1"]);
            resourceDictionary.SetBrush("MahApps.Brushes.Gray2", (Color)resourceDictionary["MahApps.Colors.Gray2"]);
            resourceDictionary.SetBrush("MahApps.Brushes.Gray3", (Color)resourceDictionary["MahApps.Colors.Gray3"]);
            resourceDictionary.SetBrush("MahApps.Brushes.Gray4", (Color)resourceDictionary["MahApps.Colors.Gray4"]);
            resourceDictionary.SetBrush("MahApps.Brushes.Gray5", (Color)resourceDictionary["MahApps.Colors.Gray5"]);
            resourceDictionary.SetBrush("MahApps.Brushes.Gray6", (Color)resourceDictionary["MahApps.Colors.Gray6"]);
            resourceDictionary.SetBrush("MahApps.Brushes.Gray7", (Color)resourceDictionary["MahApps.Colors.Gray7"]);
            resourceDictionary.SetBrush("MahApps.Brushes.Gray8", (Color)resourceDictionary["MahApps.Colors.Gray8"]);
            resourceDictionary.SetBrush("MahApps.Brushes.Gray9", (Color)resourceDictionary["MahApps.Colors.Gray9"]);
            resourceDictionary.SetBrush("MahApps.Brushes.Gray10", (Color)resourceDictionary["MahApps.Colors.Gray10"]);

            resourceDictionary.SetBrush("MahApps.Brushes.GrayNormal", (Color)resourceDictionary["MahApps.Colors.GrayNormal"]);
            resourceDictionary.SetBrush("MahApps.Brushes.GrayHover", (Color)resourceDictionary["MahApps.Colors.GrayHover"]);

            resourceDictionary.SetBrush("MahApps.Brushes.Controls.Border", (Color)resourceDictionary["MahApps.Colors.Gray6"]);
            resourceDictionary.SetBrush("MahApps.Brushes.TextBox.Border", theme.TextBoxBorder);
            resourceDictionary.SetBrush("MahApps.Brushes.TextBox.MouseOverInnerBorder", (Color)resourceDictionary["MahApps.Colors.Black"]);
            resourceDictionary.SetBrush("MahApps.Brushes.TextBox.FocusBorder", (Color)resourceDictionary["MahApps.Colors.Black"]);
            resourceDictionary.SetBrush("MahApps.Brushes.TextBox.MouseOverBorder", theme.PrimaryMid.Color);

            resourceDictionary.SetBrush("MahApps.Brushes.Button.MouseOverBorder", (Color)resourceDictionary["MahApps.Colors.Black"]);
            resourceDictionary.SetBrush("MahApps.Brushes.Button.MouseOverInnerBorder", (Color)resourceDictionary["MahApps.Colors.Black"]);
            resourceDictionary.SetBrush("MahApps.Brushes.ComboBox.MouseOverBorder", (Color)resourceDictionary["MahApps.Colors.Black"]);
            resourceDictionary.SetBrush("MahApps.Brushes.ComboBox.MouseOverInnerBorder", (Color)resourceDictionary["MahApps.Colors.Black"]);
            resourceDictionary.SetBrush("MahApps.Brushes.ComboBox.PopupBorder", (Color)resourceDictionary["MahApps.Colors.Gray4"]);

            resourceDictionary.SetBrush("MahApps.Brushes.CheckBox", (Color)resourceDictionary["MahApps.Colors.Gray6"]);
            resourceDictionary.SetBrush("MahApps.Brushes.CheckBox.MouseOver", (Color)resourceDictionary["MahApps.Colors.Gray2"]);

            resourceDictionary.SetBrush("MahApps.Brushes.CheckBox.Background", new LinearGradientBrush {
                StartPoint    = new Point(0.5, 0),
                EndPoint      = new Point(0.5, 1),
                GradientStops = new GradientStopCollection
                {
                    new GradientStop((Color)resourceDictionary["MahApps.Colors.Gray7"], 0),
                    new GradientStop((Color)resourceDictionary["MahApps.Colors.White"], 1)
                }
            });
            resourceDictionary.SetBrush("MahApps.Brushes.Thumb", (Color)resourceDictionary["MahApps.Colors.Gray5"]);

            resourceDictionary.SetBrush("MahApps.Brushes.Progress", new LinearGradientBrush {
                StartPoint    = new Point(1.002, 0.5),
                EndPoint      = new Point(0.001, 0.5),
                GradientStops = new GradientStopCollection
                {
                    new GradientStop((Color)resourceDictionary["MahApps.Colors.Highlight"], 0),
                    new GradientStop((Color)resourceDictionary["MahApps.Colors.Accent3"], 1)
                }
            });
            resourceDictionary.SetBrush("MahApps.Brushes.SliderValue.Disabled", (Color)resourceDictionary["MahApps.Colors.SliderValue.Disabled"]);
            resourceDictionary.SetBrush("MahApps.Brushes.SliderTrack.Disabled", (Color)resourceDictionary["MahApps.Colors.SliderTrack.Disabled"]);
            resourceDictionary.SetBrush("MahApps.Brushes.SliderThumb.Disabled", (Color)resourceDictionary["MahApps.Colors.SliderThumb.Disabled"]);
            resourceDictionary.SetBrush("MahApps.Brushes.SliderTrack.Hover", (Color)resourceDictionary["MahApps.Colors.SliderTrack.Hover"]);
            resourceDictionary.SetBrush("MahApps.Brushes.SliderTrack.Normal", (Color)resourceDictionary["MahApps.Colors.SliderTrack.Normal"]);

            resourceDictionary.SetBrush("MahApps.Brushes.Flyout.Background", (Color)resourceDictionary["MahApps.Colors.Flyout"]);
            resourceDictionary.SetBrush("MahApps.Brushes.Flyout.Foreground", (Color)resourceDictionary["MahApps.Colors.Black"]);

            resourceDictionary.SetBrush("MahApps.Brushes.Window.FlyoutOverlay", (Color)resourceDictionary["MahApps.Colors.Black"]);
            resourceDictionary.SetBrush("MahApps.Brushes.Window.Background", (Color)resourceDictionary["MahApps.Colors.White"]);
            resourceDictionary.SetBrush("MahApps.Brushes.Separator", Color.FromArgb(0xFF, 0xC4, 0xC4, 0xC5));

            resourceDictionary.SetBrush("MahApps.Brushes.FlatButton.Background", Color.FromRgb(0xD5, 0xD5, 0xD5));
            resourceDictionary.SetBrush("MahApps.Brushes.FlatButton.Foreground", Color.FromRgb(0x22, 0x22, 0x22));
            resourceDictionary.SetBrush("MahApps.Brushes.FlatButton.PressedBackground", (Color)resourceDictionary["MahApps.Colors.FlatButton.PressedBackground"]);
            resourceDictionary.SetBrush("MahApps.Brushes.FlatButton.PressedForeground", Colors.White);

            resourceDictionary.SetBrush("MahApps.Brushes.DarkIdealForegroundDisabled", Color.FromRgb(0xAD, 0xAD, 0xAD));
            resourceDictionary.SetBrush("MahApps.Brushes.CleanWindowCloseButton.Background", Color.FromRgb(0xEB, 0x2F, 0x2F));
            resourceDictionary.SetBrush("MahApps.Brushes.CleanWindowCloseButton.PressedBackground", Color.FromRgb(0x7C, 0x00, 0x00));

            //CONTROL VALIDATION BRUSHES
            resourceDictionary.SetBrush("MahApps.Brushes.Controls.Validation", Color.FromArgb(0xFF, 0xDB, 0x00, 0x0C));
            resourceDictionary.SetBrush("MahApps.Brushes.Validation1", Color.FromArgb(0x05, 0x2A, 0x2E, 0x31));
            resourceDictionary.SetBrush("MahApps.Brushes.Validation2", Color.FromArgb(0x15, 0x2A, 0x2E, 0x31));
            resourceDictionary.SetBrush("MahApps.Brushes.Validation3", Color.FromArgb(0x25, 0x2A, 0x2E, 0x31));
            resourceDictionary.SetBrush("MahApps.Brushes.Validation4", Color.FromArgb(0x35, 0x2A, 0x2E, 0x31));
            resourceDictionary.SetBrush("MahApps.Brushes.Validation5", Color.FromArgb(0xFF, 0xDC, 0x00, 0x0C));
            //unused
            resourceDictionary.SetBrush("MahApps.Brushes.ValidationSummary1", Color.FromArgb(0xFF, 0xDC, 0x02, 0x0D));
            resourceDictionary.SetBrush("MahApps.Brushes.ValidationSummary2", Color.FromArgb(0xFF, 0xCA, 0x00, 0x0C));
            resourceDictionary.SetBrush("MahApps.Brushes.ValidationSummary3", Color.FromArgb(0xFF, 0xFF, 0x92, 0x98));
            resourceDictionary.SetBrush("MahApps.Brushes.ValidationSummary4", Color.FromArgb(0xFF, 0xFD, 0xC8, 0xC8));
            resourceDictionary.SetBrush("MahApps.Brushes.ValidationSummary5", Color.FromArgb(0xDD, 0xD4, 0x39, 0x40));
            resourceDictionary.SetBrush("MahApps.Brushes.ValidationSummaryFill1", Color.FromArgb(0x59, 0xF7, 0xD8, 0xDB));
            resourceDictionary.SetBrush("MahApps.Brushes.ValidationSummaryFill2", Color.FromArgb(0xFF, 0xF7, 0xD8, 0xDB));
            //validation text foreground always white
            resourceDictionary.SetBrush("MahApps.Brushes.Text.Validation", Colors.White);

            //WPF default colors
            resourceDictionary.SetBrush("{x:Static SystemColors.WindowBrushKey}", (Color)resourceDictionary["MahApps.Colors.White"]);
            resourceDictionary.SetBrush("{x:Static SystemColors.ControlTextBrushKey}", (Color)resourceDictionary["MahApps.Colors.Black"]);

            //menu default colors
            resourceDictionary.SetBrush("MahApps.Brushes.Menu.Background", (Color)resourceDictionary["MahApps.Colors.White"]);
            resourceDictionary.SetBrush("MahApps.Brushes.ContextMenu.Background", (Color)resourceDictionary["MahApps.Colors.White"]);
            resourceDictionary.SetBrush("MahApps.Brushes.SubMenu.Background", (Color)resourceDictionary["MahApps.Colors.White"]);
            resourceDictionary.SetBrush("MahApps.Brushes.MenuItem.Background", (Color)resourceDictionary["MahApps.Colors.White"]);

            resourceDictionary.SetBrush("MahApps.Brushes.ContextMenu.Border", (Color)resourceDictionary["MahApps.Colors.Black"]);
            resourceDictionary.SetBrush("MahApps.Brushes.SubMenu.Border", (Color)resourceDictionary["MahApps.Colors.Black"]);

            resourceDictionary.SetBrush("MahApps.Brushes.MenuItem.SelectionFill", (Color)resourceDictionary["MahApps.Colors.MenuItem.SelectionFill"]);
            resourceDictionary.SetBrush("MahApps.Brushes.MenuItem.SelectionStroke", (Color)resourceDictionary["MahApps.Colors.MenuItem.SelectionStroke"]);

            resourceDictionary.SetBrush("MahApps.Brushes.TopMenuItem.PressedFill", (Color)resourceDictionary["MahApps.Colors.TopMenuItem.PressedFill"]);
            resourceDictionary.SetBrush("MahApps.Brushes.TopMenuItem.PressedStroke", (Color)resourceDictionary["MahApps.Colors.TopMenuItem.PressedStroke"]);
            resourceDictionary.SetBrush("MahApps.Brushes.TopMenuItem.SelectionStroke", (Color)resourceDictionary["MahApps.Colors.TopMenuItem.SelectionStroke"]);

            resourceDictionary.SetBrush("MahApps.Brushes.MenuItem.DisabledForeground", (Color)resourceDictionary["MahApps.Colors.MenuItem.DisabledForeground"]);
            resourceDictionary.SetBrush("MahApps.Brushes.MenuItem.DisabledGlyphPanel", Color.FromRgb(0x84, 0x85, 0x89));

            resourceDictionary.SetBrush("{x:Static SystemColors.MenuTextBrushKey}", (Color)resourceDictionary["MahApps.Colors.Black"]);

            resourceDictionary.SetBrush("MahApps.Brushes.CheckmarkFill", (Color)resourceDictionary["MahApps.Colors.Accent"]);
            resourceDictionary.SetBrush("MahApps.Brushes.RightArrowFill", (Color)resourceDictionary["MahApps.Colors.Accent"]);

            resourceDictionary.SetColor("MahApps.Colors.IdealForeground", theme.PrimaryMid.GetForegroundColor());
            resourceDictionary.SetBrush("MahApps.Brushes.IdealForeground", theme.PrimaryMid.GetForegroundColor());
            resourceDictionary.SetBrush("MahApps.Brushes.IdealForegroundDisabled", (Color)resourceDictionary["MahApps.Colors.IdealForeground"]);
            resourceDictionary.SetBrush("MahApps.Brushes.AccentSelectedColor", (Color)resourceDictionary["MahApps.Colors.IdealForeground"]);

            //DataGrid brushes

            resourceDictionary.SetBrush("MahApps.Brushes.DataGrid.Highlight", (Color)resourceDictionary["MahApps.Colors.Accent"]);
            resourceDictionary.SetBrush("MahApps.Brushes.DataGrid.DisabledHighlight", (Color)resourceDictionary["MahApps.Colors.Gray7"]);
            resourceDictionary.SetBrush("MahApps.Brushes.DataGrid.HighlightText", (Color)resourceDictionary["MahApps.Colors.IdealForeground"]);
            resourceDictionary.SetBrush("MahApps.Brushes.DataGrid.MouseOverHighlight", (Color)resourceDictionary["MahApps.Colors.Accent3"]);
            resourceDictionary.SetBrush("MahApps.Brushes.DataGrid.FocusBorder", (Color)resourceDictionary["MahApps.Colors.Accent"]);
            resourceDictionary.SetBrush("MahApps.Brushes.DataGrid.InactiveSelectionHighlight", (Color)resourceDictionary["MahApps.Colors.Accent2"]);
            resourceDictionary.SetBrush("MahApps.Brushes.DataGrid.InactiveSelectionHighlightText", (Color)resourceDictionary["MahApps.Colors.IdealForeground"]);

            resourceDictionary.SetBrush("MahApps.Brushes.ToggleSwitchButton.Pressed.Win10", (Color)resourceDictionary["MahApps.Colors.ToggleSwitchButton.Pressed.Win10"]);
            resourceDictionary.SetBrush("MahApps.Brushes.ToggleSwitchButton.OffBorder.Win10", (Color)resourceDictionary["MahApps.Colors.ToggleSwitchButton.OffBorder.Win10"]);
            resourceDictionary.SetBrush("MahApps.Brushes.ToggleSwitchButton.OffMouseOverBorder.Win10", (Color)resourceDictionary["MahApps.Colors.ToggleSwitchButton.OffMouseOverBorder.Win10"]);
            resourceDictionary.SetBrush("MahApps.Brushes.ToggleSwitchButton.OffDisabledBorder.Win10", (Color)resourceDictionary["MahApps.Colors.ToggleSwitchButton.OffDisabledBorder.Win10"]);
            resourceDictionary.SetBrush("MahApps.Brushes.ToggleSwitchButton.OffSwitch.Win10", Colors.Transparent);
            resourceDictionary.SetBrush("MahApps.Brushes.ToggleSwitchButton.OnSwitch.Win10", (Color)resourceDictionary["MahApps.Colors.Accent"]);
            resourceDictionary.SetBrush("MahApps.Brushes.ToggleSwitchButton.OnSwitchDisabled.Win10", (Color)resourceDictionary["MahApps.Colors.ToggleSwitchButton.OnSwitchDisabled.Win10"]);
            resourceDictionary.SetBrush("MahApps.Brushes.ToggleSwitchButton.OnSwitchMouseOver.Win10", (Color)resourceDictionary["MahApps.Colors.Accent2"]);
            resourceDictionary.SetBrush("MahApps.Brushes.ToggleSwitchButton.ThumbIndicator.Win10", (Color)resourceDictionary["MahApps.Colors.ToggleSwitchButton.ThumbIndicator.Win10"]);
            resourceDictionary.SetBrush("MahApps.Brushes.ToggleSwitchButton.ThumbIndicatorMouseOver.Win10", (Color)resourceDictionary["MahApps.Colors.ToggleSwitchButton.ThumbIndicatorMouseOver.Win10"]);
            resourceDictionary.SetBrush("MahApps.Brushes.ToggleSwitchButton.ThumbIndicatorChecked.Win10", (Color)resourceDictionary["MahApps.Colors.IdealForeground"]);
            resourceDictionary.SetBrush("MahApps.Brushes.ToggleSwitchButton.ThumbIndicatorPressed.Win10", (Color)resourceDictionary["MahApps.Colors.ToggleSwitchButton.ThumbIndicatorPressed.Win10"]);
            resourceDictionary.SetBrush("MahApps.Brushes.ToggleSwitchButton.ThumbIndicatorDisabled.Win10", (Color)resourceDictionary["MahApps.Colors.ToggleSwitchButton.ThumbIndicatorDisabled.Win10"]);

            resourceDictionary.SetBrush("MahApps.Brushes.Badged.DisabledBackground", (Color)resourceDictionary["MahApps.Colors.Badged.DisabledBackground"]);

            //HamburgerMenu

            resourceDictionary.SetBrush("MahApps.HamburgerMenu.PaneBackground", Color.FromArgb(0xFF, 0x44, 0x44, 0x44));
            resourceDictionary.SetBrush("MahApps.HamburgerMenu.PaneForeground", Color.FromArgb(0xFF, 0xFF, 0xFF, 0xFF));
        }
        public static void SetMahApps(this ResourceDictionary resourceDictionary, ITheme theme, BaseTheme baseTheme)
        {
            resourceDictionary.SetMahAppsBaseTheme(baseTheme);

            resourceDictionary.SetBrush("HighlightBrush", theme.PrimaryDark.Color);
            resourceDictionary.SetBrush("AccentBaseColorBrush", theme.PrimaryDark.Color);
            resourceDictionary.SetBrush("AccentColorBrush", theme.PrimaryDark.Color);
            resourceDictionary.SetBrush("AccentColorBrush2", theme.PrimaryMid.Color, 0.8);
            resourceDictionary.SetBrush("AccentColorBrush3", theme.PrimaryLight.Color);
            resourceDictionary.SetBrush("AccentColorBrush4", theme.PrimaryLight.Color, 0.8);
            resourceDictionary.SetBrush("WindowTitleColorBrush", theme.PrimaryDark.Color);
            resourceDictionary.SetBrush("AccentSelectedColorBrush", theme.PrimaryMid.GetForegroundColor());
            resourceDictionary.SetBrush("ProgressBrush", new LinearGradientBrush(theme.PrimaryDark.Color, theme.PrimaryMid.Color, 90.0));
            resourceDictionary.SetBrush("CheckmarkFill", theme.PrimaryMid.Color);
            resourceDictionary.SetBrush("RightArrowFill", theme.PrimaryMid.Color);
            resourceDictionary.SetBrush("IdealForegroundColorBrush", theme.PrimaryMid.GetForegroundColor());
            resourceDictionary.SetBrush("IdealForegroundDisabledBrush", theme.PrimaryDark.GetForegroundColor(), 0.4);

            resourceDictionary.SetBrush("MetroDataGrid.HighlightBrush", theme.PrimaryMid.Color);
            resourceDictionary.SetBrush("MetroDataGrid.HighlightTextBrush", theme.PrimaryMid.GetForegroundColor());
            resourceDictionary.SetBrush("MetroDataGrid.MouseOverHighlightBrush", theme.PrimaryLight.Color);
            resourceDictionary.SetBrush("MetroDataGrid.FocusBorderBrush", theme.PrimaryMid.Color);
            resourceDictionary.SetBrush("MetroDataGrid.InactiveSelectionHighlightBrush", theme.PrimaryMid.Color);
            resourceDictionary.SetBrush("MetroDataGrid.InactiveSelectionHighlightTextBrush", theme.PrimaryMid.GetForegroundColor());

            resourceDictionary.SetBrush("MahApps.Metro.Brushes.ToggleSwitchButton.OnSwitchBrush.Win10", theme.PrimaryMid.Color);
            resourceDictionary.SetBrush("MahApps.Metro.Brushes.ToggleSwitchButton.OnSwitchMouseOverBrush.Win10", theme.PrimaryMid.Color, 0.8);
            resourceDictionary.SetBrush("MahApps.Metro.Brushes.ToggleSwitchButton.ThumbIndicatorCheckedBrush.Win10", theme.PrimaryMid.GetForegroundColor(), 0.8);
        }