-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathControlStyle.xaml
128 lines (128 loc) · 6.41 KB
/
ControlStyle.xaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:ESLTracker">
<Style x:Key="ToggleButtonStyle" TargetType="{x:Type ToggleButton}">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="ToggleButton">
<Border BorderBrush="{TemplateBinding BorderBrush}"
Background="{TemplateBinding Background}">
<ContentPresenter HorizontalAlignment="Center"
VerticalAlignment="Center"/>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
<Setter Property="Background" Value="{x:Null}"></Setter>
<Setter Property="Margin" Value="1,0,1,0"/>
<Style.Triggers>
<Trigger Property="IsChecked" Value="True">
<Setter Property="Background" Value="{DynamicResource {x:Static SystemColors.MenuHighlightBrushKey}}" />
</Trigger>
</Style.Triggers>
</Style>
<Style x:Key="ImageFilterClassButtonStyle" TargetType="{x:Type Image}">
<Setter Property="Height" Value="23"></Setter>
<Setter Property="Width" Value="23"/>
<Setter Property="Margin" Value="2,3,2,3"/>
</Style>
<Style x:Key="ModalControlInWindow" TargetType="{x:Type UserControl}">
<Setter Property="Background" Value="{DynamicResource {x:Static SystemColors.GradientInactiveCaptionBrushKey}}"></Setter>
</Style>
<Style x:Key="SaveButton" TargetType="{x:Type Button}">
<Setter Property="FontWeight" Value="Medium"></Setter>
</Style>
<Style x:Key="HeaderText" TargetType="{x:Type TextBlock}">
<Setter Property="FontWeight" Value="Bold"></Setter>
<Setter Property="Background" Value="{DynamicResource {x:Static SystemColors.ActiveCaptionBrushKey}}"></Setter>
<Setter Property="Padding" Value="5,5,5,5"/>
<Setter Property="FontSize" Value="14"/>
</Style>
<Style x:Key="ExpanderHeaderText" TargetType="{x:Type Expander}">
<Setter Property="HeaderTemplate">
<Setter.Value>
<DataTemplate>
<TextBlock
Text="{Binding}"
Width="{Binding
RelativeSource={RelativeSource
Mode=FindAncestor,
AncestorType={x:Type Expander}},
Path=ActualWidth}"
FontSize="14"
FontWeight="Bold"
Padding="5,5,5,5"
/>
</DataTemplate>
</Setter.Value>
</Setter>
<Setter Property="Background" Value="{DynamicResource {x:Static SystemColors.GradientInactiveCaptionBrushKey}}"/>
</Style>
<Style x:Key="DeckName" TargetType="{x:Type TextBlock}">
<Setter Property="FontWeight" Value="SemiBold"/>
<Setter Property="FontSize" Value="16"/>
<Style.Triggers>
<DataTrigger Binding="{Binding Deck.IsHidden}" Value="True">
<Setter Property="FontStyle" Value="Italic"/>
<Setter Property="Foreground" Value="Gray"/>
</DataTrigger>
</Style.Triggers>
</Style>
<Style x:Key="DeckVersion" TargetType="{x:Type TextBlock}">
<Setter Property="FontWeight" Value="SemiBold"/>
<Setter Property="FontSize" Value="16"/>
</Style>
<!--Virtualised ItemsControl-->
<Style x:Key="ItemsControlVirtualizedStyle" TargetType="ItemsControl">
<Setter Property="VirtualizingStackPanel.IsVirtualizing" Value="True"/>
<Setter Property="VirtualizingStackPanel.ScrollUnit" Value="Pixel" />
<Setter Property="ScrollViewer.CanContentScroll" Value="True"/>
<Setter Property="ItemsPanel">
<Setter.Value>
<ItemsPanelTemplate>
<VirtualizingStackPanel />
</ItemsPanelTemplate>
</Setter.Value>
</Setter>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="ItemsControl">
<Border
BorderThickness="{TemplateBinding Border.BorderThickness}"
Padding="{TemplateBinding Control.Padding}"
BorderBrush="{TemplateBinding Border.BorderBrush}"
Background="{TemplateBinding Panel.Background}"
SnapsToDevicePixels="True"
>
<ScrollViewer
VerticalScrollBarVisibility="Auto"
Padding="{TemplateBinding Control.Padding}"
Focusable="False">
<ItemsPresenter SnapsToDevicePixels="{TemplateBinding UIElement.SnapsToDevicePixels}" />
</ScrollViewer>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style x:Key="EditDeck_SectionHeader" TargetType="{x:Type TextBlock}">
<Setter Property="FontWeight" Value="Medium" />
<Setter Property="FontSize" Value="14" />
<Setter Property="Padding" Value="5,2,5,2" />
<Setter Property="Margin" Value="-5, -5, 0, 0" />
<Setter Property="Background" Value="{DynamicResource {x:Static SystemColors.GradientInactiveCaptionBrushKey}}" />
</Style>
<Style x:Key="EditDeck_FormSection" TargetType="{x:Type Border}">
<Setter Property="Margin" Value="5"/>
<Setter Property="Padding" Value="5, 5, 0, 5"/>
<Setter Property="BorderThickness" Value="2" />
<Setter Property="BorderBrush" Value="{DynamicResource {x:Static SystemColors.GradientInactiveCaptionBrushKey}}" />
</Style>
<Style x:Key="EditDeck_FormSectionEx" TargetType="{x:Type Expander}">
<Setter Property="Margin" Value="5"/>
<Setter Property="Padding" Value="0" />
<Setter Property="BorderThickness" Value="2" />
<Setter Property="Background" Value="{DynamicResource {x:Static SystemColors.GradientInactiveCaptionBrushKey}}" />
<Setter Property="BorderBrush" Value="{DynamicResource {x:Static SystemColors.GradientInactiveCaptionBrushKey}}" />
</Style>
</ResourceDictionary>