<UserControl x:Class="MainShell.Recipe.View.ProcessCompensationView"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
             xmlns:mw="http://www.maxwell-gp.com/"
             mc:Ignorable="d"
             d:DesignHeight="500"
             d:DesignWidth="960">
    <Grid Background="#F4F7FB">
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto"/>
            <RowDefinition Height="*"/>
        </Grid.RowDefinitions>

        <Border Margin="12,12,12,8"
                Padding="12,10"
                Background="White"
                BorderBrush="#D6E0EA"
                BorderThickness="1"
                CornerRadius="4">
            <StackPanel>
                <TextBlock Text="补偿参数"
                           Foreground="#2E5FA7"
                           FontSize="15"
                           FontWeight="Bold"/>
                <TextBlock Margin="0,4,0,0"
                           Text="当前工艺配方支持对 PHS-X1、PHS-Y1、WS-X、Stage-Y 四个轴分别设置补偿值。"
                           Foreground="#6B7B8D"
                           FontSize="12"
                           TextWrapping="Wrap"/>
            </StackPanel>
        </Border>

        <Border Grid.Row="1"
                Margin="12,0,12,12"
                Background="White"
                BorderBrush="#D6E0EA"
                BorderThickness="1"
                CornerRadius="4">
            <Grid>
                <Grid.RowDefinitions>
                    <RowDefinition Height="Auto"/>
                    <RowDefinition Height="*"/>
                </Grid.RowDefinitions>

                <Border Padding="14,10"
                        Background="#EEF3F8"
                        BorderBrush="#D6E0EA"
                        BorderThickness="0,0,0,1"
                        CornerRadius="4,4,0,0">
                    <TextBlock Text="轴补偿设置"
                               Foreground="#2E5FA7"
                               FontSize="15"
                               FontWeight="Bold"/>
                </Border>

                <Grid Grid.Row="1" Margin="16">
                    <Grid.RowDefinitions>
                        <RowDefinition Height="Auto"/>
                        <RowDefinition Height="Auto"/>
                        <RowDefinition Height="Auto"/>
                        <RowDefinition Height="Auto"/>
                    </Grid.RowDefinitions>
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition Width="180"/>
                        <ColumnDefinition Width="180"/>
                        <ColumnDefinition Width="Auto"/>
                    </Grid.ColumnDefinitions>

                    <TextBlock Grid.Row="0"
                               Grid.Column="0"
                               VerticalAlignment="Center"
                               Foreground="#2E5FA7"
                               FontSize="14"
                               FontWeight="Bold"
                               Text="PHS-X1"/>
                    <mw:NumberBox Grid.Row="0"
                                  Grid.Column="1"
                                  Style="{StaticResource ProcessLargeNumberBoxStyle}"
                                  Value="{Binding PhsX1Compensation, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
                                  DecimalPlaces="4"
                                  mw:NumericKeypadAttach.IsEnabled="True"
                                  ShowUpDownButton="True"/>
                    <TextBlock Grid.Row="0"
                               Grid.Column="2"
                               Margin="8,0,0,0"
                               VerticalAlignment="Center"
                               Foreground="#6B7B8D"
                               Text="mm"/>

                    <TextBlock Grid.Row="1"
                               Grid.Column="0"
                               Margin="0,12,0,0"
                               VerticalAlignment="Center"
                               Foreground="#2E5FA7"
                               FontSize="14"
                               FontWeight="Bold"
                               Text="PHS-Y1"/>
                    <mw:NumberBox Grid.Row="1"
                                  Grid.Column="1"
                                  Margin="8,12,0,0"
                                  Style="{StaticResource ProcessLargeNumberBoxStyle}"
                                  Value="{Binding PhsY1Compensation, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
                                  DecimalPlaces="4"
                                  mw:NumericKeypadAttach.IsEnabled="True"
                                  ShowUpDownButton="True"/>
                    <TextBlock Grid.Row="1"
                               Grid.Column="2"
                               Margin="8,12,0,0"
                               VerticalAlignment="Center"
                               Foreground="#6B7B8D"
                               Text="mm"/>

                    <TextBlock Grid.Row="2"
                               Grid.Column="0"
                               Margin="0,12,0,0"
                               VerticalAlignment="Center"
                               Foreground="#2E5FA7"
                               FontSize="14"
                               FontWeight="Bold"
                               Text="WS-X"/>
                    <mw:NumberBox Grid.Row="2"
                                  Grid.Column="1"
                                  Margin="8,12,0,0"
                                  Style="{StaticResource ProcessLargeNumberBoxStyle}"
                                  Value="{Binding WsXCompensation, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
                                  DecimalPlaces="4"
                                  mw:NumericKeypadAttach.IsEnabled="True"
                                  ShowUpDownButton="True"/>
                    <TextBlock Grid.Row="2"
                               Grid.Column="2"
                               Margin="8,12,0,0"
                               VerticalAlignment="Center"
                               Foreground="#6B7B8D"
                               Text="mm"/>

                    <TextBlock Grid.Row="3"
                               Grid.Column="0"
                               Margin="0,12,0,0"
                               VerticalAlignment="Center"
                               Foreground="#2E5FA7"
                               FontSize="14"
                               FontWeight="Bold"
                               Text="Stage-Y"/>
                    <mw:NumberBox Grid.Row="3"
                                  Grid.Column="1"
                                  Margin="8,12,0,0"
                                  Style="{StaticResource ProcessLargeNumberBoxStyle}"
                                  Value="{Binding StageYCompensation, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
                                  DecimalPlaces="4"
                                  mw:NumericKeypadAttach.IsEnabled="True"
                                  ShowUpDownButton="True"/>
                    <TextBlock Grid.Row="3"
                               Grid.Column="2"
                               Margin="8,12,0,0"
                               VerticalAlignment="Center"
                               Foreground="#6B7B8D"
                               Text="mm"/>
                </Grid>
            </Grid>
        </Border>
    </Grid>
</UserControl>
