|
| 1 | +<UserControl x:Class="PalCalc.UI.View.TraitView" |
| 2 | + xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" |
| 3 | + xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
| 4 | + xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" |
| 5 | + xmlns:d="http://schemas.microsoft.com/expression/blend/2008" |
| 6 | + xmlns:local="clr-namespace:PalCalc.UI.View" |
| 7 | + xmlns:vm="clr-namespace:PalCalc.UI.ViewModel" |
| 8 | + mc:Ignorable="d" |
| 9 | + d:DataContext="{d:DesignInstance vm:TraitViewModel, IsDesignTimeCreatable=True}"> |
| 10 | + <Grid> |
| 11 | + <Grid.ColumnDefinitions> |
| 12 | + <ColumnDefinition Width="4" /> |
| 13 | + <ColumnDefinition Width="*" /> |
| 14 | + </Grid.ColumnDefinitions> |
| 15 | + <Rectangle Grid.Column="0" VerticalAlignment="Stretch"> |
| 16 | + <Rectangle.Fill> |
| 17 | + <SolidColorBrush Color="{Binding RankColor}" /> |
| 18 | + </Rectangle.Fill> |
| 19 | + </Rectangle> |
| 20 | + <Border Grid.Column="2" BorderThickness="0,1,1,1"> |
| 21 | + <Border.BorderBrush> |
| 22 | + <SolidColorBrush Color="{Binding RankColor}" Opacity="0.5" /> |
| 23 | + </Border.BorderBrush> |
| 24 | + </Border> |
| 25 | + <Grid Grid.Column="1" Margin="5,2,2,2"> |
| 26 | + <Grid.ColumnDefinitions> |
| 27 | + <ColumnDefinition Width="Auto" /> |
| 28 | + <ColumnDefinition Width="*" /> |
| 29 | + <ColumnDefinition Width="Auto" /> |
| 30 | + </Grid.ColumnDefinitions> |
| 31 | + |
| 32 | + <Viewbox StretchDirection="DownOnly" Stretch="Uniform"> |
| 33 | + <TextBlock Grid.Column="0" Text="{Binding Name}" Height="14" FontSize="10" VerticalAlignment="Center" Foreground="White" /> |
| 34 | + </Viewbox> |
| 35 | + <Grid Grid.Column="2" Margin="10,0,0,0"> |
| 36 | + <Rectangle Width="12" Height="12"> |
| 37 | + <Rectangle.Fill> |
| 38 | + <SolidColorBrush Color="{Binding RankColor}" /> |
| 39 | + </Rectangle.Fill> |
| 40 | + <Rectangle.OpacityMask> |
| 41 | + <ImageBrush ImageSource="{Binding RankIcon}" /> |
| 42 | + </Rectangle.OpacityMask> |
| 43 | + </Rectangle> |
| 44 | + </Grid> |
| 45 | + </Grid> |
| 46 | + </Grid> |
| 47 | +</UserControl> |
0 commit comments