Katteker/Example/MainWindow.xaml
2018-08-02 22:10:11 +02:00

61 lines
2.3 KiB
XML

<Window
x:Class="Example.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity"
xmlns:local="clr-namespace:Example"
xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:prism="http://prismlibrary.com/"
Title="MainWindow"
Width="800"
Height="450"
d:DataContext="{d:DesignInstance local:MainWindowViewModel}"
prism:ViewModelLocator.AutoWireViewModel="True"
Background="{DynamicResource MaterialDesignPaper}"
FontFamily="{DynamicResource MaterialDesignFont}"
TextElement.FontSize="13"
TextElement.FontWeight="Regular"
TextElement.Foreground="{DynamicResource MaterialDesignBody}"
TextOptions.TextFormattingMode="Ideal"
TextOptions.TextRenderingMode="Auto"
mc:Ignorable="d">
<i:Interaction.Triggers>
<i:EventTrigger EventName="ContentRendered">
<i:InvokeCommandAction Command="{Binding UpdateCommand}" CommandParameter="True" />
</i:EventTrigger>
</i:Interaction.Triggers>
<DockPanel>
<materialDesign:Snackbar
Margin="10,0"
HorizontalAlignment="Stretch"
DockPanel.Dock="Bottom"
IsActive="True"
Message="Hello World" />
<StackPanel>
<Button
Height="45"
Margin="10"
Command="{Binding UpdateCommand}"
CommandParameter="False"
Content="Update"
FontSize="24" />
<TextBlock
Margin="20"
HorizontalAlignment="Center"
FontSize="60"
RenderTransformOrigin="0.5,0.5"
Text=":-)">
<TextBlock.RenderTransform>
<TransformGroup>
<ScaleTransform />
<SkewTransform />
<RotateTransform Angle="90" />
<TranslateTransform />
</TransformGroup>
</TextBlock.RenderTransform>
</TextBlock>
</StackPanel>
</DockPanel>
</Window>