|
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120 |
- <UserControl x:Class="BPASmartClient.JXJFoodBigStation.View.GlobalVarMonitorView"
- 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:pry="clr-namespace:BPASmartClient.CustomResource.UserControls;assembly=BPASmartClient.CustomResource"
- xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
- xmlns:vm="clr-namespace:BPASmartClient.JXJFoodBigStation.ViewModel"
- mc:Ignorable="d"
- d:DesignHeight="1080" d:DesignWidth="1920">
- <UserControl.DataContext>
- <vm:GlobalVarMonitorViewModel />
- </UserControl.DataContext>
-
- <Grid Margin="10">
- <Grid.RowDefinitions>
- <RowDefinition Height="80" />
- <RowDefinition />
- </Grid.RowDefinitions>
- <!--#region 表格标题栏设置-->
-
- <Grid
- Grid.Row="0"
- Margin="0,10,0,0"
- Background="#ff0C255F">
-
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="60"/>
- <ColumnDefinition Width="400"/>
- <ColumnDefinition Width="200"/>
- <ColumnDefinition />
- <ColumnDefinition Width="200"/>
- </Grid.ColumnDefinitions>
- <Grid Grid.Column="0">
- <TextBlock Text="序号" FontSize="24" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="Aqua"/>
- <Border BorderThickness="1,0,1,0" Cursor="SizeWE" />
- </Grid>
- <TextBlock Grid.Column="1" FontSize="24" Text="变量名" HorizontalAlignment="Left" VerticalAlignment="Center" Foreground="Aqua" />
- <TextBlock Grid.Column="2" FontSize="24" Text="类型" HorizontalAlignment="Left" VerticalAlignment="Center" Foreground="Aqua" />
- <Grid Grid.Column="3">
- <TextBlock Text="描述" FontSize="24" HorizontalAlignment="Left" VerticalAlignment="Center" Foreground="Aqua" />
- <Border BorderThickness="1,0,1,0" Cursor="SizeWE" />
- </Grid>
- <TextBlock Grid.Column="4" FontSize="24" Text="当前值" HorizontalAlignment="Left" VerticalAlignment="Center" Foreground="Aqua" />
-
- <Border Grid.ColumnSpan="10" BorderThickness="1,0,1,0" />
- </Grid>
- <Grid Grid.Row="1">
- <ScrollViewer HorizontalScrollBarVisibility="Hidden" VerticalScrollBarVisibility="Hidden" >
- <ItemsControl ItemsSource="{Binding PlcInfo}" Foreground="Aqua">
- <ItemsControl.ItemTemplate>
- <DataTemplate>
- <Grid Name="gr" Margin="0,3">
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="60"/>
- <ColumnDefinition Width="400"/>
- <ColumnDefinition Width="200"/>
- <ColumnDefinition />
- <ColumnDefinition Width="200"/>
- </Grid.ColumnDefinitions>
- <Grid Grid.Column="0">
- <TextBlock
- FontSize="16"
- HorizontalAlignment="Center"
- VerticalAlignment="Center"
- Text="{Binding SerialNum}" />
- <Border
- BorderThickness="1,0,1,0"
- Cursor="SizeWE" />
- </Grid>
- <Grid Grid.Column="1">
- <TextBlock
- FontSize="16"
- HorizontalAlignment="Left"
- VerticalAlignment="Center"
- Text="{Binding Variable}" />
- <Border
- BorderThickness="1,0,1,0"
- Cursor="SizeWE" />
- </Grid>
-
- <TextBlock
- Grid.Column="2"
- FontSize="16"
- HorizontalAlignment="Left"
- VerticalAlignment="Center"
- Text="{Binding Type }" />
- <Grid Grid.Column="3">
- <TextBlock
- FontSize="16"
- HorizontalAlignment="Left"
- VerticalAlignment="Center"
- Text="{Binding Describe}" />
- <Border
- BorderThickness="1,0,1,0"
- Cursor="SizeWE" />
- </Grid>
-
- <TextBlock
- HorizontalAlignment="Left"
- VerticalAlignment="Center"
- Grid.Column="4"
- Text="{Binding NowValue}" FontSize="16" />
-
-
- <Border
- Grid.ColumnSpan="10"
- BorderThickness="1,0,1,1" />
- </Grid>
- <DataTemplate.Triggers>
- <Trigger Property="IsMouseOver" Value="true">
- <Setter TargetName="gr" Property="Background" Value="#112AB2E7" />
- </Trigger>
- </DataTemplate.Triggers>
- </DataTemplate>
- </ItemsControl.ItemTemplate>
- </ItemsControl>
- </ScrollViewer>
- </Grid>
- </Grid>
- </UserControl>
|