StationInfo.xaml 5.64 KB
<UserControl x:Class="HHWCSHost.Controls.StationInfo"
             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:HHWCSHost.Controls"
             mc:Ignorable="d" 
             d:DesignHeight="400" d:DesignWidth="250" Padding="5,5">
    <UserControl.Resources>
        <Style x:Key="labStyle" TargetType="{x:Type Label}" >
            <Setter Property="Foreground" Value="Blue"/>
            <Setter Property="Margin" Value="0,0"/>
            <Setter Property="VerticalAlignment" Value="Center"/>
            <Setter Property="HorizontalAlignment" Value="Left"/>
        </Style>
        <Style x:Key="txtBlockStyle" TargetType="{x:Type TextBlock}">
            <Setter Property="Foreground" Value="Black"/>
            <Setter Property="Margin" Value="0,0"/>
            <Setter Property="VerticalAlignment" Value="Center"/>
        </Style>
    </UserControl.Resources>
    <Grid Background="#FFEEF6F5">
        <Grid.RowDefinitions>
            <RowDefinition></RowDefinition>
            <RowDefinition></RowDefinition>
            <RowDefinition></RowDefinition>
            <RowDefinition></RowDefinition>
            <RowDefinition></RowDefinition>
            <RowDefinition></RowDefinition>
            <RowDefinition></RowDefinition>
            <RowDefinition></RowDefinition>
        </Grid.RowDefinitions>
        <Grid.ColumnDefinitions>
            <ColumnDefinition></ColumnDefinition>
            <ColumnDefinition></ColumnDefinition>
            <ColumnDefinition></ColumnDefinition>
            <ColumnDefinition></ColumnDefinition>
        </Grid.ColumnDefinitions>
        
        <Label x:Name="lab_Name" Grid.Column="0" Grid.Row="0" Grid.ColumnSpan="6" HorizontalContentAlignment="Center" Style="{DynamicResource labStyle}" FontWeight="Bold" FontSize="18" HorizontalAlignment="Center">站台名</Label>
        <TextBlock Style="{DynamicResource txtBlockStyle}"  Grid.Row="1" Grid.Column="0" TextWrapping="Wrap" Text="标记位" />
        <TextBlock Style="{DynamicResource txtBlockStyle}"  Grid.Row="1" Grid.Column="2" TextWrapping="Wrap" Text="报文类型" />
        <TextBlock Style="{DynamicResource txtBlockStyle}"  Grid.Row="2" Grid.Column="0" TextWrapping="Wrap" Text="PLC编号" />
        <TextBlock Style="{DynamicResource txtBlockStyle}"  Grid.Row="2" Grid.Column="2" TextWrapping="Wrap" Text="装载状态" />
        <TextBlock Style="{DynamicResource txtBlockStyle}"  Grid.Row="3" Grid.Column="0" TextWrapping="Wrap" Text="设备编号" />
        <TextBlock Style="{DynamicResource txtBlockStyle}"  Grid.Row="3" Grid.Column="2" TextWrapping="Wrap" Text="Id" />
        <TextBlock Style="{DynamicResource txtBlockStyle}"  Grid.Row="4" Grid.Column="0" TextWrapping="Wrap" Text="TextBlock" />
        <TextBlock Style="{DynamicResource txtBlockStyle}"  Grid.Row="4" Grid.Column="2" TextWrapping="Wrap" Text="TextBlock" />
        <TextBlock Style="{DynamicResource txtBlockStyle}"  Grid.Row="5" Grid.Column="0" TextWrapping="Wrap" Text="TextBlock" />
        <TextBlock Style="{DynamicResource txtBlockStyle}"  Grid.Row="5" Grid.Column="2" TextWrapping="Wrap" Text="TextBlock" />
        <TextBlock Style="{DynamicResource txtBlockStyle}"  Grid.Row="6" Grid.Column="0" TextWrapping="Wrap" Text="TextBlock" />
        <TextBlock Style="{DynamicResource txtBlockStyle}"  Grid.Row="6" Grid.Column="2" TextWrapping="Wrap" Text="TextBlock" />
        <TextBlock Style="{DynamicResource txtBlockStyle}"  Grid.Row="7" Grid.Column="0" TextWrapping="Wrap" Text="TextBlock" />
        <TextBlock Style="{DynamicResource txtBlockStyle}"  Grid.Row="7" Grid.Column="2" TextWrapping="Wrap" Text="TextBlock" />

        <Label Style="{DynamicResource labStyle}" HorizontalAlignment="Left"  Grid.Row="1" Grid.Column="1" Content="未获取" />
        <Label Style="{DynamicResource labStyle}" HorizontalAlignment="Left"  Grid.Row="1" Grid.Column="3" Content="未获取" />
        <Label Style="{DynamicResource labStyle}" HorizontalAlignment="Left"  Grid.Row="2" Grid.Column="1" Content="未获取" />
        <Label Style="{DynamicResource labStyle}" HorizontalAlignment="Left"  Grid.Row="2" Grid.Column="3" Content="未获取" />
        <Label Style="{DynamicResource labStyle}" HorizontalAlignment="Left"  Grid.Row="3" Grid.Column="1" Content="未获取" />
        <Label Style="{DynamicResource labStyle}" HorizontalAlignment="Left"  Grid.Row="3" Grid.Column="3" Content="未获取" />
        <Label Style="{DynamicResource labStyle}" HorizontalAlignment="Left"  Grid.Row="4" Grid.Column="1" Content="未获取" />
        <Label Style="{DynamicResource labStyle}" HorizontalAlignment="Left"  Grid.Row="4" Grid.Column="3" Content="未获取" />
        <Label Style="{DynamicResource labStyle}" HorizontalAlignment="Left"  Grid.Row="5" Grid.Column="1" Content="未获取" />
        <Label Style="{DynamicResource labStyle}" HorizontalAlignment="Left"  Grid.Row="5" Grid.Column="3" Content="未获取" />
        <Label Style="{DynamicResource labStyle}" HorizontalAlignment="Left"  Grid.Row="6" Grid.Column="1" Content="未获取" />
        <Label Style="{DynamicResource labStyle}" HorizontalAlignment="Left"  Grid.Row="6" Grid.Column="3" Content="未获取" />
        <Label Style="{DynamicResource labStyle}" HorizontalAlignment="Left"  Grid.Row="7" Grid.Column="1" Content="未获取" />
        <Label Style="{DynamicResource labStyle}" HorizontalAlignment="Left"  Grid.Row="7" Grid.Column="3" Content="未获取" />
    </Grid>
</UserControl>