I find the property named "windowclosebuttonstyle" , but i don't know how to change it , i just want to change the close button's color to red . I need the help .
@trlanfeng
<Style x:Key="CleanCloseWindowButtonStyle" TargetType="{x:Type Button}" BasedOn="{StaticResource MetroWindowButtonStyle}">
<Style.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter Property="Background" Value="#EB2F2F" />
<Setter Property="Foreground" Value="{DynamicResource WhiteBrush}" />
</Trigger>
<Trigger Property="IsPressed" Value="True">
<Setter Property="Background" Value="#7C0000" />
</Trigger>
</Style.Triggers>
</Style>
usage
<Controls:MetroWindow x:Class="MetroDemo.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:Controls="clr-namespace:MahApps.Metro.Controls;assembly=MahApps.Metro"
Title="MahApps.Metro - Demo Application"
WindowCloseButtonStyle="{DynamicResource CleanCloseWindowButtonStyle}"
>
</Controls:MetroWindow>
Most helpful comment
@trlanfeng
usage