12345678910111213141516171819202122232425262728293031323334 |
- <UserControl xmlns="https://github.com/avaloniaui"
- xmlns:vm="using:avaloniaPr.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:DataType="vm:MainWindowViewModel"
- x:Class="avaloniaPr.Calculator">
- <Grid Background="Gray">
- <Grid.RowDefinitions>
- <RowDefinition Height="0.1*"/>
- <RowDefinition Height="0.3*"/>
- <RowDefinition/>
- <RowDefinition Height="0.1*"/>
- </Grid.RowDefinitions>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="0.3*"/>
- <ColumnDefinition/>
- <ColumnDefinition Width="0.3*"/>
- </Grid.ColumnDefinitions>
- <TextBlock Text="Calculator" Classes="centerTB" Grid.Column="1" Grid.Row="1"/>
- <StackPanel Grid.Row="2" Grid.Column="1">
- <TextBlock Text="{Binding CalculatorVM.TextCalculator}" Classes="TBLMain"/>
- <ComboBox SelectedValue="{Binding CalculatorVM.SV}" ItemsSource="{Binding CalculatorVM.ListItem}" Width="250"/>
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Center" Margin="0,30" Background="#87929c">
- <TextBox Text="{Binding CalculatorVM.OneNum}" Classes="TBCalculator"/>
- <TextBlock Text="{Binding CalculatorVM.SV}" Classes="TBLCalculator"/>
- <TextBox Text="{Binding CalculatorVM.TwoNum}" Classes="TBCalculator"/>
- </StackPanel>
- <Button Content="{Binding CalculatorVM.TextButton}" Command="{Binding CalculatorVM.CommandCalculator}" Classes="ButtonStyle"/>
- <TextBlock Text="{Binding CalculatorVM.Result, StringFormat = Результат {0}}" Classes="TBLMain"/>
- </StackPanel>
- </Grid>
- </UserControl>
|