| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286 |
- <Page x:Class="CCDCountWpf.WpfPage.MainPage"
- 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:local="clr-namespace:CCDCountWpf.WpfPage"
- xmlns:BindNameSpace="clr-namespace:CCDCountWpf"
- mc:Ignorable="d"
- Title="MainPage" Height="503" Width="876" Loaded="Page_Loaded">
- <Grid>
- <Grid Margin="0,0,0,187" SizeChanged="Grid_SizeChanged">
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="*"/>
- <ColumnDefinition Width="*"/>
- </Grid.ColumnDefinitions>
- <Border Grid.Column="0" BorderBrush="Black" BorderThickness="1" Margin="2,2,2,2">
- <Image x:Name="ShowBox" Source="{Binding BitmapImage}" Margin="0,0,0,0"/>
- </Border>
- <Border Grid.Column="1" BorderBrush="Black" BorderThickness="1" Margin="2,2,2,2">
- <StackPanel Orientation="Vertical">
- <Image x:Name="MiniShowImageBox1" Source="{Binding ThumbnailImage1}" Margin="3,5,3,5" MouseDown="MiniShowImageBox1_MouseDown" Cursor="Hand" />
- <Image x:Name="MiniShowImageBox2" Source="{Binding ThumbnailImage2}" Margin="3,5,3,5" MouseDown="MiniShowImageBox2_MouseDown" Cursor="Hand" />
- <Image x:Name="MiniShowImageBox3" Source="{Binding ThumbnailImage3}" Margin="3,5,3,5" MouseDown="MiniShowImageBox3_MouseDown" Cursor="Hand"/>
- <Image x:Name="MiniShowImageBox4" Source="{Binding ThumbnailImage4}" Margin="3,5,3,5" MouseDown="MiniShowImageBox4_MouseDown" Cursor="Hand"/>
- </StackPanel>
- </Border>
- </Grid>
-
- <Grid Margin="0,0,0,10" Height="170" VerticalAlignment="Bottom">
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="*"/>
- <ColumnDefinition Width="*"/>
- <ColumnDefinition Width="*"/>
- </Grid.ColumnDefinitions>
- <Border Grid.Column="0"
- Background="#FF0087FF"
- CornerRadius="8"
- BorderBrush="Gray"
- BorderThickness="1"
- Margin="15,10,15,0" Height="155" VerticalAlignment="Top" Cursor="">
- <Grid>
- <StackPanel Orientation="Vertical" Margin="0,0,80,0">
- <StackPanel Orientation="Horizontal">
- <Label Content="总粒数:" HorizontalAlignment="Left" Margin="10,10,0,0" VerticalAlignment="Top" FontWeight="Bold" FontSize="20" Foreground="White"/>
- <Label x:Name="AllActiveNumLab" Content="{Binding AllActiveNum}" HorizontalAlignment="Left" Margin="20,10,0,0" Width="80" FontWeight="Bold" FontSize="20" Background="{x:Null}" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" Foreground="White"/>
- </StackPanel>
- <StackPanel Orientation="Horizontal">
- <Label Content="合格数:" HorizontalAlignment="Left" Margin="10,10,0,0" VerticalAlignment="Top" FontWeight="Bold" FontSize="20" Foreground="White"/>
- <Label x:Name="AllOkNumLab" Content="{Binding AllOkNum}" HorizontalAlignment="Left" Margin="20,10,0,0" Width="80" FontWeight="Bold" FontSize="20" Background="{x:Null}" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" Foreground="White"/>
- </StackPanel>
- <StackPanel Orientation="Horizontal">
- <Label Content="不合格数:" HorizontalAlignment="Left" Margin="10,10,0,0" VerticalAlignment="Top" FontWeight="Bold" FontSize="20" Foreground="White"/>
- <Label x:Name="AllNgNumLab" Content="{Binding AllNgNum}" HorizontalAlignment="Left" Margin="0,10,0,0" Width="80" FontWeight="Bold" FontSize="20" Background="{x:Null}" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" Foreground="White"/>
- </StackPanel>
- </StackPanel>
- <Label x:Name="CamRunStaticLab" Content="{Binding CamRunStatic}" HorizontalAlignment="Right" Margin="10,5,10,0" VerticalAlignment="Top" Background="{x:Null}" FontSize="25" Foreground="{Binding CameraStaticColor}" FontWeight="Bold" />
- <Button x:Name="DataClear" Content="清零" BorderThickness="1" HorizontalAlignment="Right" Margin="10,0,10,12" Width="80" Height="40" Background="#FF0123FF" FontWeight="Bold" FontSize="20" Foreground="White" Click="DataClear_Click" Cursor="Hand" VerticalAlignment="Bottom">
- <Button.Template>
- <ControlTemplate TargetType="Button">
- <Border CornerRadius="5"
- Background="{TemplateBinding Background}"
- BorderBrush="{TemplateBinding BorderBrush}"
- BorderThickness="{TemplateBinding BorderThickness}">
- <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
- </Border>
- </ControlTemplate>
- </Button.Template>
- </Button>
- </Grid>
- <!-- 卡片内容 -->
- </Border>
- <Border Grid.Column="1"
- Background="#FF0087FF"
- CornerRadius="8"
- BorderBrush="Gray"
- BorderThickness="1"
- Margin="15,10,15,0" Height="60" VerticalAlignment="Top">
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Center">
- <Label Content="计数速度:" HorizontalAlignment="Left" Margin="10,10,0,0" VerticalAlignment="Top" FontWeight="Bold" FontSize="20" Foreground="White"/>
- <Label x:Name="ShuLiSpeedTbx" Content="{Binding ShuLiSpeed}" HorizontalAlignment="Left" Margin="0,0,0,0" Width="60" FontWeight="Bold" FontSize="20" Background="{x:Null}" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" Foreground="White"/>
- <Label Content="粒/秒" FontWeight="Bold" FontSize="20" Margin="0,10,0,0" Foreground="White" />
- </StackPanel>
- </Border>
- <Border Grid.Column="1"
- Background="#FF0087FF"
- CornerRadius="8"
- BorderBrush="Gray"
- BorderThickness="1"
- Margin="15,80,15,0" Height="85" VerticalAlignment="Top">
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Center" VerticalAlignment="Center">
- <Button x:Name="StartIdentifyBtn" Content="开始" BorderThickness="1" HorizontalAlignment="Right" Margin="0,0,20,0" VerticalAlignment="Top" Width="100" Height="60" Background="#FF0123FF" FontWeight="Bold" FontSize="20" Foreground="White" Cursor="Hand" Click="StartIdentifyBtn_Click">
- <Button.Template>
- <ControlTemplate TargetType="Button">
- <Border CornerRadius="5" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}">
- <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
- </Border>
- </ControlTemplate>
- </Button.Template>
- </Button>
- <Button x:Name="StopIdentifyBtn" Content="暂停" BorderThickness="1" HorizontalAlignment="Right" Margin="0,0,0,0" VerticalAlignment="Top" Width="100" Height="60" Background="#FF0123FF" FontWeight="Bold" FontSize="20" Foreground="White" Cursor="Hand" Click="StopIdentifyBtn_Click">
- <Button.Template>
- <ControlTemplate TargetType="Button">
- <Border CornerRadius="5" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}">
- <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
- </Border>
- </ControlTemplate>
- </Button.Template>
- </Button>
- </StackPanel>
- </Border>
- <Border Grid.Column="2"
- Background="#FF0087FF"
- CornerRadius="8"
- BorderBrush="Gray"
- BorderThickness="1"
- Margin="15,10,15,0" Height="155" VerticalAlignment="Top" Cursor="">
- <Grid>
- <StackPanel Orientation="Vertical">
- <StackPanel Orientation="Horizontal" Margin="0,10,0,0" HorizontalAlignment="Center">
- <TextBlock Text="A速度:" FontSize="20" Margin="0,0,0,0" VerticalAlignment="Center" Foreground="White"/>
- <Button x:Name="BottingMaterialCylinderVibrationTableHighSpeedValueUpUPBtn" Content="++" Width="30" Height="30" Click="BottingMaterialCylinderVibrationTableHighSpeedValueUpUpBtn_Click" Background="#FF0123FF" Foreground="White">
- <Button.Template>
- <ControlTemplate TargetType="Button">
- <Border CornerRadius="5"
- Background="{TemplateBinding Background}"
- BorderBrush="{TemplateBinding BorderBrush}"
- BorderThickness="{TemplateBinding BorderThickness}">
- <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
- </Border>
- </ControlTemplate>
- </Button.Template>
- </Button>
- <Button x:Name="BottingMaterialCylinderVibrationTableHighSpeedValueUpBtn" Content="+" Width="30" Height="30" Click="BottingMaterialCylinderVibrationTableHighSpeedValueUpBtn_Click" Background="#FF0123FF" Foreground="White">
- <Button.Template>
- <ControlTemplate TargetType="Button">
- <Border CornerRadius="5"
- Background="{TemplateBinding Background}"
- BorderBrush="{TemplateBinding BorderBrush}"
- BorderThickness="{TemplateBinding BorderThickness}">
- <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
- </Border>
- </ControlTemplate>
- </Button.Template>
- </Button>
- <TextBox Text="{Binding Source={x:Static BindNameSpace:PlcSettingMessageBus.PlcMessageShowBindage},Path = BottingMaterialCylinderVibrationTableHighSpeedValue,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}" FontSize="16" Width="79" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" Foreground="White" Background="{x:Null}"/>
- <Button x:Name="BottingMaterialCylinderVibrationTableHighSpeedValueDownBtn" Content="-" Width="30" Click="BottingMaterialCylinderVibrationTableHighSpeedValueDownBtn_Click" Background="#FF0123FF" Foreground="White">
- <Button.Template>
- <ControlTemplate TargetType="Button">
- <Border CornerRadius="5"
- Background="{TemplateBinding Background}"
- BorderBrush="{TemplateBinding BorderBrush}"
- BorderThickness="{TemplateBinding BorderThickness}">
- <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
- </Border>
- </ControlTemplate>
- </Button.Template>
- </Button>
- <Button x:Name="BottingMaterialCylinderVibrationTableHighSpeedValueDownDownBtn" Content="--" Width="30" Click="BottingMaterialCylinderVibrationTableHighSpeedValueDownDownBtn_Click" Background="#FF0123FF" Foreground="White">
- <Button.Template>
- <ControlTemplate TargetType="Button">
- <Border CornerRadius="5"
- Background="{TemplateBinding Background}"
- BorderBrush="{TemplateBinding BorderBrush}"
- BorderThickness="{TemplateBinding BorderThickness}">
- <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
- </Border>
- </ControlTemplate>
- </Button.Template>
- </Button>
- </StackPanel>
- <StackPanel Orientation="Horizontal" Margin="0,20,0,0" HorizontalAlignment="Center">
- <TextBlock Text="B速度:" FontSize="20" Margin="0,0,0,0" VerticalAlignment="Center" Foreground="White"/>
- <Button x:Name="BottingFilterVibrationTableHighSpeedValueUpUpBtn" Content="++" Width="30" Height="30" Click="BottingFilterVibrationTableHighSpeedValueUpUpBtn_Click" Background="#FF0123FF" Foreground="White">
- <Button.Template>
- <ControlTemplate TargetType="Button">
- <Border CornerRadius="5"
- Background="{TemplateBinding Background}"
- BorderBrush="{TemplateBinding BorderBrush}"
- BorderThickness="{TemplateBinding BorderThickness}">
- <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
- </Border>
- </ControlTemplate>
- </Button.Template>
- </Button>
- <Button x:Name="BottingFilterVibrationTableHighSpeedValueUpBtn" Content="+" Width="30" Height="30" Click="BottingFilterVibrationTableHighSpeedValueUpBtn_Click" Background="#FF0123FF" Foreground="White">
- <Button.Template>
- <ControlTemplate TargetType="Button">
- <Border CornerRadius="5"
- Background="{TemplateBinding Background}"
- BorderBrush="{TemplateBinding BorderBrush}"
- BorderThickness="{TemplateBinding BorderThickness}">
- <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
- </Border>
- </ControlTemplate>
- </Button.Template>
- </Button>
- <TextBox Text="{Binding Source={x:Static BindNameSpace:PlcSettingMessageBus.PlcMessageShowBindage},Path = BottingFilterVibrationTableHighSpeedValue,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}" FontSize="16" Width="80" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" Foreground="White" Background="{x:Null}"/>
- <Button x:Name="BottingFilterVibrationTableHighSpeedValueDownBtn" Content="-" Width="30" Click="BottingFilterVibrationTableHighSpeedValueDownBtn_Click" Background="#FF0123FF" Foreground="White">
- <Button.Template>
- <ControlTemplate TargetType="Button">
- <Border CornerRadius="5"
- Background="{TemplateBinding Background}"
- BorderBrush="{TemplateBinding BorderBrush}"
- BorderThickness="{TemplateBinding BorderThickness}">
- <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
- </Border>
- </ControlTemplate>
- </Button.Template>
- </Button>
- <Button x:Name="BottingFilterVibrationTableHighSpeedValueDownDownBtn" Content="--" Width="30" Click="BottingFilterVibrationTableHighSpeedValueDownDownBtn_Click" Background="#FF0123FF" Foreground="White">
- <Button.Template>
- <ControlTemplate TargetType="Button">
- <Border CornerRadius="5"
- Background="{TemplateBinding Background}"
- BorderBrush="{TemplateBinding BorderBrush}"
- BorderThickness="{TemplateBinding BorderThickness}">
- <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
- </Border>
- </ControlTemplate>
- </Button.Template>
- </Button>
- </StackPanel>
- <StackPanel Orientation="Horizontal" Margin="0,20,0,0" HorizontalAlignment="Center">
- <TextBlock Text="C速度:" FontSize="20" Margin="0,0,0,0" VerticalAlignment="Center" Foreground="White"/>
- <Button x:Name="BottingCountVibrationTableHighSpeedValueUpUpBtn" Content="++" Width="30" Height="30" Click="BottingCountVibrationTableHighSpeedValueUpUpBtn_Click" Background="#FF0123FF" Foreground="White">
- <Button.Template>
- <ControlTemplate TargetType="Button">
- <Border CornerRadius="5"
- Background="{TemplateBinding Background}"
- BorderBrush="{TemplateBinding BorderBrush}"
- BorderThickness="{TemplateBinding BorderThickness}">
- <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
- </Border>
- </ControlTemplate>
- </Button.Template>
- </Button>
- <Button x:Name="BottingCountVibrationTableHighSpeedValueUpBtn" Content="+" Width="30" Height="30" Click="BottingCountVibrationTableHighSpeedValueUpBtn_Click" Background="#FF0123FF" Foreground="White">
- <Button.Template>
- <ControlTemplate TargetType="Button">
- <Border CornerRadius="5"
- Background="{TemplateBinding Background}"
- BorderBrush="{TemplateBinding BorderBrush}"
- BorderThickness="{TemplateBinding BorderThickness}">
- <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
- </Border>
- </ControlTemplate>
- </Button.Template>
- </Button>
- <TextBox Text="{Binding Source={x:Static BindNameSpace:PlcSettingMessageBus.PlcMessageShowBindage},Path = BottingCountVibrationTableHighSpeedValue,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}" FontSize="16" Width="80" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" Background="{x:Null}" Foreground="White"/>
- <Button x:Name="BottingCountVibrationTableHighSpeedValueDownBtn" Content="-" Width="30" Click="BottingCountVibrationTableHighSpeedValueDownBtn_Click" Background="#FF0123FF" Foreground="White">
- <Button.Template>
- <ControlTemplate TargetType="Button">
- <Border CornerRadius="5"
- Background="{TemplateBinding Background}"
- BorderBrush="{TemplateBinding BorderBrush}"
- BorderThickness="{TemplateBinding BorderThickness}">
- <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
- </Border>
- </ControlTemplate>
- </Button.Template>
- </Button>
- <Button x:Name="BottingCountVibrationTableHighSpeedValueDownDownBtn" Content="--" Width="30" Click="BottingCountVibrationTableHighSpeedValueDownDownBtn_Click" Background="#FF0123FF" Foreground="White">
- <Button.Template>
- <ControlTemplate TargetType="Button">
- <Border CornerRadius="5"
- Background="{TemplateBinding Background}"
- BorderBrush="{TemplateBinding BorderBrush}"
- BorderThickness="{TemplateBinding BorderThickness}">
- <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
- </Border>
- </ControlTemplate>
- </Button.Template>
- </Button>
- </StackPanel>
- </StackPanel>
- </Grid>
- <!-- 卡片内容 -->
- </Border>
- </Grid>
-
- </Grid>
- </Page>
|