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
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:sys="clr-namespace:System;assembly=mscorlib"
xmlns:lvc="clr-namespace:LiveCharts.Wpf;assembly=LiveCharts.Wpf">
<!--颜色-->
<SolidColorBrush x:Key="TextBrush" Color="#4C4949" />
<SolidColorBrush x:Key="GrayBrush1" Color="#FF727272"/>
<SolidColorBrush x:Key="GrayBrush2" Color="#FF858484" />
<!--在图表中描述字符串的透明背景-->
<SolidColorBrush x:Key="TextTransparentBackgroundBrush" Color="#99FFFFFF"/>
<SolidColorBrush x:Key="SemiTransparentGreyBrush2" Color="#99FFFFFF"/>
<SolidColorBrush x:Key="SemiTransparentGreyBrush" Color="#99F0F0F0"/>
<SolidColorBrush x:Key="SemiTransparentActiveBrush" Color="#50008BE5"/>
<SolidColorBrush x:Key="WhiteBrush" Color="White"/>
<!--尺寸-->
<sys:Double x:Key="FontSize.Title">15</sys:Double>
<sys:Double x:Key="FontSize.Value">15</sys:Double>
<sys:Double x:Key="FontSize.Unit">15</sys:Double>
<Thickness x:Key="TextMargin">2.5 0</Thickness>
<sys:Double x:Key="GraphInfoRowMaxHeight">20</sys:Double>
<sys:Double x:Key="GraphInfo2RowMaxHeight">40</sys:Double>
<sys:Double x:Key="GraphInfo3RowMaxHeight">60</sys:Double>
<sys:Double x:Key="GraphInfo4RowMaxHeight">80</sys:Double>
<!--字体-->
<Style x:Key="TitleStyle" TargetType="TextBlock">
<Setter Property="Padding" Value="5,2"/>
<Setter Property="Width" Value="50"/>
<Setter Property="Foreground" Value="{StaticResource GrayBrush1}"/>
<Setter Property="FontSize" Value="{StaticResource FontSize.Title}"/>
<Setter Property="TextAlignment" Value="Right"/>
</Style>
<Style x:Key="ValueStyle" TargetType="TextBlock">
<Setter Property="Foreground" Value="{StaticResource TextBrush}"/>
<Setter Property="FontSize" Value="{StaticResource FontSize.Value}"/>
<Setter Property="Padding" Value="5,2"/>
</Style>
<Style x:Key="UnitStyle" TargetType="TextBlock">
<Setter Property="Foreground" Value="{StaticResource GrayBrush2}"/>
<Setter Property="FontSize" Value="{StaticResource FontSize.Unit}"/>
<Setter Property="VerticalAlignment" Value="Bottom"/>
</Style>
<!--Axis.Section-->
<!--图表中选择器-->
<Style x:Key="Styles.Axis.Section.Selected" TargetType="lvc:AxisSection" >
<Setter Property="StrokeThickness" Value="1"/>
<Setter Property="DataLabel" Value="False"/>
<Setter Property="DisableAnimations" Value="True"/>
<Setter Property="DataLabelForeground" Value="White"/>
<Setter Property="Opacity" Value="0.1"/>
<Setter Property="Stroke" Value="#40CA000C"/>
<Setter Property="Fill" Value="#20CA000C"/>
</Style>
<!--图表中放大用选择器-->
<Style x:Key="Styles.Axis.Section.Selected.ZoomIn" TargetType="lvc:AxisSection" >
<Setter Property="StrokeThickness" Value="1"/>
<Setter Property="DataLabel" Value="True"/>
<Setter Property="DisableAnimations" Value="True"/>
<Setter Property="DataLabelForeground" Value="White"/>
<Setter Property="Opacity" Value="0.5"/>
<Setter Property="Stroke" Value="{StaticResource MahApps.Brushes.Accent}"/>
</Style>
<!--扫描图,纵向趋势图Y轴 标签-->
<Style x:Key="AxisSectionStyle" TargetType="lvc:AxisSection" >
<Setter Property="StrokeThickness" Value="1"/>
<Setter Property="DataLabel" Value="True"/>
<Setter Property="DisableAnimations" Value="True"/>
<Setter Property="DataLabelForeground" Value="White"/>
<Setter Property="Opacity" Value="0.5"/>
<Setter Property="Panel.ZIndex" Value="1"/>
</Style>
<!--扫描图,纵向趋势图Y轴 标签 公差,目标值,上下限-->
<Style x:Key="Styles.Axis.Section.Tolerance" TargetType="lvc:AxisSection" >
<Setter Property="StrokeThickness" Value="1"/>
<Setter Property="DataLabel" Value="True"/>
<Setter Property="DisableAnimations" Value="True"/>
<Setter Property="DataLabelForeground" Value="White"/>
<Setter Property="Opacity" Value="0.5"/>
<Setter Property="Panel.ZIndex" Value="1"/>
<Setter Property="StrokeDashArray" Value="3"/>
</Style>
</ResourceDictionary>