<Window x:Class="MeterVision.Dlg.EditStandValueDlg"
        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:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
        xmlns:local="clr-namespace:MeterVision.Dlg"
        xmlns:img="clr-namespace:MeterVision.UC"
        xmlns:zdfflatui="clr-namespace:ZdfFlatUI;assembly=WPF.UI"
        mc:Ignorable="d"
        WindowStartupLocation="CenterOwner"
        ResizeMode="CanResize"
        ShowInTaskbar="False"
        Closed="Window_Closed"
        PreviewMouseWheel="Window_PreviewMouseWheel"
        Background="WhiteSmoke" FontSize="14px"
        Title="修改标准值" Height="600" Width="800">
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="*" />
            <RowDefinition Height="50" />
        </Grid.RowDefinitions>

        <Border BorderBrush="#D3D3D3" Background="White" BorderThickness="0 0 0 1" Margin="0 0 0 0" Padding="0 0 0 10">
            <Grid>
                <Grid.RowDefinitions>
                    <RowDefinition Height="*" />
                    <RowDefinition Height="50"/>
                </Grid.RowDefinitions>
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="Auto" />
                    <ColumnDefinition Width="*" />
                    <ColumnDefinition Width="Auto" />
                </Grid.ColumnDefinitions>

                <!-- 左侧切换图片 -->
                <Border x:Name="pnlLeft" Visibility="Visible" Grid.Column="0" Grid.Row="0" Grid.RowSpan="2"
                        Margin="10 0 10 0" Background="Transparent" VerticalAlignment="Center">
                    <StackPanel Visibility="Visible"  Background="#666666" HorizontalAlignment="Center">
                        <Button x:Name="btnLeft" Content="&lt;" FontSize="20px" Width="30" Click="BtnLeft_Click"
                                Height="30" Margin="5" Padding="0" Foreground="White" Background="#333333" />
                    </StackPanel>
                </Border>
                        
                <!-- 右侧切换图片 -->
                <Border x:Name="pnlRight" Visibility="Visible" Grid.Column="2" Grid.Row="0" Grid.RowSpan="2"  Background="Transparent" Margin="10 0 10 0"
                        VerticalAlignment="Center">
                    <StackPanel  Background="#666666" Margin="0" HorizontalAlignment="Center">
                        <Button x:Name="btnRight" Content="&gt;" FontSize="20px"  Click="BtnRight_Click"
                                Width="30" Height="30" Margin="5" Padding="0" Foreground="White" Background="#333333" />
                    </StackPanel>
                </Border>

                 <!--图像区域-->
                <Border Grid.Row="0" Grid.Column="1" Background="White" Margin="5">
                    <img:UCImage x:Name="ucImage" />
                </Border>

                <Border Grid.Row="1" Grid.Column="1" Background="WhiteSmoke" Margin="8 0 8 0" BorderBrush="#D3D3D3" BorderThickness="1">
                    <StackPanel Orientation="Horizontal" HorizontalAlignment="Center" VerticalAlignment="Center">
                        <StackPanel x:Name="pnlFinalValue" Orientation="Horizontal">
                            <TextBlock Text="识别值：" FontSize="14px" Foreground="#333333" VerticalAlignment="Center" />
                            <Border BorderBrush="#666666" BorderThickness="1" Width="100" Padding="2" Height="25" Background="White" VerticalAlignment="Center">
                                <TextBlock x:Name="txtFinalValue" Text="4376.346" FontSize="14px" Foreground="#000000" VerticalAlignment="Center" />
                            </Border>
                            <!--<Button x:Name="btnCopy" Content=">>" FontSize="20px" Width="50" Height="28" Click="BtnCopy_Click" 
                                    Margin="10 0 10 0" Padding="0" Foreground="White" Background="#2196F3" VerticalAlignment="Center" />-->
                            <zdfflatui:FlatButton x:Name="btnCopy" HorizontalAlignment="Center"
                                              Background="#2196F3" Foreground="White" Content=">>"
                                          Click="BtnCopy_Click" Margin="10 0 10 0"
                                              Width="40" Height="28" FontSize="20px"  />
                        </StackPanel>
                        <StackPanel  Orientation="Horizontal" Margin="20 0 0 0">
                            <TextBlock Text="标准值：" FontSize="14px" Foreground="#333333" VerticalAlignment="Center" />
                            <TextBox x:Name="txtStandValue" Text="4687.1234" FontSize="14px" 
                                     PreviewTextInput="TxtStandValue_PreviewTextInput" 
                                     TextChanged="TxtStandValue_TextChanged"
                                     Padding="2" Width="100" VerticalAlignment="Center" />
                        </StackPanel>
                    </StackPanel>
                </Border>
                
            </Grid>
        </Border>

        <StackPanel Grid.Row="1" Orientation="Horizontal" HorizontalAlignment="Center">
            <Button Name="btnOk" Content="确    定" Width="100" Height="35" VerticalAlignment="Center"
                    Margin="0 0 20 0"
                    Click="BtnOk_Click"/>
            <Button Name="btnClose" Content="取    消" Width="100" Height="35" VerticalAlignment="Center"
                    Margin="20 0 0 0"
                    Click="BtnClose_Click"/>
        </StackPanel>
        
    </Grid>
</Window>
