Files
SewerGenerator/StammGenerator/Views/styles/my_controls.xaml

65 lines
3.8 KiB
XML

<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<Style x:Key="ToggleButtonList" TargetType="{x:Type ToggleButton}">
<Setter Property="FrameworkElement.OverridesDefaultStyle" Value="True"/>
<Setter Property="FrameworkElement.FocusVisualStyle" Value="{x:Null}"/>
<Setter Property="Width" Value="170" />
<Setter Property="Height" Value="70" />
<Setter Property="Margin" Value="2" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type ToggleButton}">
<Grid>
<Rectangle Name="rect" Fill="#FF808080" Stretch="Fill"/>
<ContentPresenter VerticalAlignment="Top" HorizontalAlignment="Left" Margin="5"
RecognizesAccessKey="True" TextBlock.FontFamily="Seggeo" TextBlock.FontSize="16"
TextBlock.Foreground="#FFFFFFFF" TextBlock.FontWeight="Light" />
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="UIElement.IsMouseOver" Value="True">
<Setter TargetName="rect" Property="Shape.Fill" Value="BlueViolet"/>
<Setter Property="Foreground" Value="#FFFFFFFF"/>
</Trigger>
<Trigger Property="ToggleButton.IsChecked" Value="True">
<Setter TargetName="rect" Property="Shape.Fill" Value="BlueViolet" />
<Setter Property="Foreground" Value="#FFFFFFFF" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style x:Key="SmallToggleButtonList" TargetType="{x:Type RadioButton}">
<Setter Property="FrameworkElement.OverridesDefaultStyle" Value="True"/>
<Setter Property="FrameworkElement.FocusVisualStyle" Value="{x:Null}"/>
<Setter Property="Height" Value="40" />
<Setter Property="Width" Value="auto" />
<Setter Property="Margin" Value="2" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type RadioButton}">
<Grid>
<Rectangle x:Name="rect" Fill="#FF808080" Stretch="Fill" />
<ContentPresenter VerticalAlignment="Top" HorizontalAlignment="Left" Margin="5" RecognizesAccessKey="True"
TextBlock.FontFamily="Seggeo" TextBlock.FontSize="12"
TextBlock.Foreground="#FFFFFFFF" TextBlock.FontWeight="Light" />
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="UIElement.IsMouseOver" Value="True">
<Setter TargetName="rect" Property="Shape.Fill" Value="BlueViolet"/>
<Setter Property="Foreground" Value="#FFFFFFFF" />
</Trigger>
<Trigger Property="RadioButton.IsChecked" Value="True">
<Setter TargetName="rect" Property="Shape.Fill" Value="BlueViolet" />
<Setter Property="Foreground" Value="#FFFFFFFF" />
</Trigger>
<Trigger Property="RadioButton.IsEnabled" Value="False">
<Setter TargetName="rect" Property="Shape.Fill" Value="DarkGray" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</ResourceDictionary>