math-suite/Source/GraphingCalculator/Styles/GroupBoxStyle.xaml

40 lines
1.8 KiB
XML

<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<Style TargetType="GroupBox">
<Setter Property="SnapsToDevicePixels" Value="True" />
<Setter Property="OverridesDefaultStyle" Value="True" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="GroupBox">
<Border Background="#FAF8F8"
BorderBrush="White"
BorderThickness="1"
CornerRadius="5"
Margin="4">
<Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch" >
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition />
</Grid.RowDefinitions>
<ContentPresenter Margin="3,0,0,0" ContentSource="Header" >
<ContentPresenter.Resources>
<Style TargetType="TextBlock">
<Setter Property="Foreground" Value="Gray" />
</Style>
</ContentPresenter.Resources>
</ContentPresenter>
<ContentPresenter HorizontalAlignment="Stretch"
VerticalAlignment="Stretch"
Margin="4" Grid.Row="1" />
</Grid>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</ResourceDictionary>