Skip to content

Commit b0d3fb7

Browse files
committed
add examples
1 parent 49a6908 commit b0d3fb7

12 files changed

Lines changed: 371 additions & 40 deletions

File tree

Modules/XamlDesigner/Properties/AssemblyInfo.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,5 +32,5 @@
3232
// You can specify all the values or you can default the Build and Revision Numbers
3333
// by using the '*' as shown below:
3434
// [assembly: AssemblyVersion("1.0.*")]
35-
[assembly: AssemblyVersion("1.1.1.0")]
36-
[assembly: AssemblyFileVersion("1.1.1.0")]
35+
[assembly: AssemblyVersion("1.1.2.0")]
36+
[assembly: AssemblyFileVersion("1.1.2.0")]

Modules/XamlEditor/Properties/AssemblyInfo.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,5 +32,5 @@
3232
// You can specify all the values or you can default the Build and Revision Numbers
3333
// by using the '*' as shown below:
3434
// [assembly: AssemblyVersion("1.0.*")]
35-
[assembly: AssemblyVersion("1.1.1.0")]
36-
[assembly: AssemblyFileVersion("1.1.1.0")]
35+
[assembly: AssemblyVersion("1.1.2.0")]
36+
[assembly: AssemblyFileVersion("1.1.2.0")]

XamlService/Properties/AssemblyInfo.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,5 +32,5 @@
3232
// You can specify all the values or you can default the Build and Revision Numbers
3333
// by using the '*' as shown below:
3434
// [assembly: AssemblyVersion("1.0.*")]
35-
[assembly: AssemblyVersion("1.1.1.0")]
36-
[assembly: AssemblyFileVersion("1.1.1.0")]
35+
[assembly: AssemblyVersion("1.1.2.0")]
36+
[assembly: AssemblyFileVersion("1.1.2.0")]

XamlTheme/Properties/AssemblyInfo.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,5 +51,5 @@
5151
// You can specify all the values or you can default the Build and Revision Numbers
5252
// by using the '*' as shown below:
5353
// [assembly: AssemblyVersion("1.0.*")]
54-
[assembly: AssemblyVersion("1.1.1.0")]
55-
[assembly: AssemblyFileVersion("1.1.1.0")]
54+
[assembly: AssemblyVersion("1.1.2.0")]
55+
[assembly: AssemblyFileVersion("1.1.2.0")]

XamlUtil/Properties/AssemblyInfo.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,5 +32,5 @@
3232
// You can specify all the values or you can default the Build and Revision Numbers
3333
// by using the '*' as shown below:
3434
// [assembly: AssemblyVersion("1.0.*")]
35-
[assembly: AssemblyVersion("1.1.1.0")]
36-
[assembly: AssemblyFileVersion("1.1.1.0")]
35+
[assembly: AssemblyVersion("1.1.2.0")]
36+
[assembly: AssemblyFileVersion("1.1.2.0")]

XamlViewer/App.xaml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,10 @@
55
<Application.Resources>
66
<ResourceDictionary>
77
<ResourceDictionary.MergedDictionaries>
8-
<ResourceDictionary Source="Resources/Examples.xaml"/>
8+
<ResourceDictionary Source="Resources/Examples/AnimationExample.xaml"/>
9+
<ResourceDictionary Source="Resources/Examples/CustomControlExample.xaml"/>
10+
<ResourceDictionary Source="Resources/Examples/StyleExample.xaml"/>
11+
<ResourceDictionary Source="Resources/Examples/WindowExample.xaml"/>
912
<ResourceDictionary Source="Resources/Constants.xaml"/>
1013
<ResourceDictionary Source="Resources/Geometries.xaml"/>
1114
<ResourceDictionary Source="Resources/DataTemplates/XamlSelection.xaml"/>

XamlViewer/Properties/AssemblyInfo.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,5 +51,5 @@
5151
// You can specify all the values or you can default the Build and Revision Numbers
5252
// by using the '*' as shown below:
5353
// [assembly: AssemblyVersion("1.0.*")]
54-
[assembly: AssemblyVersion("1.1.1.0")]
55-
[assembly: AssemblyFileVersion("1.1.1.0")]
54+
[assembly: AssemblyVersion("1.1.2.0")]
55+
[assembly: AssemblyFileVersion("1.1.2.0")]
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
2+
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
3+
xmlns:sys="clr-namespace:System;assembly=mscorlib"
4+
xmlns:models="clr-namespace:XamlViewer.Models">
5+
6+
<sys:String x:Key="{x:Static models:InternalConstStrings.AnimationExampleFileContentKey}" xml:space="preserve">
7+
<![CDATA[<Grid xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
8+
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
9+
Background="White">
10+
<Grid.Resources>
11+
12+
<BackEase EasingMode="EaseInOut" x:Key="EasingFunc"/>
13+
14+
<Storyboard x:Key="Storyboard1" RepeatBehavior="Forever">
15+
<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(Canvas.Left)" Storyboard.TargetName="RedEllipase">
16+
<EasingDoubleKeyFrame KeyTime="0:0:1" Value="0"/>
17+
<EasingDoubleKeyFrame KeyTime="0:0:2" Value="100" EasingFunction="{StaticResource EasingFunc}"/>
18+
<EasingDoubleKeyFrame KeyTime="0:0:3" Value="200" EasingFunction="{StaticResource EasingFunc}"/>
19+
<EasingDoubleKeyFrame KeyTime="0:0:4" Value="200"/>
20+
<EasingDoubleKeyFrame KeyTime="0:0:5" Value="100" EasingFunction="{StaticResource EasingFunc}"/>
21+
<EasingDoubleKeyFrame KeyTime="0:0:6" Value="0" EasingFunction="{StaticResource EasingFunc}"/>
22+
</DoubleAnimationUsingKeyFrames>
23+
<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(Canvas.Left)" Storyboard.TargetName="GreenEllipase">
24+
<EasingDoubleKeyFrame KeyTime="0:0:1" Value="200" EasingFunction="{StaticResource EasingFunc}"/>
25+
<EasingDoubleKeyFrame KeyTime="0:0:2" Value="200"/>
26+
<EasingDoubleKeyFrame KeyTime="0:0:3" Value="100" EasingFunction="{StaticResource EasingFunc}"/>
27+
<EasingDoubleKeyFrame KeyTime="0:0:4" Value="0" EasingFunction="{StaticResource EasingFunc}"/>
28+
<EasingDoubleKeyFrame KeyTime="0:0:5" Value="0"/>
29+
<EasingDoubleKeyFrame KeyTime="0:0:6" Value="100" EasingFunction="{StaticResource EasingFunc}"/>
30+
</DoubleAnimationUsingKeyFrames>
31+
<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(Canvas.Left)" Storyboard.TargetName="BlueEllipase">
32+
<EasingDoubleKeyFrame KeyTime="0:0:1" Value="100" EasingFunction="{StaticResource EasingFunc}"/>
33+
<EasingDoubleKeyFrame KeyTime="0:0:2" Value="0" EasingFunction="{StaticResource EasingFunc}"/>
34+
<EasingDoubleKeyFrame KeyTime="0:0:3" Value="0"/>
35+
<EasingDoubleKeyFrame KeyTime="0:0:4" Value="100" EasingFunction="{StaticResource EasingFunc}"/>
36+
<EasingDoubleKeyFrame KeyTime="0:0:5" Value="200" EasingFunction="{StaticResource EasingFunc}"/>
37+
<EasingDoubleKeyFrame KeyTime="0:0:6" Value="200"/>
38+
</DoubleAnimationUsingKeyFrames>
39+
</Storyboard>
40+
</Grid.Resources>
41+
<Grid.Triggers>
42+
<EventTrigger RoutedEvent="FrameworkElement.Loaded">
43+
<BeginStoryboard Storyboard="{StaticResource Storyboard1}"/>
44+
</EventTrigger>
45+
</Grid.Triggers>
46+
<Canvas Width="240" Height="40">
47+
<Ellipse x:Name="RedEllipase" Canvas.Left="0" Height="40" Width="40" Fill="Red"/>
48+
<Ellipse x:Name="GreenEllipase" Canvas.Left="100" Height="40" Width="40" Fill="Green"/>
49+
<Ellipse x:Name="BlueEllipase" Canvas.Left="200" Height="40" Width="40" Fill="Blue"/>
50+
</Canvas>
51+
</Grid>]]>
52+
</sys:String>
53+
54+
</ResourceDictionary>
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
2+
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
3+
xmlns:sys="clr-namespace:System;assembly=mscorlib"
4+
xmlns:models="clr-namespace:XamlViewer.Models">
5+
6+
<sys:String x:Key="{x:Static models:InternalConstStrings.CustomControlExampleFileContentKey}" xml:space="preserve">
7+
<![CDATA[<Grid xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
8+
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
9+
xmlns:controls="clr-namespace:XamlTheme.Controls;assembly=XamlTheme"
10+
Background="White">
11+
<controls:Hyperlink Text="Welcome to XAML Viewer" FontSize="50"
12+
HorizontalAlignment="Center" VerticalAlignment="Center"
13+
NavigateUri="https://github.com/huangjia2107/XamlViewer"
14+
ToolTip="{Binding NavigateUri,RelativeSource={RelativeSource Self}}"/>
15+
</Grid>]]>
16+
</sys:String>
17+
</ResourceDictionary>

0 commit comments

Comments
 (0)