MainWindow.xaml 7.97 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139
<Window x:Class="FLYAD7.Simulation.Battery.RayLaser.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:local="clr-namespace:FLYAD7.Simulation.Battery.RayLaser"
        Title="MainWindow" Height="313"  Closed="Window_Closed">
    <Grid>
        <Grid.Resources>
            <ResourceDictionary>
                <local:IO2BinConverter x:Key="io2bconv" />
            </ResourceDictionary>
        </Grid.Resources>
        <StackPanel Orientation="Horizontal">
            <StackPanel>
                <GroupBox Header="连接" Margin="5" >
                    <StackPanel>
                        <Grid DataContext="{Binding Gage.FlyAdRay}">
                            <TextBlock Margin="5">
                                <TextBlock.Inlines>
                                    <Run Text="射线 LocalEP:"/>
                                    <Run Text="{Binding LocalEP,Mode=OneWay}"/>
                                </TextBlock.Inlines>
                            </TextBlock>
                        </Grid>
                        <Grid DataContext="{Binding Gage.FlyAdLaser}">
                            <TextBlock Margin="5">
                                <TextBlock.Inlines>
                                    <Run Text="激光 LocalEP:"/>
                                    <Run Text="{Binding LocalEP,Mode=OneWay}"/>
                                </TextBlock.Inlines>
                            </TextBlock>
                        </Grid>
                    </StackPanel>
                </GroupBox>
                <StackPanel Orientation="Horizontal">
                    <GroupBox Header="射线 当前数据" HorizontalAlignment="Left" Margin="5" DataContext="{Binding FlyADClientUIRay}">
                        <Grid>
                            <Grid.RowDefinitions>
                                <RowDefinition Height="auto" />
                                <RowDefinition Height="auto" />
                                <RowDefinition Height="auto" />
                                <RowDefinition Height="auto" />
                                <RowDefinition Height="auto" />
                                <RowDefinition Height="auto" />
                            </Grid.RowDefinitions>
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="67" />
                                <ColumnDefinition Width="181*" />
                            </Grid.ColumnDefinitions>
                            <Grid.Resources>
                                <ResourceDictionary>
                                    <Style TargetType="TextBlock">
                                        <Setter Property="Margin" Value="2"/>
                                        <Setter Property="Height" Value="23"/>
                                        <Setter Property="HorizontalAlignment" Value="Left"/>
                                    </Style>
                                    <Style TargetType="TextBox">
                                        <Setter Property="Margin" Value="2"/>
                                        <Setter Property="Height" Value="23"/>
                                        <Setter Property="Width" Value="120"/>
                                        <Setter Property="HorizontalAlignment" Value="Left"/>
                                    </Style>
                                </ResourceDictionary>
                            </Grid.Resources>


                            <TextBox Grid.Row="0" Grid.Column="1"   Text="{Binding AD}" IsEnabled="False"/>
                            <TextBlock Grid.Row="0"  Text="AD" />
                            <TextBlock Grid.Row="1"  Text="POS" />
                            <TextBox Grid.Row="1"  Grid.Column="1"  Text="{Binding Position}" IsEnabled="False" />

                            <TextBox  Grid.Row="2" Grid.Column="1" Text="{Binding IStatus,Converter={StaticResource ResourceKey=io2bconv}}"/>
                            <TextBlock Grid.Row="2" Text="IN"  />
                            <TextBox Grid.Row="3" Grid.Column="1"  Text="{Binding OStatus,Converter={StaticResource ResourceKey=io2bconv}}"/>
                            <TextBlock Grid.Row="3" Text="OUT" />
                            <TextBlock Grid.Row="5"  Text="POS2" />
                            <TextBox Grid.Row="5"  Grid.Column="1"  Text="{Binding Position2}" IsEnabled="False" />

                        </Grid>
                    </GroupBox>
                    <GroupBox Header="射线 当前数据" HorizontalAlignment="Left" Margin="5" DataContext="{Binding FlyADClientUILaser}">
                        <Grid>
                            <Grid.RowDefinitions>
                                <RowDefinition Height="auto" />
                                <RowDefinition Height="auto" />
                                <RowDefinition Height="auto" />
                                <RowDefinition Height="auto" />
                                <RowDefinition Height="auto" />
                                <RowDefinition Height="auto" />
                            </Grid.RowDefinitions>
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="67" />
                                <ColumnDefinition Width="181*" />
                            </Grid.ColumnDefinitions>
                            <Grid.Resources>
                                <ResourceDictionary>
                                    <Style TargetType="TextBlock">
                                        <Setter Property="Margin" Value="2"/>
                                        <Setter Property="Height" Value="23"/>
                                        <Setter Property="HorizontalAlignment" Value="Left"/>
                                    </Style>
                                    <Style TargetType="TextBox">
                                        <Setter Property="Margin" Value="2"/>
                                        <Setter Property="Height" Value="23"/>
                                        <Setter Property="Width" Value="120"/>
                                        <Setter Property="HorizontalAlignment" Value="Left"/>
                                    </Style>
                                </ResourceDictionary>
                            </Grid.Resources>


                            <TextBox Grid.Row="0" Grid.Column="1"   Text="{Binding AD}" IsEnabled="False"/>
                            <TextBlock Grid.Row="0"  Text="AD" />
                            <TextBlock Grid.Row="1"  Text="POS" />
                            <TextBox Grid.Row="1"  Grid.Column="1"  Text="{Binding Position}" IsEnabled="False" />

                            <TextBox  Grid.Row="2" Grid.Column="1" Text="{Binding IStatus,Converter={StaticResource ResourceKey=io2bconv}}"/>
                            <TextBlock Grid.Row="2" Text="IN"  />
                            <TextBox Grid.Row="3" Grid.Column="1"  Text="{Binding OStatus,Converter={StaticResource ResourceKey=io2bconv}}"/>
                            <TextBlock Grid.Row="3" Text="OUT" />
                            <TextBlock Grid.Row="5"  Text="POS2" />
                            <TextBox Grid.Row="5"  Grid.Column="1"  Text="{Binding Position2}" IsEnabled="False" />

                        </Grid>
                    </GroupBox>
                </StackPanel>
            </StackPanel>
            <GroupBox Header="周期调试" Height="65" VerticalAlignment="Top" Margin="5" Width="227">
                <Grid>
                    <TextBlock Height="23" HorizontalAlignment="Left" Margin="103,8,0,0" Name="textBox5" Text="{Binding TimeSpan1ms}" IsEnabled="False" VerticalAlignment="Top" Width="105" />
                    <TextBlock Height="23" HorizontalAlignment="Left" Margin="7,11,0,0" Name="textBlock5" Text="timegrid周期" VerticalAlignment="Top" />
                </Grid>
            </GroupBox>
        </StackPanel>

        


    </Grid>
</Window>