View difference between Paste ID: mM1cEimQ and FQC1TtSd
SHOW: | | - or go back to the newest paste.
1
<ResourceDictionary
2
	xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
3
	xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
4-
    xmlns:converters="clr-namespace:CDP.MAR.ClientBase.Converters;assembly=CDP.MAR.ClientBase">
4+
    xmlns:converters="clr-namespace:aaa.bbb.Converters;assembly=aaa.bbb">
5
    <SolidColorBrush x:Key="TabItemDisabledBackground" Color="#F4F4F4"/>
6
    <SolidColorBrush x:Key="TabItemDisabledBorderBrush" Color="#FFC9C7BA"/>
7
    <Style x:Key="ShellTabItemStyle" TargetType="{x:Type TabItem}">
8
        <Setter Property="FontFamily" Value="Trebuchet MS"/>
9
        <Setter Property="FontSize" Value="14"/>
10
        <Setter Property="Foreground" Value="#FFFFFFFF"/>
11
        <Setter Property="Background" Value="#AAAAAAAA"/>
12
        <Setter Property="Header" Value="{Binding Content.DataContext.Nom, RelativeSource={RelativeSource Self}}" />
13
        <Setter Property="Template">
14
            <Setter.Value>
15
                <ControlTemplate TargetType="{x:Type TabItem}">
16
                    <ControlTemplate.Resources>
17
                        <converters:VisibilityToCadenasConverter x:Key="visibilityToCadenasConverter"/>
18
                    </ControlTemplate.Resources>
19
                    <Grid Width="Auto" Height="Auto" x:Name="TabItemRoot" Margin="10,0,10,0">
20
                        <DockPanel>
21
                            <Image x:Name="cadenas" Source="../Resources/lock_16_dis.png" Width="16" DockPanel.Dock="Left" 
22
                                   Visibility="{Binding Converter={StaticResource visibilityToCadenasConverter}}" 
23
                                   ToolTip="Nécessite une connection avec PRF ou DCM"/>
24
                            <ContentPresenter Margin="13,5,13,5" x:Name="Content" ContentSource="Header" RecognizesAccessKey="True"/>
25
                        </DockPanel>
26
                        <Border x:Name="border" Height="Auto" Margin="-5,0,-5,0" Padding="0,0,0,0" Opacity="0">
27
                            <Border.Background>
28
                                <SolidColorBrush Color="#55FFFFFF" />
29
                                <!--RadialGradientBrush>
30
                                    <GradientStop Color="#A3FFFFFF" Offset="0"/>
31
                                    <GradientStop Color="#00FFFFFF" Offset="1"/>
32
                                </RadialGradientBrush-->                                
33
                            </Border.Background>
34
                        </Border>
35
                    </Grid>
36
                    <ControlTemplate.Triggers>
37
                        <Trigger Property="IsSelected" Value="true">
38
                            <Setter TargetName="border" Property="Opacity" Value="1"/>
39
                            <Setter TargetName="Content" Property="Opacity" Value="1"/>                            
40
                        </Trigger>
41
                        <Trigger Property="IsSelected" Value="false">
42
                            <Setter TargetName="Content" Property="Opacity" Value="0.7"/>
43
                        </Trigger>
44
                    </ControlTemplate.Triggers>
45
                </ControlTemplate>
46
            </Setter.Value>
47
        </Setter>
48
    </Style>
49
50
    <Style x:Key="WindowRegionStyle" TargetType="Window">
51
        <Setter Property="Background" Value="Transparent" />
52
        <Setter Property="Margin" Value="0" />
53
        <Setter Property="Padding" Value="0" />
54
        <Setter Property="Width" Value="400" />
55
        <Setter Property="Height" Value="400" />
56
        <Setter Property="Title" Value="{Binding Path=Content.Title, RelativeSource={RelativeSource Self}}" />
57
    </Style>
58
    
59
    <!-- Focus Visual -->
60
61
        <Style x:Key="ButtonFocusVisual">
62
            <Setter Property="Control.Template">
63
                <Setter.Value>
64
                    <ControlTemplate>
65
                        <Border>
66
                            <Rectangle Margin="2" StrokeThickness="1" Stroke="#60000000" StrokeDashArray="1 2"/>
67
                        </Border>
68
                    </ControlTemplate>
69
                </Setter.Value>
70
            </Setter>
71
        </Style>
72
73
        <!-- Fill Brushes -->
74
75
        <LinearGradientBrush x:Key="NormalBrush" StartPoint="0,0" EndPoint="0,1">
76
            <GradientBrush.GradientStops>
77
                <GradientStopCollection>
78
                    <GradientStop Color="#FFF" Offset="0.0"/>
79
                    <GradientStop Color="#CCC" Offset="1.0"/>
80
                </GradientStopCollection>
81
            </GradientBrush.GradientStops>
82
        </LinearGradientBrush>
83
84
        <LinearGradientBrush x:Key="headerBarBG" EndPoint="0.5,1" StartPoint="0.5,0">
85
            <GradientStop Color="#FF284292"/>
86
            <GradientStop Color="#FF2175B8" Offset="0.26499998569488525"/>
87
        </LinearGradientBrush>
88
89
        <LinearGradientBrush x:Key="HorizontalNormalBrush" StartPoint="0,0" EndPoint="1,0">
90
            <GradientBrush.GradientStops>
91
                <GradientStopCollection>
92
                    <GradientStop Color="#FFF" Offset="0.0"/>
93
                    <GradientStop Color="#CCC" Offset="1.0"/>
94
                </GradientStopCollection>
95
            </GradientBrush.GradientStops>
96
        </LinearGradientBrush>
97
98
        <LinearGradientBrush x:Key="LightBrush" StartPoint="0,0" EndPoint="0,1">
99
            <GradientBrush.GradientStops>
100
                <GradientStopCollection>
101
                    <GradientStop Color="#FFF" Offset="0.0"/>
102
                    <GradientStop Color="#444" Offset="1.0"/>
103
                </GradientStopCollection>
104
            </GradientBrush.GradientStops>
105
        </LinearGradientBrush>
106
107
        <LinearGradientBrush x:Key="HorizontalLightBrush" StartPoint="0,0" EndPoint="1,0">
108
            <GradientBrush.GradientStops>
109
                <GradientStopCollection>
110
                    <GradientStop Color="#FFF" Offset="0.0"/>
111
                    <GradientStop Color="#EEE" Offset="1.0"/>
112
                </GradientStopCollection>
113
            </GradientBrush.GradientStops>
114
        </LinearGradientBrush>
115
116
        <LinearGradientBrush x:Key="DarkBrush" StartPoint="0,0" EndPoint="0,1">
117
            <GradientBrush.GradientStops>
118
                <GradientStopCollection>
119
                    <GradientStop Color="#FFF" Offset="0.0"/>
120
                    <GradientStop Color="#AAA" Offset="1.0"/>
121
                </GradientStopCollection>
122
            </GradientBrush.GradientStops>
123
        </LinearGradientBrush>
124
125
        <LinearGradientBrush x:Key="PressedBrush" StartPoint="0,0" EndPoint="0,1">
126
            <GradientBrush.GradientStops>
127
                <GradientStopCollection>
128
                    <GradientStop Color="#BBB" Offset="0.0"/>
129
                    <GradientStop Color="#EEE" Offset="0.1"/>
130
                    <GradientStop Color="#EEE" Offset="0.9"/>
131
                    <GradientStop Color="#FFF" Offset="1.0"/>
132
                </GradientStopCollection>
133
            </GradientBrush.GradientStops>
134
        </LinearGradientBrush>
135
136
        <LinearGradientBrush x:Key="ToggledBrush" StartPoint="0,0" EndPoint="0,1">
137
            <GradientBrush.GradientStops>
138
                <GradientStopCollection>
139
                    <GradientStop Color="#058cf5" Offset="0.0"/>
140
                    <!--GradientStop Color="#336699" Offset="0.1"/>
141
                    <GradientStop Color="#336699" Offset="0.9"/-->
142
                    <GradientStop Color="#015fe7" Offset="1.0"/>
143
                </GradientStopCollection>
144
            </GradientBrush.GradientStops>
145
        </LinearGradientBrush>
146
147
    <SolidColorBrush x:Key="DisabledForegroundBrush" Color="#888" />
148
        <SolidColorBrush x:Key="DisabledBackgroundBrush" Color="#EEE" />
149
        <SolidColorBrush x:Key="WindowBackgroundBrush" Color="#FFF" />
150
        <SolidColorBrush x:Key="SelectedBackgroundBrush" Color="#CCC" />
151
152
        <!-- Border Brushes -->
153
154
        <LinearGradientBrush x:Key="NormalBorderBrush" StartPoint="0,0" EndPoint="0,1">
155
            <GradientBrush.GradientStops>
156
                <GradientStopCollection>
157
                    <GradientStop Color="#999" Offset="0.0"/>
158
                    <GradientStop Color="#444" Offset="1.0"/>
159
                </GradientStopCollection>
160
            </GradientBrush.GradientStops>
161
        </LinearGradientBrush>
162
163
        <LinearGradientBrush x:Key="HorizontalNormalBorderBrush" StartPoint="0,0" EndPoint="1,0">
164
            <GradientBrush.GradientStops>
165
                <GradientStopCollection>
166
                    <GradientStop Color="#CCC" Offset="0.0"/>
167
                    <GradientStop Color="#444" Offset="1.0"/>
168
                </GradientStopCollection>
169
            </GradientBrush.GradientStops>
170
        </LinearGradientBrush>
171
172
        <LinearGradientBrush x:Key="DefaultedBorderBrush" StartPoint="0,0" EndPoint="0,1">
173
            <GradientBrush.GradientStops>
174
                <GradientStopCollection>
175
                    <GradientStop Color="#777" Offset="0.0"/>
176
                    <GradientStop Color="#000" Offset="1.0"/>
177
                </GradientStopCollection>
178
            </GradientBrush.GradientStops>
179
        </LinearGradientBrush>
180
181
        <LinearGradientBrush x:Key="PressedBorderBrush" StartPoint="0,0" EndPoint="0,1">
182
            <GradientBrush.GradientStops>
183
                <GradientStopCollection>
184
                    <GradientStop Color="#444" Offset="0.0"/>
185
                    <GradientStop Color="#888" Offset="1.0"/>
186
                </GradientStopCollection>
187
            </GradientBrush.GradientStops>
188
        </LinearGradientBrush>
189
190
        <SolidColorBrush x:Key="DisabledBorderBrush" Color="#AAA" />
191
        <SolidColorBrush x:Key="SolidBorderBrush" Color="#888" />
192
        <SolidColorBrush x:Key="LightBorderBrush" Color="#AAA" />
193
194
        <!-- Miscellaneous Brushes -->
195
196
        <SolidColorBrush x:Key="GlyphBrush" Color="#444" />
197
        <SolidColorBrush x:Key="LightColorBrush" Color="#DDD" />
198
199
200
        <!-- Button -->
201
202
        <Style TargetType="{x:Type Button}">
203
            <Setter Property="SnapsToDevicePixels" Value="true"/>
204
            <Setter Property="OverridesDefaultStyle" Value="true"/>
205
            <Setter Property="FocusVisualStyle" Value="{StaticResource ButtonFocusVisual}"/>
206
            <Setter Property="MinHeight" Value="22"/>
207
            <Setter Property="MinWidth" Value="60"/>
208
            <Setter Property="Template">
209
                <Setter.Value>
210
                    <ControlTemplate TargetType="{x:Type Button}">
211
                        <Border x:Name="Border" 
212
                                CornerRadius="4" 
213
                                BorderThickness="1" 
214
                                Background="{StaticResource NormalBrush}" 
215
                                BorderBrush="{StaticResource NormalBorderBrush}">
216
                            <ContentPresenter Margin="2" 
217
                                              HorizontalAlignment="Center" 
218
                                              VerticalAlignment="Center" 
219
                                              RecognizesAccessKey="True"/>
220
                        </Border>
221
                        <ControlTemplate.Triggers>
222
                            <Trigger Property="IsKeyboardFocused" Value="true">
223
                                <Setter TargetName="Border" Property="BorderBrush" Value="{StaticResource DefaultedBorderBrush}" />
224
                            </Trigger>
225
                            <Trigger Property="IsDefaulted" Value="true">
226
                                <Setter TargetName="Border" Property="BorderBrush" Value="{StaticResource DefaultedBorderBrush}" />
227
                            </Trigger>
228
                            <Trigger Property="IsMouseOver" Value="true">
229
                                <Setter TargetName="Border" Property="Background" Value="{StaticResource DarkBrush}" />
230
                            </Trigger>
231
                            <Trigger Property="IsPressed" Value="true">
232
                                <Setter TargetName="Border" Property="Background" Value="{StaticResource PressedBrush}" />
233
                                <Setter TargetName="Border" Property="BorderBrush" Value="{StaticResource PressedBorderBrush}" />
234
                            </Trigger>
235
                            <Trigger Property="IsEnabled" Value="false">
236
                                <Setter TargetName="Border" Property="Background" Value="{StaticResource DisabledBackgroundBrush}" />
237
                                <Setter TargetName="Border" Property="BorderBrush" Value="{StaticResource DisabledBorderBrush}" />
238
                                <Setter Property="Foreground" Value="{StaticResource DisabledForegroundBrush}"/>
239
                            </Trigger>
240
                        </ControlTemplate.Triggers>
241
                    </ControlTemplate>
242
                </Setter.Value>
243
            </Setter>
244
        </Style>
245
246
247
        <!-- TextBox -->
248
249
        <Style x:Key="{x:Type TextBox}" TargetType="{x:Type TextBoxBase}">
250
            <Setter Property="SnapsToDevicePixels" Value="True"/>
251
            <Setter Property="OverridesDefaultStyle" Value="True"/>
252
            <Setter Property="KeyboardNavigation.TabNavigation" Value="None"/>
253
            <Setter Property="FocusVisualStyle" Value="{x:Null}"/>
254
            <Setter Property="MinWidth" Value="30"/>
255
            <!--Setter Property="MinHeight" Value="20"/-->
256
            <Setter Property="AllowDrop" Value="true"/>
257
            <Setter Property="Template">
258
                <Setter.Value>
259
                    <ControlTemplate TargetType="{x:Type TextBoxBase}">
260
                        <Border 
261
            Name="Border"
262
            CornerRadius="0" 
263
            Padding="2"
264
            Background="White"
265
            BorderBrush="{StaticResource SolidBorderBrush}"
266
            BorderThickness="1" >
267
                            <ScrollViewer Margin="0" x:Name="PART_ContentHost"/>
268
                        </Border>
269
                        <ControlTemplate.Triggers>
270
                            <Trigger Property="IsEnabled" Value="False">
271
                                <Setter TargetName="Border" Property="Background" Value="{StaticResource DisabledBackgroundBrush}"/>
272
                                <Setter TargetName="Border" Property="BorderBrush" Value="{StaticResource DisabledBackgroundBrush}"/>
273
                                <Setter Property="Foreground" Value="{StaticResource DisabledForegroundBrush}"/>
274
                            </Trigger>
275
                        </ControlTemplate.Triggers>
276
                    </ControlTemplate>
277
                </Setter.Value>
278
            </Setter>
279
        </Style>
280
281
        <!-- RichTextBox -->
282
283
        <Style x:Key="{x:Type RichTextBox}"
284
       BasedOn="{StaticResource {x:Type TextBox}}"
285
       TargetType="{x:Type RichTextBox}">
286
            <Style.Resources>
287
                <Style x:Key="{x:Type FlowDocument}"
288
           TargetType="{x:Type FlowDocument}">
289
                    <Setter Property="OverridesDefaultStyle"
290
            Value="true"/>
291
                </Style>
292
            </Style.Resources>
293
        </Style>
294
295
        <!-- PasswordBox -->
296
297
        <Style x:Key="{x:Type PasswordBox}" TargetType="{x:Type PasswordBox}">
298
            <Setter Property="SnapsToDevicePixels" Value="true"/>
299
            <Setter Property="OverridesDefaultStyle" Value="true"/>
300
            <Setter Property="KeyboardNavigation.TabNavigation" Value="None"/>
301
            <Setter Property="FocusVisualStyle" Value="{x:Null}"/>
302
            <Setter Property="FontFamily" Value="Verdana"/>
303
            <Setter Property="PasswordChar" Value="●"/>
304
            <Setter Property="MinWidth" Value="30"/>
305
            <Setter Property="MinHeight" Value="20"/>
306
            <Setter Property="AllowDrop" Value="true"/>
307
            <Setter Property="Template">
308
                <Setter.Value>
309
                    <ControlTemplate TargetType="{x:Type PasswordBox}">
310
                        <Border 
311
            Name="Border"
312
            CornerRadius="0" 
313
            Padding="2" 
314
            Background="{StaticResource DisabledBackgroundBrush}"
315
            BorderBrush="{StaticResource SolidBorderBrush}"
316
            BorderThickness="1" >
317
                            <ScrollViewer x:Name="PART_ContentHost" />
318
                        </Border>
319
                        <ControlTemplate.Triggers>
320
                            <Trigger Property="IsEnabled" Value="False">
321
                                <Setter TargetName="Border" Property="Background" Value="{StaticResource DisabledBackgroundBrush}"/>
322
                                <Setter TargetName="Border" Property="BorderBrush" Value="{StaticResource DisabledBackgroundBrush}"/>
323
                                <Setter Property="Foreground" Value="{StaticResource DisabledForegroundBrush}"/>
324
                            </Trigger>
325
                        </ControlTemplate.Triggers>
326
                    </ControlTemplate>
327
                </Setter.Value>
328
            </Setter>
329
        </Style>
330
331
        <!-- TabControl -->
332
333
        <Style  TargetType="{x:Type TabControl}">
334
            <Setter Property="OverridesDefaultStyle" Value="True" />
335
            <Setter Property="SnapsToDevicePixels" Value="True" />
336
            <Setter Property="Template">
337
                <Setter.Value>
338
                    <ControlTemplate TargetType="{x:Type TabControl}">
339
                        <Grid KeyboardNavigation.TabNavigation="Local">
340
                            <Grid.RowDefinitions>
341
                                <RowDefinition Height="Auto"/>
342
                                <RowDefinition Height="*"/>
343
                            </Grid.RowDefinitions>
344
                            <Border 
345
              Name="Border" 
346
              Grid.Row="1" 
347
              Background="{StaticResource WindowBackgroundBrush}" 
348
              BorderBrush="{StaticResource SolidBorderBrush}" 
349
              BorderThickness="1" 
350
              CornerRadius="2" 
351
              KeyboardNavigation.TabNavigation="Local"
352
              KeyboardNavigation.DirectionalNavigation="Contained"
353
              KeyboardNavigation.TabIndex="2" >
354
                                <ContentPresenter 
355
                Name="PART_SelectedContentHost"
356
                Margin="4"
357
                ContentSource="SelectedContent" />
358
                            </Border>
359
                            <TabPanel 
360
              Name="HeaderPanel"
361
              Grid.Row="0"
362
              Margin="1,0,0,-1" 
363
              IsItemsHost="True"
364
              KeyboardNavigation.TabIndex="1"
365
              Background="Transparent" />
366
                        </Grid>
367
                        <ControlTemplate.Triggers>
368
                            <Trigger Property="IsEnabled" Value="False">
369
                                <Setter Property="Foreground" Value="{StaticResource DisabledForegroundBrush}" />
370
                                <Setter TargetName="Border" Property="BorderBrush" Value="{StaticResource DisabledBorderBrush}" />
371
                            </Trigger>
372
                        </ControlTemplate.Triggers>
373
                    </ControlTemplate>
374
                </Setter.Value>
375
            </Setter>
376
        </Style>
377
378
        <!-- TabItem -->
379
380
        <Style TargetType="{x:Type TabItem}">
381
            <Setter Property="Template">
382
                <Setter.Value>
383
                    <ControlTemplate TargetType="{x:Type TabItem}">
384
                        <Grid>
385
                            <Border 
386
            Name="Border"
387
            Margin="-1,0,0,0" 
388
            Background="{StaticResource LightBrush}"
389
            BorderBrush="{StaticResource SolidBorderBrush}" 
390
            BorderThickness="1,1,1,1" 
391
            CornerRadius="2,12,0,0" >
392
                                <ContentPresenter x:Name="ContentSite"
393
              VerticalAlignment="Center"
394
              HorizontalAlignment="Center"
395
              ContentSource="Header"
396
              Margin="12,2,12,2"
397
              RecognizesAccessKey="True"/>
398
                            </Border>
399
                        </Grid>
400
                        <ControlTemplate.Triggers>
401
                            <Trigger Property="IsSelected" Value="True">
402
                                <Setter TargetName="Border" Property="Background" Value="{StaticResource WindowBackgroundBrush}" />
403
                                <Setter TargetName="Border" Property="BorderThickness" Value="1,1,1,0" />
404
                            </Trigger>
405
                            <Trigger Property="IsEnabled" Value="False">
406
                                <Setter TargetName="Border" Property="Background" Value="{StaticResource DisabledBackgroundBrush}" />
407
                                <Setter TargetName="Border" Property="BorderBrush" Value="{StaticResource DisabledBorderBrush}" />
408
                                <Setter Property="Foreground" Value="{StaticResource DisabledForegroundBrush}" />
409
                            </Trigger>
410
                        </ControlTemplate.Triggers>
411
                    </ControlTemplate>
412
                </Setter.Value>
413
            </Setter>
414
        </Style>
415
416
        <!-- SideBar Styles -->
417
418
        <Style x:Key="TextBlockSectionTitle" TargetType="TextBlock">
419
            <Setter Property="FontFamily" Value="Trebuchet MS"/>
420
            <Setter Property="FontSize" Value="11" />
421
            <Setter Property="FontWeight" Value="Normal" />
422
            <Setter Property="Foreground" Value="#FF1B75BB" />
423
            <Setter Property="HorizontalAlignment" Value="Stretch" />
424
            <Setter Property="TextWrapping" Value="Wrap" />
425
            <Setter Property="TextAlignment" Value="Left" />
426
            <Setter Property="Margin" Value="0,0,0,12" />
427
        </Style>
428
429
        <!-- Shell Boxes -->
430
        <Style x:Key="ShelBoxStyle" TargetType="Border">
431
            <Setter Property="Background" Value="#AAFFFFFF" />
432
            <Setter Property="Opacity" Value="0.8" />
433
            <Setter Property="CornerRadius" Value="12,12,12,12" />
434
            <Setter Property="VerticalAlignment" Value="Stretch" />
435
        </Style>
436
437
        <!-- ListView -->
438
439
        <Style x:Key="{x:Static GridView.GridViewScrollViewerStyleKey}" TargetType="{x:Type ScrollViewer}">
440
            <Setter Property="Template">
441
                <Setter.Value>
442
                    <ControlTemplate TargetType="{x:Type ScrollViewer}">
443
                        <Grid Background="{TemplateBinding Background}">
444
                            <Grid.ColumnDefinitions>
445
                                <ColumnDefinition Width="*"/>
446
                                <ColumnDefinition Width="Auto"/>
447
                            </Grid.ColumnDefinitions>
448
                            <Grid.RowDefinitions>
449
                                <RowDefinition Height="*"/>
450
                                <RowDefinition Height="Auto"/>
451
                            </Grid.RowDefinitions>
452
453
                            <DockPanel Margin="{TemplateBinding Padding}">
454
                                <ScrollViewer DockPanel.Dock="Top"
455
              HorizontalScrollBarVisibility="Hidden"
456
              VerticalScrollBarVisibility="Hidden"
457
              Focusable="false">
458
                                    <Border CornerRadius="4" Background="{StaticResource DefaultedBorderBrush}" Padding="4" Margin="0,4,0,4">
459
                                        <GridViewHeaderRowPresenter Margin="2,0,2,0"
460
                Columns="{Binding Path=TemplatedParent.View.Columns,RelativeSource={RelativeSource TemplatedParent}}"
461
                ColumnHeaderContainerStyle="{Binding Path=TemplatedParent.View.ColumnHeaderContainerStyle,RelativeSource={RelativeSource TemplatedParent}}"
462
                ColumnHeaderTemplate="{Binding Path=TemplatedParent.View.ColumnHeaderTemplate,RelativeSource={RelativeSource TemplatedParent}}"
463
                ColumnHeaderTemplateSelector="{Binding Path=TemplatedParent.View.ColumnHeaderTemplateSelector,RelativeSource={RelativeSource TemplatedParent}}"
464
                AllowsColumnReorder="{Binding Path=TemplatedParent.View.AllowsColumnReorder,RelativeSource={RelativeSource TemplatedParent}}"
465
                ColumnHeaderContextMenu="{Binding Path=TemplatedParent.View.ColumnHeaderContextMenu,RelativeSource={RelativeSource TemplatedParent}}"
466
                ColumnHeaderToolTip="{Binding Path=TemplatedParent.View.ColumnHeaderToolTip,RelativeSource={RelativeSource TemplatedParent}}"
467
                SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
468
                                    </Border>
469
470
                                </ScrollViewer>
471
472
                                <ScrollContentPresenter Name="PART_ScrollContentPresenter"
473
              KeyboardNavigation.DirectionalNavigation="Local"/>
474
                            </DockPanel>
475
476
                            <ScrollBar Name="PART_HorizontalScrollBar"
477
            Orientation="Horizontal"
478
            Grid.Row="1"
479
            Maximum="{TemplateBinding ScrollableWidth}"
480
            ViewportSize="{TemplateBinding ViewportWidth}"
481
            Value="{TemplateBinding HorizontalOffset}"
482
            Visibility="{TemplateBinding ComputedHorizontalScrollBarVisibility}"/>
483
484
                            <ScrollBar Name="PART_VerticalScrollBar"
485
            Grid.Column="1"
486
            Maximum="{TemplateBinding ScrollableHeight}"
487
            ViewportSize="{TemplateBinding ViewportHeight}"
488
            Value="{TemplateBinding VerticalOffset}"
489
            Visibility="{TemplateBinding ComputedVerticalScrollBarVisibility}"/>
490
491
                        </Grid>
492
                    </ControlTemplate>
493
                </Setter.Value>
494
            </Setter>
495
        </Style>
496
497
        <Style x:Key="GridViewColumnHeaderGripper" TargetType="{x:Type Thumb}">
498
            <Setter Property="Width" Value="18"/>
499
            <Setter Property="Background" Value="#404040"/>
500
            <Setter Property="Template">
501
                <Setter.Value>
502
                    <ControlTemplate TargetType="{x:Type Thumb}">
503
                        <Border Padding="{TemplateBinding Padding}" Background="Transparent">
504
                            <Rectangle HorizontalAlignment="Center" Width="1" Fill="{TemplateBinding Background}"/>
505
                        </Border>
506
                    </ControlTemplate>
507
                </Setter.Value>
508
            </Setter>
509
        </Style>
510
511
        <Style x:Key="{x:Type GridViewColumnHeader}" TargetType="{x:Type GridViewColumnHeader}">
512
            <Setter Property="HorizontalContentAlignment" Value="Left"/>
513
            <Setter Property="VerticalContentAlignment" Value="Center"/>
514
            <Setter Property="Foreground" Value="#ffffff"/>
515
            <Setter Property="Template">
516
                <Setter.Value>
517
                    <ControlTemplate TargetType="{x:Type GridViewColumnHeader}">
518
                        <Grid>
519
                            <Border Name="HeaderBorder" BorderThickness="0,1,0,1" BorderBrush="{x:Null}" Background="{x:Null}" Padding="2,0,2,0">
520
                                <ContentPresenter Name="HeaderContent" Margin="0,0,0,1" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" RecognizesAccessKey="True" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
521
                            </Border>
522
                            <Thumb x:Name="PART_HeaderGripper" HorizontalAlignment="Right" Margin="0,0,-9,0" Style="{StaticResource GridViewColumnHeaderGripper}" Foreground="#FFFFFFFF" Background="{x:Null}"/>
523
                        </Grid>
524
                        <ControlTemplate.Triggers>
525
                            <Trigger Property="IsMouseOver" Value="true">
526
                                <Setter Property="Background" TargetName="PART_HeaderGripper" Value="{x:Null}"/>
527
                                <Setter Property="Foreground" TargetName="PART_HeaderGripper" Value="#FFFCFCFC"/>
528
                                <Setter Property="Background" TargetName="HeaderBorder" Value="{x:Null}"/>
529
                            </Trigger>
530
                            <Trigger Property="IsPressed" Value="true">
531
                                <Setter TargetName="HeaderContent" Property="Margin" Value="1,1,0,0"/>
532
                                <Setter Property="Foreground" TargetName="PART_HeaderGripper" Value="#FFE0E0E0"/>
533
                                <Setter Property="Background" TargetName="PART_HeaderGripper" Value="{x:Null}"/>
534
                                <Setter Property="Background" TargetName="HeaderBorder" Value="{x:Null}"/>
535
                            </Trigger>
536
                            <Trigger Property="IsEnabled" Value="false">
537
                                <Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.GrayTextBrushKey}}"/>
538
                                <Setter Property="Background" TargetName="PART_HeaderGripper" Value="{x:Null}"/>
539
                            </Trigger>
540
                        </ControlTemplate.Triggers>
541
                    </ControlTemplate>
542
                </Setter.Value>
543
            </Setter>
544
            <Style.Triggers>
545
                <Trigger Property="Role" Value="Floating">
546
                    <Setter Property="Opacity" Value="0.7"/>
547
                    <Setter Property="Template">
548
                        <Setter.Value>
549
                            <ControlTemplate TargetType="{x:Type GridViewColumnHeader}">
550
                                <Canvas Name="PART_FloatingHeaderCanvas">
551
                                    <Rectangle Fill="#60000000" Width="{TemplateBinding ActualWidth}" Height="{TemplateBinding ActualHeight}"/>
552
                                </Canvas>
553
                            </ControlTemplate>
554
                        </Setter.Value>
555
                    </Setter>
556
                    <Setter Property="Foreground" Value="#FFFFFFFF"/>
557
                    <Setter Property="Background" Value="{x:Null}"/>
558
                </Trigger>
559
                <Trigger Property="Role" Value="Padding">
560
                    <Setter Property="Template">
561
                        <Setter.Value>
562
                            <ControlTemplate TargetType="{x:Type GridViewColumnHeader}">
563
                                <Border Name="HeaderBorder" BorderThickness="0,1,0,1" BorderBrush="#404040" Background="{x:Null}"/>
564
                            </ControlTemplate>
565
                        </Setter.Value>
566
                    </Setter>
567
                    <Setter Property="Foreground" Value="#FFFFFFFF"/>
568
                    <Setter Property="Background" Value="{x:Null}"/>
569
                    <Setter Property="BorderBrush" Value="{x:Null}"/>
570
                </Trigger>
571
            </Style.Triggers>
572
        </Style>
573
574
        <Style x:Key="{x:Type ListView}" TargetType="{x:Type ListView}">
575
            <Setter Property="SnapsToDevicePixels" Value="true"/>
576
            <Setter Property="OverridesDefaultStyle" Value="true"/>
577
            <Setter Property="ScrollViewer.HorizontalScrollBarVisibility" Value="Auto"/>
578
            <Setter Property="ScrollViewer.VerticalScrollBarVisibility" Value="Auto"/>
579
            <Setter Property="ScrollViewer.CanContentScroll" Value="true"/>
580
            <Setter Property="VerticalContentAlignment" Value="Center"/>
581
            <Setter Property="Template">
582
                <Setter.Value>
583
                    <ControlTemplate TargetType="{x:Type ListView}">
584
                        <Border Name="Border"  BorderThickness="1" BorderBrush="{x:Null}" Background="{x:Null}">
585
                            <ScrollViewer Style="{DynamicResource {x:Static GridView.GridViewScrollViewerStyleKey}}" Foreground="#FFFFFFFF">
586
                                <ItemsPresenter />
587
                            </ScrollViewer>
588
                        </Border>
589
                        <ControlTemplate.Triggers>
590
                            <Trigger Property="IsGrouping" Value="true">
591
                                <Setter Property="ScrollViewer.CanContentScroll" Value="false"/>
592
                            </Trigger>
593
                            <Trigger Property="IsEnabled" Value="false">
594
                                <Setter TargetName="Border" Property="Background" Value="#AAAAAA"/>
595
                            </Trigger>
596
                        </ControlTemplate.Triggers>
597
                    </ControlTemplate>
598
                </Setter.Value>
599
            </Setter>
600
        </Style>
601
602
        <Style x:Key="{x:Type ListViewItem}" TargetType="{x:Type ListViewItem}">
603
            <Setter Property="SnapsToDevicePixels" Value="true"/>
604
            <Setter Property="OverridesDefaultStyle" Value="true"/>
605
            <Setter Property="HorizontalContentAlignment" Value="Stretch" />
606
            <Setter Property="VerticalContentAlignment" Value="Center" />
607
            <Setter Property="Foreground" Value="#000000"/>
608
609
            <Setter Property="Template">
610
                <Setter.Value>
611
                    <ControlTemplate TargetType="{x:Type ListBoxItem}">
612
                        <Border Name="Border" Padding="2" SnapsToDevicePixels="true"  CornerRadius="4" Margin="0,2,0,2">
613
                            <GridViewRowPresenter VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
614
                        </Border>
615
                        <ControlTemplate.Triggers>
616
                            <Trigger Property="ItemsControl.AlternationIndex" Value="1">
617
                                <Setter Property="Background" TargetName="Border"  Value="#A5FFFFFF"></Setter>
618
                            </Trigger>
619
                            <Trigger Property="ItemsControl.AlternationIndex" Value="2">
620
                                <Setter Property="Background" TargetName="Border"  Value="Transparent"></Setter>
621
                            </Trigger>
622
                            <Trigger Property="IsSelected" Value="true">
623
                                <Setter Property="Background" TargetName="Border" Value="#99B4C6"/>
624
                                <Setter Property="Foreground" Value="#000000"/>
625
                            </Trigger>
626
                            <Trigger Property="IsMouseOver" Value="true">
627
                                <Setter Property="Background" TargetName="Border" Value="#c5d7e5"/>
628
                                <Setter Property="Foreground" Value="#000000"/>
629
                            </Trigger>
630
                            <Trigger Property="IsEnabled" Value="false">
631
                                <Setter Property="Foreground" Value="#000000"/>
632
                            </Trigger>
633
                        </ControlTemplate.Triggers>
634
                    </ControlTemplate>
635
                </Setter.Value>
636
            </Setter>
637
        </Style>
638
639
    <Style x:Key="ToggleButtonBlue" TargetType="{x:Type ToggleButton}">
640
        <Setter Property="SnapsToDevicePixels" Value="true"/>
641
        <Setter Property="OverridesDefaultStyle" Value="true"/>
642
        <Setter Property="FocusVisualStyle" Value="{StaticResource ButtonFocusVisual}"/>
643
        <Setter Property="MinHeight" Value="22"/>
644
        <Setter Property="MinWidth" Value="60"/>
645
        <Setter Property="Template">
646
            <Setter.Value>                
647
                <ControlTemplate TargetType="{x:Type ToggleButton}">
648
                    <Border x:Name="Border" 
649
                                CornerRadius="4" 
650
                                BorderThickness="1" 
651
                                Background="{StaticResource NormalBrush}" 
652
                                BorderBrush="{StaticResource NormalBorderBrush}">
653
                        <ContentPresenter Margin="2" 
654
                                              HorizontalAlignment="Center" 
655
                                              VerticalAlignment="Center" 
656
                                              RecognizesAccessKey="True"/>
657
                    </Border>
658
                    <ControlTemplate.Triggers>
659
                        <Trigger Property="IsKeyboardFocused" Value="true">
660
                            <Setter TargetName="Border" Property="BorderBrush" Value="{StaticResource DefaultedBorderBrush}" />
661
                        </Trigger>
662
                        <Trigger Property="IsMouseOver" Value="true">
663
                            <Setter TargetName="Border" Property="Background" Value="{StaticResource DarkBrush}" />
664
                        </Trigger>
665
                        <Trigger Property="IsPressed" Value="true">
666
                            <Setter TargetName="Border" Property="Background" Value="{StaticResource PressedBrush}" />
667
                            <Setter TargetName="Border" Property="BorderBrush" Value="{StaticResource PressedBorderBrush}" />
668
                        </Trigger>
669
                        <Trigger Property="IsEnabled" Value="false">
670
                            <Setter TargetName="Border" Property="Background" Value="{StaticResource DisabledBackgroundBrush}" />
671
                            <Setter TargetName="Border" Property="BorderBrush" Value="{StaticResource DisabledBorderBrush}" />
672
                            <Setter Property="Foreground" Value="{StaticResource DisabledForegroundBrush}"/>
673
                        </Trigger>
674
                        <Trigger Property="IsChecked" Value="true">
675
                            <Setter TargetName="Border" Property="Background" Value="{StaticResource ToggledBrush}" />
676
                            <Setter TargetName="Border" Property="BorderBrush" Value="{StaticResource PressedBorderBrush}" />
677
                            <Setter Property="Foreground" Value="White"/>
678
                        </Trigger>
679
                    </ControlTemplate.Triggers>
680
                </ControlTemplate>
681
            </Setter.Value>
682
        </Setter>
683
    </Style>
684
685
    <!-- ComboBox -->
686
687
        <ControlTemplate x:Key="ComboBoxToggleButton" TargetType="{x:Type ToggleButton}">
688
            <Grid>
689
                <Grid.ColumnDefinitions>
690
                    <ColumnDefinition />
691
                    <ColumnDefinition Width="20" />
692
                </Grid.ColumnDefinitions>
693
                <Border
694
        x:Name="Border" 
695
        Grid.ColumnSpan="2"
696
        CornerRadius="0,0,0,0"
697
        Background="{DynamicResource SelectedBackgroundBrush}"
698
        BorderBrush="{DynamicResource DisabledForegroundBrush}"
699
        BorderThickness="1" />
700
                <Border 
701
        Grid.Column="0"
702
        CornerRadius="0,0,0,0" 
703
        Margin="1" 
704
        Background="{DynamicResource SelectedBackgroundBrush}" 
705
        BorderBrush="{DynamicResource DisabledBorderBrush}"
706
        BorderThickness="0,0,1,0" />
707
                <Path 
708
        x:Name="Arrow"
709
        Grid.Column="1"     
710
        Fill="{StaticResource GlyphBrush}"
711
        HorizontalAlignment="Center"
712
        VerticalAlignment="Center"
713
        Data="M 0 0 L 4 4 L 8 0 Z"/>
714
            </Grid>
715
            <ControlTemplate.Triggers>
716
                <Trigger Property="ToggleButton.IsMouseOver" Value="true">
717
                    <Setter Property="Background" TargetName="Border" Value="{DynamicResource SolidBorderBrush}"/>
718
                </Trigger>
719
                <Trigger Property="ToggleButton.IsChecked" Value="true">
720
                    <Setter Property="Background" TargetName="Border" Value="{DynamicResource PressedBrush}"/>
721
                </Trigger>
722
                <Trigger Property="IsEnabled" Value="False">
723
                    <Setter TargetName="Border" Property="Background" Value="{StaticResource DisabledBackgroundBrush}" />
724
                    <Setter TargetName="Border" Property="BorderBrush" Value="{StaticResource DisabledBorderBrush}" />
725
                    <Setter Property="Foreground" Value="{StaticResource DisabledForegroundBrush}"/>
726
                    <Setter TargetName="Arrow" Property="Fill" Value="{StaticResource DisabledForegroundBrush}" />
727
                </Trigger>
728
            </ControlTemplate.Triggers>
729
        </ControlTemplate>
730
731
        <ControlTemplate x:Key="ComboBoxTextBox" TargetType="{x:Type TextBox}">
732
            <Border x:Name="PART_ContentHost" Focusable="False" Background="{TemplateBinding Background}" />
733
        </ControlTemplate>
734
735
        <Style x:Key="{x:Type ComboBox}" TargetType="{x:Type ComboBox}">
736
            <Setter Property="SnapsToDevicePixels" Value="true"/>
737
            <Setter Property="OverridesDefaultStyle" Value="true"/>
738
            <Setter Property="ScrollViewer.HorizontalScrollBarVisibility" Value="Auto"/>
739
            <Setter Property="ScrollViewer.VerticalScrollBarVisibility" Value="Auto"/>
740
            <Setter Property="ScrollViewer.CanContentScroll" Value="true"/>
741
            <Setter Property="MinWidth" Value="40"/>
742
            <Setter Property="MinHeight" Value="20"/>
743
            <Setter Property="Template">
744
                <Setter.Value>
745
                    <ControlTemplate TargetType="{x:Type ComboBox}">
746
                        <Grid>
747
                            <Grid.Background>
748
                                <DrawingBrush Viewbox="0,0,20,20" ViewboxUnits="Absolute">
749
                                    <DrawingBrush.Drawing>
750
                                        <DrawingGroup>
751
                                            <GeometryDrawing Brush="#FFD3D3D3">
752
                                                <GeometryDrawing.Geometry>
753
                                                    <RectangleGeometry Rect="0,0,20,20"/>
754
                                                </GeometryDrawing.Geometry>
755
                                            </GeometryDrawing>
756
                                            <GeometryDrawing Brush="#FF000000">
757
                                                <GeometryDrawing.Geometry>
758
                                                    <EllipseGeometry Center="0,0" RadiusX="10" RadiusY="10"/>
759
                                                </GeometryDrawing.Geometry>
760
                                            </GeometryDrawing>
761
                                            <GeometryDrawing Brush="#FF000000">
762
                                                <GeometryDrawing.Geometry>
763
                                                    <EllipseGeometry Center="20,20" RadiusX="10" RadiusY="10"/>
764
                                                </GeometryDrawing.Geometry>
765
                                            </GeometryDrawing>
766
                                            <GeometryDrawing Brush="#FFFFFFFF">
767
                                                <GeometryDrawing.Geometry>
768
                                                    <EllipseGeometry Center="20,0" RadiusX="10" RadiusY="10"/>
769
                                                </GeometryDrawing.Geometry>
770
                                            </GeometryDrawing>
771
                                            <GeometryDrawing Brush="#FFFFFFFF">
772
                                                <GeometryDrawing.Geometry>
773
                                                    <EllipseGeometry Center="0,20" RadiusX="10" RadiusY="10"/>
774
                                                </GeometryDrawing.Geometry>
775
                                            </GeometryDrawing>
776
                                        </DrawingGroup>
777
                                    </DrawingBrush.Drawing>
778
                                </DrawingBrush>
779
                            </Grid.Background>
780
                            <ToggleButton 
781
              Name="ToggleButton" 
782
              Template="{StaticResource ComboBoxToggleButton}" 
783
              Grid.Column="2" 
784
              Focusable="false"
785
              IsChecked="{Binding Path=IsDropDownOpen,Mode=TwoWay,RelativeSource={RelativeSource TemplatedParent}}"
786
              ClickMode="Press">
787
                            </ToggleButton>
788
                            <ContentPresenter
789
              Name="ContentSite"
790
              IsHitTestVisible="False" 
791
              Content="{TemplateBinding SelectionBoxItem}"
792
              ContentTemplate="{TemplateBinding SelectionBoxItemTemplate}"
793
              ContentTemplateSelector="{TemplateBinding ItemTemplateSelector}"
794
              Margin="3,3,23,3"
795
              VerticalAlignment="Center"
796
              HorizontalAlignment="Left" />
797
                            <TextBox x:Name="PART_EditableTextBox"
798
              Style="{x:Null}" 
799
              Template="{StaticResource ComboBoxTextBox}" 
800
              HorizontalAlignment="Left" 
801
              VerticalAlignment="Center" 
802
              Margin="3,3,23,3"
803
              Focusable="True" 
804
              Background="Transparent"
805
              Visibility="Hidden"
806
              IsReadOnly="{TemplateBinding IsReadOnly}"/>
807
                            <Popup 
808
              Name="Popup"
809
              Placement="Bottom"
810
              IsOpen="{TemplateBinding IsDropDownOpen}"
811
              AllowsTransparency="True" 
812
              Focusable="False"
813
              PopupAnimation="Slide">
814
                                <Grid 
815
                Name="DropDown"
816
                SnapsToDevicePixels="True"                
817
                MinWidth="{TemplateBinding ActualWidth}"
818
                MaxHeight="{TemplateBinding MaxDropDownHeight}">
819
                                    <Border 
820
                  x:Name="DropDownBorder"
821
                  BorderThickness="1"
822
                  BorderBrush="{StaticResource SolidBorderBrush}" Background="{DynamicResource SelectedBackgroundBrush}"/>
823
                                    <ScrollViewer Margin="4,6,4,6" SnapsToDevicePixels="True">
824
                                        <StackPanel IsItemsHost="True" KeyboardNavigation.DirectionalNavigation="Contained" />
825
                                    </ScrollViewer>
826
                                </Grid>
827
                            </Popup>
828
                        </Grid>
829
                        <ControlTemplate.Triggers>
830
                            <Trigger Property="HasItems" Value="false">
831
                                <Setter TargetName="DropDownBorder" Property="MinHeight" Value="95"/>
832
                            </Trigger>
833
                            <Trigger Property="IsEnabled" Value="false">
834
                                <Setter Property="Foreground" Value="{StaticResource DisabledForegroundBrush}"/>
835
                            </Trigger>
836
                            <Trigger Property="IsGrouping" Value="true">
837
                                <Setter Property="ScrollViewer.CanContentScroll" Value="false"/>
838
                            </Trigger>
839
                            <Trigger SourceName="Popup" Property="Popup.AllowsTransparency" Value="true">
840
                                <Setter TargetName="DropDownBorder" Property="CornerRadius" Value="0"/>
841
                                <Setter TargetName="DropDownBorder" Property="Margin" Value="0,2,0,0"/>
842
                            </Trigger>
843
                            <Trigger Property="IsEditable"
844
                 Value="true">
845
                                <Setter Property="IsTabStop" Value="false"/>
846
                                <Setter TargetName="PART_EditableTextBox" Property="Visibility"	Value="Visible"/>
847
                                <Setter TargetName="ContentSite" Property="Visibility" Value="Hidden"/>
848
                            </Trigger>
849
                        </ControlTemplate.Triggers>
850
                    </ControlTemplate>
851
                </Setter.Value>
852
            </Setter>
853
            <Style.Triggers>
854
            </Style.Triggers>
855
        </Style>
856
857
        <!-- ComboBoxItem -->
858
859
        <Style x:Key="{x:Type ComboBoxItem}" TargetType="{x:Type ComboBoxItem}">
860
            <Setter Property="SnapsToDevicePixels" Value="true"/>
861
            <Setter Property="OverridesDefaultStyle" Value="true"/>
862
            <Setter Property="Template">
863
                <Setter.Value>
864
                    <ControlTemplate TargetType="{x:Type ComboBoxItem}">
865
                        <Border 
866
            Name="Border"
867
            Padding="2"
868
            SnapsToDevicePixels="true">
869
                            <ContentPresenter />
870
                        </Border>
871
                        <ControlTemplate.Triggers>
872
                            <Trigger Property="IsHighlighted" Value="true">
873
                                <Setter Property="Background" TargetName="Border" Value="#FFC5D7E5"/>
874
                            </Trigger>
875
                            <Trigger Property="IsEnabled" Value="false">
876
                                <Setter Property="Foreground" Value="{StaticResource DisabledForegroundBrush}"/>
877
                            </Trigger>
878
                        </ControlTemplate.Triggers>
879
                    </ControlTemplate>
880
                </Setter.Value>
881
            </Setter>
882
        </Style>
883
884
        <!-- Expander -->
885
886
        <ControlTemplate x:Key="ExpanderToggleButton" TargetType="{x:Type ToggleButton}">
887
            <Border
888
      Name="Border" 
889
      CornerRadius="0,0,0,0"
890
      Background="{x:Null}"
891
      BorderBrush="{x:Null}"
892
      BorderThickness="0,0,1,0">
893
                <Path 
894
        Name="Arrow"
895
        Fill="#FF4682B4"
896
        HorizontalAlignment="Center"
897
        VerticalAlignment="Center"
898
        Data="M 0 0 L 4 4 L 8 0 Z"/>
899
            </Border>
900
            <ControlTemplate.Triggers>
901
                <Trigger Property="ToggleButton.IsMouseOver" Value="true">
902
                    <Setter Property="Background" TargetName="Border" Value="{x:Null}"/>
903
                    <Setter Property="Fill" TargetName="Arrow" Value="#FF060606"/>
904
                </Trigger>
905
                <Trigger Property="IsPressed" Value="true">
906
                    <Setter Property="Background" TargetName="Border" Value="{x:Null}"/>
907
                    <Setter Property="Fill" TargetName="Arrow" Value="#FF093E6A"/>
908
                </Trigger>
909
                <Trigger Property="IsChecked" Value="true">
910
                    <Setter TargetName="Arrow" Property="Data" Value="M 0 4 L 4 0 L 8 4 Z" />
911
                    <Setter Property="Fill" TargetName="Arrow" Value="#FF093E6A"/>
912
                </Trigger>
913
                <Trigger Property="IsEnabled" Value="False">
914
                    <Setter Property="Foreground" Value="{StaticResource DisabledForegroundBrush}"/>
915
                    <Setter TargetName="Arrow" Property="Fill" Value="{StaticResource DisabledForegroundBrush}" />
916
                    <Setter Property="Background" TargetName="Border" Value="{x:Null}"/>
917
                    <Setter Property="BorderBrush" TargetName="Border" Value="{x:Null}"/>
918
                </Trigger>
919
            </ControlTemplate.Triggers>
920
        </ControlTemplate>
921
922
        <Style TargetType="{x:Type Expander}">
923
            <Setter Property="Template">
924
                <Setter.Value>
925
                    <ControlTemplate TargetType="{x:Type Expander}">
926
                        <Grid>
927
                            <Grid.RowDefinitions>
928
                                <RowDefinition Height="Auto"/>
929
                                <RowDefinition Name="ContentRow" Height="0"/>
930
                            </Grid.RowDefinitions>
931
                            <Border 
932
              Name="Border" 
933
              Grid.Row="0" 
934
              Background="{x:Null}"
935
              BorderBrush="{x:Null}"
936
              BorderThickness="1" 
937
              CornerRadius="0,0,0,0" >
938
                                <Grid>
939
                                    <Grid.ColumnDefinitions>
940
                                        <ColumnDefinition Width="20" />
941
                                        <ColumnDefinition Width="*" />
942
                                    </Grid.ColumnDefinitions>
943
                                    <ToggleButton
944
                  IsChecked="{Binding Path=IsExpanded,Mode=TwoWay,RelativeSource={RelativeSource TemplatedParent}}"
945
                  OverridesDefaultStyle="True" 
946
                  Template="{StaticResource ExpanderToggleButton}" 
947
                  Background="#FF4682B4" />
948
                                    <ContentPresenter 
949
                  Grid.Column="1"
950
                  Margin="4" 
951
                  ContentSource="Header" 
952
                  RecognizesAccessKey="True" />
953
                                </Grid>
954
                            </Border>
955
                            <Border 
956
              Name="Content" 
957
              Grid.Row="1" 
958
              Background="{x:Null}"
959
              BorderBrush="{x:Null}" 
960
              BorderThickness="1,0,1,1" 
961
              CornerRadius="0,0,2,2" >
962
                                <ContentPresenter Margin="4" />
963
                            </Border>
964
                        </Grid>
965
                        <ControlTemplate.Triggers>
966
                            <Trigger Property="IsExpanded" Value="True">
967
                                <Setter TargetName="ContentRow" Property="Height" Value="{Binding ElementName=Content,Path=DesiredHeight}" />
968
                            </Trigger>
969
                            <Trigger Property="IsEnabled" Value="False">
970
                                <Setter Property="Foreground" Value="{StaticResource DisabledForegroundBrush}"/>
971
                                <Setter Property="Background" TargetName="Border" Value="{DynamicResource DisabledBorderBrush}"/>
972
                                <Setter Property="BorderBrush" TargetName="Border" Value="{DynamicResource DisabledForegroundBrush}"/>
973
                            </Trigger>
974
975
                        </ControlTemplate.Triggers>
976
                    </ControlTemplate>
977
                </Setter.Value>
978
            </Setter>
979
        </Style>    
980
    
981
        <!-- Focus Visual -->
982
983
        <Style x:Key="RadioButtonFocusVisual">
984
            <Setter Property="Control.Template">
985
                <Setter.Value>
986
                    <ControlTemplate>
987
                        <Border>
988
                            <Rectangle 
989
              Margin="15,0,0,0"
990
              StrokeThickness="1"
991
              Stroke="#60000000"
992
              StrokeDashArray="1 2"/>
993
                        </Border>
994
                    </ControlTemplate>
995
                </Setter.Value>
996
            </Setter>
997
        </Style>
998
999
        <!-- RadioButton -->
1000
1001
        <Style x:Key="{x:Type RadioButton}" TargetType="{x:Type RadioButton}">
1002
            <Setter Property="SnapsToDevicePixels" Value="true"/>
1003
            <Setter Property="OverridesDefaultStyle" Value="true"/>
1004
            <Setter Property="FocusVisualStyle"	Value="{StaticResource RadioButtonFocusVisual}"/>
1005
            <Setter Property="Template">
1006
                <Setter.Value>
1007
                    <ControlTemplate TargetType="{x:Type RadioButton}">
1008
                        <BulletDecorator Background="Transparent">
1009
                            <BulletDecorator.Bullet>
1010
                                <Grid Width="13" 
1011
                Height="13" >
1012
                                    <Ellipse x:Name="Border"  
1013
                  Fill="{StaticResource NormalBrush}"
1014
                  StrokeThickness="1"
1015
                  Stroke="{StaticResource NormalBorderBrush}" />
1016
                                    <Path Height="8" x:Name="CheckMark" Width="8" Opacity="1" Fill="{StaticResource GlyphBrush}"
1017
				   Stretch="Fill" 
1018
				   Data="M102.03442,598.79645 L105.22962,597.78918 L106.78825,600.42358 C106.78825,600.42358 108.51028,595.74304 110.21724,593.60419 C112.00967,591.35822 114.89314,591.42316 114.89314,591.42316 C114.89314,591.42316 112.67844,593.42645 111.93174,594.44464 C110.7449,596.06293 107.15683,604.13837 107.15683,604.13837 z" 
1019
				   Canvas.ZIndex="1"/>
1020
                                </Grid>
1021
                            </BulletDecorator.Bullet>
1022
                            <ContentPresenter 
1023
              Margin="4,0,0,0"
1024
              VerticalAlignment="Center"
1025
              HorizontalAlignment="Left"
1026
              RecognizesAccessKey="True"/>
1027
                        </BulletDecorator>
1028
                        <ControlTemplate.Triggers>
1029
                            <Trigger Property="IsChecked" Value="false">
1030
                                <Setter TargetName="CheckMark" Property="Visibility" Value="Collapsed"/>
1031
                            </Trigger>
1032
                            <Trigger Property="IsMouseOver" Value="true">
1033
                                <Setter TargetName="Border" Property="Fill" Value="{StaticResource DarkBrush}" />
1034
                            </Trigger>
1035
                            <Trigger Property="IsPressed" Value="true">
1036
                                <Setter TargetName="Border" Property="Fill" Value="{StaticResource PressedBrush}" />
1037
                                <Setter TargetName="Border" Property="Stroke" Value="{StaticResource GlyphBrush}" />
1038
                            </Trigger>
1039
                            <Trigger Property="IsEnabled" Value="false">
1040
                                <Setter TargetName="Border" Property="Fill" Value="{StaticResource DisabledBackgroundBrush}" />
1041
                                <Setter TargetName="Border" Property="Stroke" Value="#40000000" />
1042
                                <Setter Property="Foreground" Value="#80000000"/>
1043
                            </Trigger>
1044
                        </ControlTemplate.Triggers>
1045
                    </ControlTemplate>
1046
                </Setter.Value>
1047
            </Setter>
1048
        </Style>
1049
1050
        <!-- Custom TextBox -->
1051
1052
        <Style x:Key="CustomTextBoxStyle" TargetType="{x:Type TextBoxBase}">
1053
            <Setter Property="SnapsToDevicePixels" Value="True"/>
1054
            <Setter Property="OverridesDefaultStyle" Value="True"/>
1055
            <Setter Property="KeyboardNavigation.TabNavigation" Value="None"/>
1056
            <Setter Property="FocusVisualStyle" Value="{x:Null}"/>
1057
            <Setter Property="Foreground" Value="#ffffff"/>
1058
            <Setter Property="MinWidth" Value="120"/>
1059
            <Setter Property="MinHeight" Value="30"/>
1060
            <Setter Property="AllowDrop" Value="true"/>
1061
            <Setter Property="Template">
1062
                <Setter.Value>
1063
                    <ControlTemplate TargetType="{x:Type TextBoxBase}">
1064
                        <Border 
1065
            Name="Border"
1066
            CornerRadius="12" 
1067
            Padding="5"
1068
            Background="Transparent"
1069
            BorderBrush="#ffffff"
1070
            BorderThickness="1" >
1071
                            <ScrollViewer Margin="0" x:Name="PART_ContentHost"/>
1072
                        </Border>
1073
                        <ControlTemplate.Triggers>
1074
                            <Trigger Property="IsEnabled" Value="False">
1075
                                <Setter TargetName="Border" Property="Background" Value="Transparent"/>
1076
                                <Setter TargetName="Border" Property="BorderBrush" Value="{StaticResource DisabledBackgroundBrush}"/>
1077
                                <Setter Property="Foreground" Value="{StaticResource DisabledForegroundBrush}"/>
1078
                            </Trigger>
1079
                        </ControlTemplate.Triggers>
1080
                    </ControlTemplate>
1081
                </Setter.Value>
1082
            </Setter>
1083
        </Style>
1084
1085
        <!-- Popup TextBox -->
1086
1087
        <Style x:Key="PopupTextBoxStyle" TargetType="TextBoxBase">
1088
            <Setter Property="SnapsToDevicePixels" Value="True"/>
1089
            <Setter Property="OverridesDefaultStyle" Value="True"/>
1090
            <Setter Property="KeyboardNavigation.TabNavigation" Value="None"/>
1091
            <Setter Property="FocusVisualStyle" Value="{x:Null}"/>
1092
            <Setter Property="Foreground" Value="#FF000000"/>
1093
            <Setter Property="MinWidth" Value="120"/>
1094
            <Setter Property="MinHeight" Value="30"/>
1095
            <Setter Property="AllowDrop" Value="true"/>
1096
            <Setter Property="Template">
1097
                <Setter.Value>
1098
                    <ControlTemplate TargetType="{x:Type TextBoxBase}">
1099
                        <Border 
1100
                        Name="Border"
1101
                        CornerRadius="2" 
1102
                        Padding="5"
1103
                        Background="Transparent"
1104
                        BorderBrush="Transparent"            
1105
                        BorderThickness="1">
1106
                            <ScrollViewer Margin="0" x:Name="PART_ContentHost"/>
1107
                        </Border>
1108
                        <ControlTemplate.Triggers>
1109
                            <Trigger Property="IsEnabled" Value="False">
1110
                                <Setter TargetName="Border" Property="Background" Value="Transparent"/>
1111
                                <Setter TargetName="Border" Property="BorderBrush" Value="{StaticResource DisabledBackgroundBrush}"/>
1112
                                <Setter Property="Foreground" Value="{StaticResource DisabledForegroundBrush}"/>
1113
                            </Trigger>
1114
                        </ControlTemplate.Triggers>
1115
                    </ControlTemplate>
1116
                </Setter.Value>
1117
            </Setter>
1118
        </Style>
1119
1120
1121
        <!-- Buy/Sell Grid buttons -->
1122
1123
        <ControlTemplate x:Key="AddButtonTemplate" TargetType="Button">
1124
            <Border Width="18" Height="18" Background="#00000000" Margin="2,0,2,0">
1125
                <Grid>
1126
                    <Path x:Name="path1" Height="16" Width="16" RenderTransformOrigin="0.5,0.5" Fill="{x:Null}" Stretch="Fill" Stroke="#FF8C8C8C" StrokeThickness="1" Data="M7.5,1.5 L10.5,1.5 L10.5,7.5 L16.5,7.5 L16.5,10.5 L10.5,10.5 L10.5,16.5 L7.5,16.5 L7.5,10.5 L1.5,10.5 L1.5,7.5 L7.5,7.5 z" Margin="1,-1,1,3">
1127
                        <Path.RenderTransform>
1128
                            <TransformGroup>
1129
                                <ScaleTransform/>
1130
                                <SkewTransform/>
1131
                                <RotateTransform Angle="-90"/>
1132
                                <TranslateTransform Y="2" X="0"/>
1133
                            </TransformGroup>
1134
                        </Path.RenderTransform>
1135
                    </Path>
1136
                    <Path x:Name="path" Height="16" Width="16" RenderTransformOrigin="0.5,0.5" Fill="#FF032E9C" Stretch="Fill" Data="M7.5,1.5 L10.5,1.5 L10.5,7.5 L16.5,7.5 L16.5,10.5 L10.5,10.5 L10.5,16.5 L7.5,16.5 L7.5,10.5 L1.5,10.5 L1.5,7.5 L7.5,7.5 z" StrokeThickness="0" Margin="1,-1,1,3">
1137
                        <Path.RenderTransform>
1138
                            <TransformGroup>
1139
                                <ScaleTransform/>
1140
                                <SkewTransform/>
1141
                                <RotateTransform Angle="-90"/>
1142
                                <TranslateTransform Y="2" X="0"/>
1143
                            </TransformGroup>
1144
                        </Path.RenderTransform>
1145
                    </Path>
1146
                </Grid>
1147
            </Border>
1148
            <ControlTemplate.Triggers>
1149
                <Trigger Property="IsMouseOver" Value="True">
1150
                    <Setter TargetName="path1" Property="Visibility" Value="Collapsed" />
1151
                    <Setter TargetName="path" Property="Visibility" Value="Visible" />
1152
                </Trigger>
1153
                <Trigger Property="IsMouseOver" Value="False">
1154
                    <Setter TargetName="path1" Property="Visibility" Value="Visible" />
1155
                    <Setter TargetName="path" Property="Visibility" Value="Collapsed" />
1156
                </Trigger>
1157
            </ControlTemplate.Triggers>
1158
        </ControlTemplate>
1159
1160
        <ControlTemplate x:Key="RemoveXButtonTemplate" TargetType="Button">
1161
            <Border Width="18" Height="18" Background="#00000000" Margin="2,0,2,0">
1162
                <Grid RenderTransformOrigin="0.5,0.5">
1163
                    <Grid.RenderTransform>
1164
                        <TransformGroup>
1165
                            <ScaleTransform/>
1166
                            <SkewTransform/>
1167
                            <RotateTransform Angle="45"/>
1168
                            <TranslateTransform/>
1169
                        </TransformGroup>
1170
                    </Grid.RenderTransform>
1171
                    <Path x:Name="path1" Height="16" Width="16" RenderTransformOrigin="0.5,0.5" Fill="{x:Null}" Stretch="Fill" Stroke="#FF8C8C8C" StrokeThickness="1" Data="M7.5,1.5 L10.5,1.5 L10.5,7.5 L16.5,7.5 L16.5,10.5 L10.5,10.5 L10.5,16.5 L7.5,16.5 L7.5,10.5 L1.5,10.5 L1.5,7.5 L7.5,7.5 z" Margin="1,-1,1,3">
1172
                        <Path.RenderTransform>
1173
                            <TransformGroup>
1174
                                <ScaleTransform/>
1175
                                <SkewTransform/>
1176
                                <RotateTransform Angle="-90"/>
1177
                                <TranslateTransform Y="2" X="0"/>
1178
                            </TransformGroup>
1179
                        </Path.RenderTransform>
1180
                    </Path>
1181
                    <Path x:Name="path" Height="16" Width="16" RenderTransformOrigin="0.5,0.5" Fill="#FFD60808" Stretch="Fill" Data="M7.5,1.5 L10.5,1.5 L10.5,7.5 L16.5,7.5 L16.5,10.5 L10.5,10.5 L10.5,16.5 L7.5,16.5 L7.5,10.5 L1.5,10.5 L1.5,7.5 L7.5,7.5 z" StrokeThickness="0" Margin="1,-1,1,3">
1182
                        <Path.RenderTransform>
1183
                            <TransformGroup>
1184
                                <ScaleTransform/>
1185
                                <SkewTransform/>
1186
                                <RotateTransform Angle="-90"/>
1187
                                <TranslateTransform Y="2" X="0"/>
1188
                            </TransformGroup>
1189
                        </Path.RenderTransform>
1190
                    </Path>
1191
                </Grid>
1192
            </Border>
1193
            <ControlTemplate.Triggers>
1194
                <Trigger Property="IsMouseOver" Value="True">
1195
                    <Setter TargetName="path1" Property="Visibility" Value="Collapsed" />
1196
                    <Setter TargetName="path" Property="Visibility" Value="Visible" />
1197
                </Trigger>
1198
                <Trigger Property="IsMouseOver" Value="False">
1199
                    <Setter TargetName="path1" Property="Visibility" Value="Visible" />
1200
                    <Setter TargetName="path" Property="Visibility" Value="Collapsed" />
1201
                </Trigger>
1202
            </ControlTemplate.Triggers>
1203
        </ControlTemplate>
1204
1205
        <ControlTemplate x:Key="RemoveButtonTemplate" TargetType="Button">
1206
            <Border Width="18" Height="18" Background="#00000000" Margin="2,0,2,0">
1207
                <Grid>
1208
                    <Path x:Name="path1" Height="4" Width="16" RenderTransformOrigin="0.5,0.5" Fill="{x:Null}" Stretch="Fill" Stroke="#FF8C8C8C" StrokeThickness="1" Data="M7.5,1.5 L10.5,1.5 L10.5,16.5 L7.5,16.5 z" HorizontalAlignment="Center" VerticalAlignment="Center"/>
1209
                    <Path x:Name="path" RenderTransformOrigin="0.5,0.5" Fill="#FFD60808" Stretch="Fill" Data="M7.5,1.5 L10.5,1.5 L10.5,16.5 L7.5,16.5 z" Height="4" Width="16"/>
1210
                </Grid>
1211
            </Border>
1212
            <ControlTemplate.Triggers>
1213
                <Trigger Property="IsMouseOver" Value="True">
1214
                    <Setter TargetName="path1" Property="Visibility" Value="Collapsed" />
1215
                    <Setter TargetName="path" Property="Visibility" Value="Visible" />
1216
                </Trigger>
1217
                <Trigger Property="IsMouseOver" Value="False">
1218
                    <Setter TargetName="path1" Property="Visibility" Value="Visible" />
1219
                    <Setter TargetName="path" Property="Visibility" Value="Collapsed" />
1220
                </Trigger>
1221
            </ControlTemplate.Triggers>
1222
        </ControlTemplate>
1223
1224
        <!-- Submit/Cancel buttons -->
1225
1226
        <LinearGradientBrush x:Key="SubmitButtonEnabledBG" EndPoint="0.5,1" StartPoint="0.5,0">
1227
            <GradientStop Color="#FF006C3B" Offset="0.163"/>
1228
            <GradientStop Color="#FF00A04D" Offset="1"/>
1229
        </LinearGradientBrush>
1230
        <LinearGradientBrush x:Key="SubmitButtonDisabledBG" EndPoint="0.5,1" StartPoint="0.5,0">
1231
            <GradientStop Color="#FF6C6C6C" Offset="0.163"/>
1232
            <GradientStop Color="#FF9F9F9F" Offset="1"/>
1233
        </LinearGradientBrush>
1234
1235
        <ControlTemplate x:Key="SubmitButtonTemplate" TargetType="Button">
1236
            <Grid Height="{TemplateBinding Height}">
1237
                <Border Width="105" x:Name="BgEnabled" Background="#FF006C3B" BorderBrush="#FFFFFFFF" BorderThickness="2,2,1,2" CornerRadius="9,0,0,9" HorizontalAlignment="Right">
1238
                    <TextBlock x:Name="textBlock" Text="{TemplateBinding Content}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#FFFFFFFF" />
1239
                </Border>
1240
            </Grid>
1241
            <ControlTemplate.Triggers>
1242
1243
                <Trigger Property="IsEnabled" Value="false">
1244
                    <Trigger.EnterActions>
1245
                        <BeginStoryboard>
1246
                            <Storyboard>
1247
                                <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.3" Storyboard.TargetName="textBlock" Storyboard.TargetProperty="(UIElement.Opacity)"  AutoReverse="true">
1248
                                    <SplineDoubleKeyFrame KeyTime="00:00:00.3" Value="0" KeySpline="0.5,0,0.5,1" />
1249
                                </DoubleAnimationUsingKeyFrames>
1250
                                <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.3" Storyboard.TargetName="BgEnabled" Storyboard.TargetProperty="(FrameworkElement.Width)"  AutoReverse="true">
1251
                                    <SplineDoubleKeyFrame KeyTime="00:00:00.3" Value="0" KeySpline="0.5,0,0.5,1" />
1252
                                </DoubleAnimationUsingKeyFrames>
1253
                                <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.3" Storyboard.TargetName="BgEnabled" Storyboard.TargetProperty="(UIElement.Opacity)"  AutoReverse="true">
1254
                                    <SplineDoubleKeyFrame KeyTime="00:00:00.3" Value="0" KeySpline="0.5,0,0.5,1" />
1255
                                </DoubleAnimationUsingKeyFrames>
1256
                                <ColorAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.2" Storyboard.TargetName="BgEnabled" Storyboard.TargetProperty="(Border.Background).(SolidColorBrush.Color)">
1257
                                    <SplineColorKeyFrame KeyTime="00:00:00.1" Value="#FF006C3B"/>
1258
                                    <SplineColorKeyFrame KeyTime="00:00:00.2" Value="#FF6C6C6C"/>
1259
                                </ColorAnimationUsingKeyFrames>
1260
                            </Storyboard>
1261
                        </BeginStoryboard>
1262
                    </Trigger.EnterActions>
1263
                    <Trigger.ExitActions>
1264
                        <BeginStoryboard>
1265
                            <Storyboard>
1266
                                <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.3" Storyboard.TargetName="textBlock" Storyboard.TargetProperty="(UIElement.Opacity)"  AutoReverse="true">
1267
                                    <SplineDoubleKeyFrame KeyTime="00:00:00.3" Value="0" KeySpline="0.5,0,0.5,1" />
1268
                                </DoubleAnimationUsingKeyFrames>
1269
                                <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.3" Storyboard.TargetName="BgEnabled" Storyboard.TargetProperty="(FrameworkElement.Width)"  AutoReverse="true">
1270
                                    <SplineDoubleKeyFrame KeyTime="00:00:00.3" Value="0" KeySpline="0.5,0,0.5,1" />
1271
                                </DoubleAnimationUsingKeyFrames>
1272
                                <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.3" Storyboard.TargetName="BgEnabled" Storyboard.TargetProperty="(UIElement.Opacity)"  AutoReverse="true">
1273
                                    <SplineDoubleKeyFrame KeyTime="00:00:00.3" Value="0" KeySpline="0.5,0,0.5,1" />
1274
                                </DoubleAnimationUsingKeyFrames>
1275
                                <ColorAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.2" Storyboard.TargetName="BgEnabled" Storyboard.TargetProperty="(Border.Background).(SolidColorBrush.Color)">
1276
                                    <SplineColorKeyFrame KeyTime="00:00:00.1" Value="#FF6C6C6C"/>
1277
                                    <SplineColorKeyFrame KeyTime="00:00:00.2" Value="#FF006C3B"/>
1278
                                </ColorAnimationUsingKeyFrames>
1279
                            </Storyboard>
1280
                        </BeginStoryboard>
1281
                    </Trigger.ExitActions>
1282
                </Trigger>
1283
1284
            </ControlTemplate.Triggers>
1285
        </ControlTemplate>
1286
1287
        <ControlTemplate x:Key="CancelButtonTemplate" TargetType="Button">
1288
            <Grid Height="{TemplateBinding Height}">
1289
                <Border Width="105" BorderBrush="#FFFFFFFF" BorderThickness="1,2,2,2" CornerRadius="0,9,9,0" Background="#FFFFFFFF">
1290
                    <TextBlock Text="{TemplateBinding Content}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#FF666666"  Margin="-9,0,0,0" />
1291
                </Border>
1292
            </Grid>
1293
        </ControlTemplate>
1294
1295
        <!-- ScrollBar -->
1296
1297
        <Style x:Key="ScrollBarLineButton" TargetType="{x:Type RepeatButton}">
1298
            <Setter Property="SnapsToDevicePixels" Value="True"/>
1299
            <Setter Property="OverridesDefaultStyle" Value="true"/>
1300
            <Setter Property="Focusable" Value="false"/>
1301
            <Setter Property="Template">
1302
                <Setter.Value>
1303
                    <ControlTemplate TargetType="{x:Type RepeatButton}">
1304
                        <Border 
1305
          x:Name="Border"
1306
          Margin="1" 
1307
          CornerRadius="2" 
1308
          Background="{x:Null}"
1309
          BorderBrush="{x:Null}"
1310
          BorderThickness="1">
1311
                            <Path 
1312
            HorizontalAlignment="Center"
1313
            VerticalAlignment="Center"
1314
            Fill="#404040"
1315
            Data="{Binding Path=Content, RelativeSource={RelativeSource TemplatedParent}}" />
1316
                        </Border>
1317
                        <ControlTemplate.Triggers>
1318
                            <Trigger Property="IsPressed" Value="true">
1319
                                <Setter TargetName="Border" Property="Background" Value="#E0E0E0" />
1320
                            </Trigger>
1321
                            <Trigger Property="IsEnabled" Value="false">
1322
                                <Setter Property="Foreground" Value="#888888"/>
1323
                            </Trigger>
1324
                        </ControlTemplate.Triggers>
1325
                    </ControlTemplate>
1326
                </Setter.Value>
1327
            </Setter>
1328
        </Style>
1329
1330
        <Style x:Key="ScrollBarPageButton" TargetType="{x:Type RepeatButton}">
1331
            <Setter Property="SnapsToDevicePixels" Value="True"/>
1332
            <Setter Property="OverridesDefaultStyle" Value="true"/>
1333
            <Setter Property="IsTabStop" Value="false"/>
1334
            <Setter Property="Focusable" Value="false"/>
1335
            <Setter Property="Template">
1336
                <Setter.Value>
1337
                    <ControlTemplate TargetType="{x:Type RepeatButton}">
1338
                        <Border Background="Transparent" />
1339
                    </ControlTemplate>
1340
                </Setter.Value>
1341
            </Setter>
1342
        </Style>
1343
1344
        <Style x:Key="ScrollBarThumb" TargetType="{x:Type Thumb}">
1345
            <Setter Property="SnapsToDevicePixels" Value="True"/>
1346
            <Setter Property="OverridesDefaultStyle" Value="true"/>
1347
            <Setter Property="IsTabStop" Value="false"/>
1348
            <Setter Property="Focusable" Value="false"/>
1349
            <Setter Property="Template">
1350
                <Setter.Value>
1351
                    <ControlTemplate TargetType="{x:Type Thumb}">
1352
                        <Border 
1353
          CornerRadius="2"
1354
          BorderThickness="1" Background="#FF121212" BorderBrush="#FFCECECE" />
1355
                    </ControlTemplate>
1356
                </Setter.Value>
1357
            </Setter>
1358
        </Style>
1359
1360
    <ControlTemplate x:Key="VerticalScrollBar" TargetType="{x:Type ScrollBar}">
1361
        <Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Margin="0,0,0,0" Width="Auto" >
1362
            <Grid.RowDefinitions>
1363
                <RowDefinition MaxHeight="18" Height="0.409*"/>
1364
                <RowDefinition Height="0.182*"/>
1365
                <RowDefinition MaxHeight="18" Height="0.409*"/>
1366
            </Grid.RowDefinitions>
1367
            <Border
1368
      Grid.RowSpan="3"
1369
      CornerRadius="2" 
1370
      Background="#FF3B3B3B" Margin="15,22,15,22" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" />
1371
            <RepeatButton 
1372
      Grid.Row="0"                           
1373
      Style="{StaticResource ScrollBarLineButton}"
1374
      Height="18"
1375
      Command="ScrollBar.LineUpCommand"
1376
      Content="M 0 4 L 8 4 L 4 0 Z" Margin="10,0,10,0" />
1377
            <Track 
1378
      x:Name="PART_Track"
1379
      Grid.Row="1"
1380
      IsDirectionReversed="true">
1381
                <Track.DecreaseRepeatButton>
1382
                    <RepeatButton 
1383
          Style="{StaticResource ScrollBarPageButton}"
1384
          Command="ScrollBar.PageUpCommand" />
1385
                </Track.DecreaseRepeatButton>
1386
                <Track.Thumb>
1387
                    <Thumb 
1388
          Style="{StaticResource ScrollBarThumb}" 
1389
          Margin="10,0,10,0"  
1390
          Background="#C0C0C0"
1391
          BorderBrush="#404040" Height="Auto" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Width="8" />
1392
                </Track.Thumb>
1393
                <Track.IncreaseRepeatButton>
1394
                    <RepeatButton 
1395
          Style="{StaticResource ScrollBarPageButton}"
1396
          Command="ScrollBar.PageDownCommand" />
1397
                </Track.IncreaseRepeatButton>
1398
            </Track>
1399
            <RepeatButton 
1400
      Grid.Row="3" 
1401
      Style="{StaticResource ScrollBarLineButton}"
1402
      Height="18"
1403
      Command="ScrollBar.LineDownCommand"
1404
      Content="M 0 0 L 4 4 L 8 0 Z" Margin="10,0,10,0"/>
1405
        </Grid>
1406
    </ControlTemplate>
1407
1408
    <ControlTemplate x:Key="HorizontalScrollBar" TargetType="{x:Type ScrollBar}">
1409
        <Grid >
1410
            <Grid.ColumnDefinitions>
1411
                <ColumnDefinition MaxWidth="18"/>
1412
                <ColumnDefinition Width="0.00001*"/>
1413
                <ColumnDefinition MaxWidth="18"/>
1414
            </Grid.ColumnDefinitions>
1415
            <Border
1416
      Grid.ColumnSpan="3"
1417
      CornerRadius="2" 
1418
      Background="#FF3B3B3B" Margin="22,15,22,15" />
1419
            <RepeatButton 
1420
      Grid.Column="0"                           
1421
      Style="{StaticResource ScrollBarLineButton}"
1422
      Width="18"
1423
      Command="ScrollBar.LineLeftCommand"
1424
      Content="M 4 0 L 4 8 L 0 4 Z" Margin="0,10,0,10" />
1425
            <Track 
1426
      x:Name="PART_Track"
1427
      Grid.Column="1"
1428
      IsDirectionReversed="False">
1429
                <Track.DecreaseRepeatButton>
1430
                    <RepeatButton 
1431
          Style="{StaticResource ScrollBarPageButton}"
1432
          Command="ScrollBar.PageLeftCommand" />
1433
                </Track.DecreaseRepeatButton>
1434
                <Track.Thumb>
1435
                    <Thumb 
1436
          Style="{StaticResource ScrollBarThumb}" 
1437
          Margin="0,10,0,10"  
1438
          Background="#C0C0C0"
1439
          BorderBrush="#404040" Height="8" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" />
1440
                </Track.Thumb>
1441
                <Track.IncreaseRepeatButton>
1442
                    <RepeatButton 
1443
          Style="{StaticResource ScrollBarPageButton}"
1444
          Command="ScrollBar.PageRightCommand" />
1445
                </Track.IncreaseRepeatButton>
1446
            </Track>
1447
            <RepeatButton 
1448
      Grid.Column="3" 
1449
      Style="{StaticResource ScrollBarLineButton}"
1450
      Width="18"
1451
      Command="ScrollBar.LineRightCommand"
1452
      Content="M 0 0 L 4 4 L 0 8 Z" Margin="0,10,0,10"/>
1453
        </Grid>
1454
    </ControlTemplate>
1455
1456
    <Style x:Key="{x:Type ScrollBar}" TargetType="{x:Type ScrollBar}">
1457
        <Setter Property="SnapsToDevicePixels" Value="True"/>
1458
        <Setter Property="OverridesDefaultStyle" Value="true"/>
1459
        <Style.Triggers>
1460
            <Trigger Property="Orientation" Value="Horizontal">
1461
                <Setter Property="Width" Value="Auto"/>
1462
                <Setter Property="Height" Value="Auto" />
1463
                <Setter Property="Template" Value="{StaticResource HorizontalScrollBar}" />
1464
            </Trigger>
1465
            <Trigger Property="Orientation" Value="Vertical">
1466
                <Setter Property="Width" Value="Auto"/>
1467
                <Setter Property="Height" Value="Auto" />
1468
                <Setter Property="Template" Value="{StaticResource VerticalScrollBar}" />
1469
            </Trigger>
1470
        </Style.Triggers>
1471
    </Style>
1472
1473
</ResourceDictionary>