可能重复:
如何在 WPF 中应用多种样式
<Window.Resources>
<Style TargetType="Button" x:Key="style_1">
<Setter Property="Foreground" Value="Green" />
</Style>
<Style TargetType="Button" x:Key="style_2">
<Setter Property="Background" Value="Blue" />
</Style>
</Window.Resources>
<Button x:Name="btn_1" Content="Button" HorizontalAlignment="Left" Height="40" Margin="153,95,0,0" VerticalAlignment="Top" Width="89" Style="{StaticResource style_1}" Click="Button_Click" />
<Button x:Name="btn_2" Content="Button" Height="40" Margin="281,95,262,0" VerticalAlignment="Top" Style="{StaticResource style_2}"/>
现在我想将 style_1 和 style_2 应用到btn_1我应该怎么做。