123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475 |
- <UserControl xmlns="https://github.com/avaloniaui"
- xmlns:vm="using:AvaloniaApplicationKuzminIV.ViewModels"
- xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
- xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
- xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
- mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
- x:Class="AvaloniaApplicationKuzminIV.PageForCreateCharacter"
- x:DataType="vm:PageCreateCharacterViewModel">
- <Grid>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="*" />
- <ColumnDefinition Width="*" />
- <ColumnDefinition Width="*" />
- </Grid.ColumnDefinitions>
- <Grid.RowDefinitions>
- <RowDefinition Height="Auto" />
- <RowDefinition Height="Auto" />
- <RowDefinition Height="Auto" />
- <RowDefinition Height="Auto" />
- <RowDefinition Height="Auto" />
- <RowDefinition Height="Auto" />
- <RowDefinition Height="Auto" />
- <RowDefinition Height="Auto" />
- <RowDefinition Height="Auto" />
- </Grid.RowDefinitions>
-
-
-
- <TextBlock Grid.Row="0" Grid.Column="1" Classes ="Header" Text="Создай своего персонажа" FontWeight="Bold" FontSize="20" HorizontalAlignment="Center" Margin="0, 10" />
- <Button Command="{Binding ExitFrom}" Content="Выход" Margin="5" BorderThickness="1" BorderBrush="Black" CornerRadius="8" HorizontalAlignment="Left" VerticalAlignment="Center" />
-
- <Button Grid.Row="1" Command="{Binding BackFromCreateCharacterr}" Content="Вернуться к персонажам" Margin="5" BorderThickness="1" BorderBrush="Black" CornerRadius="8" HorizontalAlignment="Left" VerticalAlignment="Center" />
- <TextBlock Grid.Row="1" Text="Имя" Classes ="Default" Margin="5" TextAlignment="Right" />
- <TextBox Grid.Row="1" Text="{Binding Sname}" Grid.Column="1" Name="LastNametb" Margin="5" />
- <TextBlock Grid.Row="4" Text="Дата создания" Classes ="Default" Margin="5" TextAlignment="Right" />
- <DatePicker Grid.Row="4" SelectedDate="{Binding DobMyCharacter}" Grid.Column="1" Name="DobPicker" Margin="5" />
- <TextBlock Grid.Row="5" Classes ="Default" Text="Пол" Margin="5" TextAlignment="Right" />
- <ComboBox Grid.Row="5" ItemsSource="{Binding Genders}" Grid.Column="1" Name="GenderCombobox" Margin="5" SelectedItem="{Binding GenderId}">
- <ComboBox.ItemTemplate>
- <DataTemplate>
- <TextBlock Text= "{Binding Title}"/>
- </DataTemplate>
- </ComboBox.ItemTemplate>
- </ComboBox>
-
- <StackPanel Orientation="Horizontal" Grid.Row="6" Grid.Column="1">
- <TextBlock Text="Качества" Classes="Default" Margin="5" TextAlignment="Right" />
- <ListBox Grid.Row="6" Grid.Column="1" Name="PropertyListBox" Margin="5" ItemsSource="{Binding Properties}" SelectedItem="{Binding SelectProperty}">
- <ListBox.ItemTemplate>
- <DataTemplate>
- <TextBlock Text="{Binding Propertyname}" />
- </DataTemplate>
- </ListBox.ItemTemplate>
- </ListBox>
- <ListBox Name="PropertyNewListBox" Margin="5" ItemsSource="{Binding SelectedProperties}">
- <ListBox.ItemTemplate>
- <DataTemplate>
- <StackPanel Orientation="Horizontal">
- <Button Content="X" Command="{Binding $parent[UserControl].((vm:PageCreateCharacterViewModel)DataContext).RemoveFromSelectedProperties }" CommandParameter="{Binding Id}" />
- <TextBlock Text="{Binding Propertyname}" />
- </StackPanel>
- </DataTemplate>
- </ListBox.ItemTemplate>
- </ListBox>
- </StackPanel>
-
- <!--asdasd-->
- <Button Command="{Binding OnCreate}" BorderThickness="1" BorderBrush="Black" CornerRadius="10" Grid.Row="8" Grid.ColumnSpan="3" Content="Создать" Background="LightGreen" HorizontalAlignment="Center" Margin="10" />
- </Grid>
- </UserControl>
|