1 | <ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
---|
2 | xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
---|
3 | xmlns:local="clr-namespace:Microsoft.Research.DynamicDataDisplay.Charts"
|
---|
4 | >
|
---|
5 | <Style TargetType="{x:Type Panel}" x:Key="gridStyle">
|
---|
6 | <Setter Property="Grid.ClipToBounds" Value="True"/>
|
---|
7 | </Style>
|
---|
8 |
|
---|
9 | <RotateTransform Angle="-90" x:Key="additionalLabelsTransformLeft"/>
|
---|
10 |
|
---|
11 | <ControlTemplate x:Key="axisControlTemplateBottom">
|
---|
12 | <Grid Background="{TemplateBinding Background}" Style="{StaticResource gridStyle}" Name="PART_ContentsGrid">
|
---|
13 | <Grid.RowDefinitions>
|
---|
14 | <RowDefinition Height="Auto"/>
|
---|
15 | <RowDefinition Height="Auto"/>
|
---|
16 | <RowDefinition Height="Auto"/>
|
---|
17 | </Grid.RowDefinitions>
|
---|
18 |
|
---|
19 | <Path Name="PART_TicksPath" Grid.Row="0" Stroke="Black"/>
|
---|
20 | <local:StackCanvas x:Name="PART_CommonLabelsCanvas" Grid.Row="1" Placement="Bottom"/>
|
---|
21 | <local:StackCanvas x:Name="PART_AdditionalLabelsCanvas" Grid.Row="2" Placement="Bottom"/>
|
---|
22 | </Grid>
|
---|
23 | </ControlTemplate>
|
---|
24 |
|
---|
25 | <ControlTemplate x:Key="axisControlTemplateTop">
|
---|
26 | <Grid Background="{TemplateBinding Background}" Style="{StaticResource gridStyle}" Name="PART_ContentsGrid">
|
---|
27 | <Grid.RowDefinitions>
|
---|
28 | <RowDefinition Height="Auto"/>
|
---|
29 | <RowDefinition Height="Auto"/>
|
---|
30 | <RowDefinition Height="Auto"/>
|
---|
31 | </Grid.RowDefinitions>
|
---|
32 |
|
---|
33 | <Path Name="PART_TicksPath" Grid.Row="2" Stroke="Black">
|
---|
34 | <Path.LayoutTransform>
|
---|
35 | <MatrixTransform Matrix="1,0,0,-1.1,0,0"/>
|
---|
36 | </Path.LayoutTransform>
|
---|
37 | </Path>
|
---|
38 | <local:StackCanvas x:Name="PART_CommonLabelsCanvas" Grid.Row="1" Placement="Top"/>
|
---|
39 | <local:StackCanvas x:Name="PART_AdditionalLabelsCanvas" Grid.Row="0" Placement="Top"/>
|
---|
40 | </Grid>
|
---|
41 | </ControlTemplate>
|
---|
42 |
|
---|
43 | <ControlTemplate x:Key="axisControlTemplateLeft">
|
---|
44 | <Grid Background="{TemplateBinding Background}" Style="{StaticResource gridStyle}" Name="PART_ContentsGrid">
|
---|
45 | <Grid.ColumnDefinitions>
|
---|
46 | <ColumnDefinition Width="Auto"/>
|
---|
47 | <ColumnDefinition Width="Auto"/>
|
---|
48 | <ColumnDefinition Width="Auto"/>
|
---|
49 | </Grid.ColumnDefinitions>
|
---|
50 |
|
---|
51 | <Rectangle Grid.Column="2"/>
|
---|
52 | <Path Name="PART_TicksPath" Grid.Column="2" Stroke="Black">
|
---|
53 | <Path.LayoutTransform>
|
---|
54 | <MatrixTransform Matrix="-1,0,0,1,0,0"/>
|
---|
55 | </Path.LayoutTransform>
|
---|
56 | </Path>
|
---|
57 | <local:StackCanvas x:Name="PART_CommonLabelsCanvas" Grid.Column="1" Placement="Left" Margin="1,0,1,0"/>
|
---|
58 | <local:StackCanvas x:Name="PART_AdditionalLabelsCanvas" Grid.Column="0" Placement="Left" Margin="1,0,1,0"/>
|
---|
59 | </Grid>
|
---|
60 | </ControlTemplate>
|
---|
61 |
|
---|
62 | <ControlTemplate x:Key="axisControlTemplateRight">
|
---|
63 | <Grid Background="{TemplateBinding Background}" Style="{StaticResource gridStyle}" Name="PART_ContentsGrid">
|
---|
64 | <Grid.ColumnDefinitions>
|
---|
65 | <ColumnDefinition Width="Auto"/>
|
---|
66 | <ColumnDefinition Width="Auto"/>
|
---|
67 | <ColumnDefinition Width="Auto"/>
|
---|
68 | </Grid.ColumnDefinitions>
|
---|
69 |
|
---|
70 | <Path Name="PART_TicksPath" Grid.Column="0" Stroke="Black"/>
|
---|
71 | <local:StackCanvas x:Name="PART_CommonLabelsCanvas" Grid.Column="1" Placement="Right" Margin="1,0,0,0"/>
|
---|
72 | <local:StackCanvas x:Name="PART_AdditionalLabelsCanvas" Grid.Column="2" Placement="Right"/>
|
---|
73 | </Grid>
|
---|
74 | </ControlTemplate>
|
---|
75 |
|
---|
76 | <!-- Smooth panning -->
|
---|
77 | <ControlTemplate x:Key="smoothAxisControlTemplateBottom">
|
---|
78 | <local:StackCanvas x:Name="PART_ContentsGrid" ClipToBounds="True" Background="{TemplateBinding Background}" Placement="Bottom">
|
---|
79 | <Grid>
|
---|
80 | <Grid.RowDefinitions>
|
---|
81 | <RowDefinition Height="Auto"/>
|
---|
82 | <RowDefinition Height="Auto"/>
|
---|
83 | <RowDefinition Height="Auto"/>
|
---|
84 | </Grid.RowDefinitions>
|
---|
85 |
|
---|
86 | <Path Name="PART_TicksPath" Grid.Row="0" Stroke="Black"/>
|
---|
87 | <local:StackCanvas x:Name="PART_CommonLabelsCanvas" Grid.Row="1" Placement="Bottom"/>
|
---|
88 | <local:StackCanvas x:Name="PART_AdditionalLabelsCanvas" Grid.Row="2" Placement="Bottom"/>
|
---|
89 | </Grid>
|
---|
90 | </local:StackCanvas>
|
---|
91 | </ControlTemplate>
|
---|
92 |
|
---|
93 | <ControlTemplate x:Key="smoothAxisControlTemplateTop">
|
---|
94 | <local:StackCanvas Background="{TemplateBinding Background}" ClipToBounds="True" x:Name="PART_ContentsGrid" Placement="Top">
|
---|
95 | <Grid>
|
---|
96 | <Grid.RowDefinitions>
|
---|
97 | <RowDefinition Height="Auto"/>
|
---|
98 | <RowDefinition Height="Auto"/>
|
---|
99 | <RowDefinition Height="Auto"/>
|
---|
100 | </Grid.RowDefinitions>
|
---|
101 |
|
---|
102 | <Path Name="PART_TicksPath" Grid.Row="2" Stroke="Black">
|
---|
103 | <Path.LayoutTransform>
|
---|
104 | <MatrixTransform Matrix="1,0,0,-1.1,0,0"/>
|
---|
105 | </Path.LayoutTransform>
|
---|
106 | </Path>
|
---|
107 | <local:StackCanvas x:Name="PART_CommonLabelsCanvas" Grid.Row="1" Placement="Top"/>
|
---|
108 | <local:StackCanvas x:Name="PART_AdditionalLabelsCanvas" Grid.Row="0" Placement="Top"/>
|
---|
109 | </Grid>
|
---|
110 | </local:StackCanvas>
|
---|
111 | </ControlTemplate>
|
---|
112 |
|
---|
113 | <ControlTemplate x:Key="smoothAxisControlTemplateLeft">
|
---|
114 | <local:StackCanvas Background="{TemplateBinding Background}" ClipToBounds="True" x:Name="PART_ContentsGrid" Placement="Left">
|
---|
115 | <Grid>
|
---|
116 | <Grid.ColumnDefinitions>
|
---|
117 | <ColumnDefinition Width="Auto"/>
|
---|
118 | <ColumnDefinition Width="Auto"/>
|
---|
119 | <ColumnDefinition Width="Auto"/>
|
---|
120 | </Grid.ColumnDefinitions>
|
---|
121 |
|
---|
122 | <Rectangle Grid.Column="2"/>
|
---|
123 | <Path Name="PART_TicksPath" Grid.Column="2" Stroke="Black">
|
---|
124 | <Path.LayoutTransform>
|
---|
125 | <MatrixTransform Matrix="-1,0,0,1,0,0"/>
|
---|
126 | </Path.LayoutTransform>
|
---|
127 | </Path>
|
---|
128 | <local:StackCanvas x:Name="PART_CommonLabelsCanvas" Grid.Column="1" Placement="Left" Margin="1,0,1,0"/>
|
---|
129 | <local:StackCanvas x:Name="PART_AdditionalLabelsCanvas" Grid.Column="0" Placement="Left" Margin="1,0,1,0"/>
|
---|
130 | </Grid>
|
---|
131 | </local:StackCanvas>
|
---|
132 | </ControlTemplate>
|
---|
133 |
|
---|
134 | <ControlTemplate x:Key="smoothAxisControlTemplateRight">
|
---|
135 | <local:StackCanvas Background="{TemplateBinding Background}" ClipToBounds="True" x:Name="PART_ContentsGrid" Placement="Right">
|
---|
136 | <Grid>
|
---|
137 | <Grid.ColumnDefinitions>
|
---|
138 | <ColumnDefinition Width="Auto"/>
|
---|
139 | <ColumnDefinition Width="Auto"/>
|
---|
140 | <ColumnDefinition Width="Auto"/>
|
---|
141 | </Grid.ColumnDefinitions>
|
---|
142 |
|
---|
143 | <Path Name="PART_TicksPath" Grid.Column="0" Stroke="Black"/>
|
---|
144 | <local:StackCanvas x:Name="PART_CommonLabelsCanvas" Grid.Column="1" Placement="Right" Margin="1,0,0,0"/>
|
---|
145 | <local:StackCanvas x:Name="PART_AdditionalLabelsCanvas" Grid.Column="2" Placement="Right"/>
|
---|
146 | </Grid>
|
---|
147 | </local:StackCanvas>
|
---|
148 | </ControlTemplate>
|
---|
149 |
|
---|
150 | </ResourceDictionary> |
---|