You are creating a Windows Presentation Foundation application by using Microsoft .NET Framework 3.5.
The application-definition file contains the following XAML code fragment.
<Application.Resources>
<Style TargetType="Button" x:Key="buttons">
<Setter Property="Margin" Value="5" />
<Setter Property="Background" Value="Olive" />
</Style>
</Application.Resources>
You add a window to the application. The window includes the following XAML code fragment.
(Line numbers are included for reference only.)
01 <StackPanel>
02 <StackPanel.Resources>
03
04 <Setter Property="Button.Background" Value="Blue" />
05 </Style>
06 </StackPanel.Resources>
07 <Button Content="Open" />
08 </StackPanel>
You need to ensure that the Button control of the window meets the following requirements:
* The Margin property is set to 5.
* The Background property is set to Blue.
Which XAML code fragment should you insert at line 03?
A.
<Style TargetType="Button">
B.
<Style TargetType="Button" BasedOn= "{StaticResource {x:Type Button}}">
C.
<Style TargetType="Button" BasedOn= "{StaticResource buttons}">
D.
<Style TargetType="{x:Type Button}" BasedOn= "{StaticResource {x:Type Button}}">