|
|
@@ -1,24 +1,24 @@
|
|
|
<UserControl x:Class="YSAI.Tool.Wpf.views.Serial"
|
|
|
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:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|
|
+ xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
|
|
xmlns:c="clr-namespace:YSAI.Tool.Wpf.controllers"
|
|
|
xmlns:cl="clr-namespace:YSAI.Core.Wpf.controls.ledgauge;assembly=YSAI.Core.Wpf"
|
|
|
xmlns:lang="http://wpflocalizeextension.codeplex.com"
|
|
|
lang:LocalizeDictionary.DesignCulture="zh"
|
|
|
lang:ResxLocalizationProvider.DefaultAssembly="YSAI.Langs"
|
|
|
lang:ResxLocalizationProvider.DefaultDictionary="Lang"
|
|
|
-
|
|
|
+
|
|
|
xmlns:btn="clr-namespace:YSAI.Core.Wpf.controls.button;assembly=YSAI.Core.Wpf"
|
|
|
xmlns:pt="http://propertytools.org/wpf"
|
|
|
xmlns:helpers="clr-namespace:YSAI.Core.Wpf.style;assembly=YSAI.Core.Wpf"
|
|
|
xmlns:cs="clr-namespace:YSAI.Core.Wpf.converters;assembly=YSAI.Core.Wpf"
|
|
|
xmlns:i="http://schemas.microsoft.com/xaml/behaviors"
|
|
|
xmlns:mvvm="clr-namespace:YSAI.Core.Wpf.mvvm;assembly=YSAI.Core.Wpf"
|
|
|
- Background="{DynamicResource ContentBackgroundPicture}"
|
|
|
- >
|
|
|
-
|
|
|
+ Background="{DynamicResource ContentBackgroundPicture}"
|
|
|
+ >
|
|
|
+
|
|
|
<!--加载控制器-->
|
|
|
<UserControl.DataContext>
|
|
|
<c:SerialController />
|
|
|
@@ -79,30 +79,30 @@
|
|
|
|
|
|
<!--导入导出-->
|
|
|
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right" Margin="0,0,0,-30" Panel.ZIndex="2">
|
|
|
- <btn:ButtonControl
|
|
|
- Width="80"
|
|
|
- Command="{Binding IncBasics}"
|
|
|
- HorizontalAlignment="Center"
|
|
|
- VerticalAlignment="Center"
|
|
|
- IsMouseOverBorderBrushColor="{DynamicResource Control.Border.One.Color}"
|
|
|
- BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
- IsPressedBorderBrushColor="{DynamicResource Control.Border.Two.Color}"
|
|
|
- Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
- Icon="{DynamicResource Inc}"
|
|
|
- Content="导入"
|
|
|
- BorderThickness="1,0,0,0" />
|
|
|
- <btn:ButtonControl
|
|
|
- Width="80"
|
|
|
- Command="{Binding ExpBasics}"
|
|
|
- HorizontalAlignment="Center"
|
|
|
- VerticalAlignment="Center"
|
|
|
- IsMouseOverBorderBrushColor="{DynamicResource Control.Border.One.Color}"
|
|
|
- BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
- IsPressedBorderBrushColor="{DynamicResource Control.Border.Two.Color}"
|
|
|
- Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
- Icon="{DynamicResource Exp}"
|
|
|
- Content="导出"
|
|
|
- BorderThickness="1,0,0,0" />
|
|
|
+ <btn:ButtonControl
|
|
|
+ Width="80"
|
|
|
+ Command="{Binding IncBasics}"
|
|
|
+ HorizontalAlignment="Center"
|
|
|
+ VerticalAlignment="Center"
|
|
|
+ IsMouseOverBorderBrushColor="{DynamicResource Control.Border.One.Color}"
|
|
|
+ BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
+ IsPressedBorderBrushColor="{DynamicResource Control.Border.Two.Color}"
|
|
|
+ Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
+ Icon="{DynamicResource Inc}"
|
|
|
+ Content="导入"
|
|
|
+ BorderThickness="1,0,0,0" />
|
|
|
+ <btn:ButtonControl
|
|
|
+ Width="80"
|
|
|
+ Command="{Binding ExpBasics}"
|
|
|
+ HorizontalAlignment="Center"
|
|
|
+ VerticalAlignment="Center"
|
|
|
+ IsMouseOverBorderBrushColor="{DynamicResource Control.Border.One.Color}"
|
|
|
+ BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
+ IsPressedBorderBrushColor="{DynamicResource Control.Border.Two.Color}"
|
|
|
+ Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
+ Icon="{DynamicResource Exp}"
|
|
|
+ Content="导出"
|
|
|
+ BorderThickness="1,0,0,0" />
|
|
|
</StackPanel>
|
|
|
<!--属性表格-->
|
|
|
<Grid Grid.Row="1" Panel.ZIndex="1">
|
|
|
@@ -159,12 +159,12 @@
|
|
|
</ResourceDictionary>
|
|
|
</Grid.Resources>
|
|
|
<pt:PropertyGrid Margin="1,-4,1,0"
|
|
|
-SelectedObject="{Binding BasicsData}"
|
|
|
-TabVisibility="VisibleIfMoreThanOne"
|
|
|
-TextBlock.Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
-Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
-BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
-CategoryHeaderTemplate="{StaticResource HeaderTemplate}"/>
|
|
|
+ SelectedObject="{Binding BasicsData}"
|
|
|
+ TabVisibility="VisibleIfMoreThanOne"
|
|
|
+ TextBlock.Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
+ Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
+ BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
+ CategoryHeaderTemplate="{StaticResource HeaderTemplate}" EnumAsRadioButtonsLimit="0"/>
|
|
|
</Grid>
|
|
|
</Grid>
|
|
|
|
|
|
@@ -240,20 +240,20 @@ CategoryHeaderTemplate="{StaticResource HeaderTemplate}"/>
|
|
|
<Grid Grid.Row="0" Grid.Column="1" Margin="0,-40,0,0">
|
|
|
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right" >
|
|
|
<btn:ButtonControl Grid.Column="5" Width="80" Command="{Binding Start}" HorizontalAlignment="Right" VerticalAlignment="Center" BorderThickness="1,0,0,0"
|
|
|
- IsMouseOverBorderBrushColor="{DynamicResource Control.Border.One.Color}"
|
|
|
- BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
- IsPressedBorderBrushColor="{DynamicResource Control.Border.Two.Color}"
|
|
|
- Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
- Icon="{DynamicResource Open}"
|
|
|
- Content="打开"/>
|
|
|
+ IsMouseOverBorderBrushColor="{DynamicResource Control.Border.One.Color}"
|
|
|
+ BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
+ IsPressedBorderBrushColor="{DynamicResource Control.Border.Two.Color}"
|
|
|
+ Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
+ Icon="{DynamicResource Open}"
|
|
|
+ Content="打开"/>
|
|
|
|
|
|
<btn:ButtonControl Grid.Column="6" Width="80" Command="{Binding Stop}" HorizontalAlignment="Right" VerticalAlignment="Center" BorderThickness="1,0,0,0"
|
|
|
- IsMouseOverBorderBrushColor="{DynamicResource Control.Border.One.Color}"
|
|
|
- BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
- IsPressedBorderBrushColor="{DynamicResource Control.Border.Two.Color}"
|
|
|
- Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
- Icon="{DynamicResource CloseBase}"
|
|
|
- Content="关闭"/>
|
|
|
+ IsMouseOverBorderBrushColor="{DynamicResource Control.Border.One.Color}"
|
|
|
+ BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
+ IsPressedBorderBrushColor="{DynamicResource Control.Border.Two.Color}"
|
|
|
+ Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
+ Icon="{DynamicResource CloseBase}"
|
|
|
+ Content="关闭"/>
|
|
|
</StackPanel>
|
|
|
</Grid>
|
|
|
<!--发送区域-->
|
|
|
@@ -266,12 +266,12 @@ CategoryHeaderTemplate="{StaticResource HeaderTemplate}"/>
|
|
|
<RadioButton ToolTip="发送方式" Margin="0,0,15,0" Visibility="{Binding AsciiVisibility}" IsChecked="{Binding DataFormat,Mode=TwoWay,Converter={StaticResource CheckConverter},ConverterParameter=0}" Style="{StaticResource RadioButtonStyle}" Content="ASCII" VerticalAlignment="Center" HorizontalAlignment="Right" />
|
|
|
<RadioButton ToolTip="发送方式" Margin="0,0,15,0" Visibility="{Binding HexVisibility}" IsChecked="{Binding DataFormat,Mode=TwoWay,Converter={StaticResource CheckConverter},ConverterParameter=1}" Style="{StaticResource RadioButtonStyle}" Content="Hex" VerticalAlignment="Center" HorizontalAlignment="Right" />
|
|
|
<btn:ButtonControl Grid.Column="3" Width="80" Command="{Binding Send}" HorizontalAlignment="Right" VerticalAlignment="Center" BorderThickness="1,0,0,0"
|
|
|
- IsMouseOverBorderBrushColor="{DynamicResource Control.Border.One.Color}"
|
|
|
- BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
- IsPressedBorderBrushColor="{DynamicResource Control.Border.Two.Color}"
|
|
|
- Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
- Icon="{DynamicResource Send}"
|
|
|
- Content="发送"/>
|
|
|
+ IsMouseOverBorderBrushColor="{DynamicResource Control.Border.One.Color}"
|
|
|
+ BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
+ IsPressedBorderBrushColor="{DynamicResource Control.Border.Two.Color}"
|
|
|
+ Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
+ Icon="{DynamicResource Send}"
|
|
|
+ Content="发送"/>
|
|
|
</StackPanel>
|
|
|
<GroupBox Style="{StaticResource GroupBoxTab}" Grid.Row="1" Grid.ColumnSpan="8" Width="auto" Margin="0,0,0,0">
|
|
|
<GroupBox.Header>
|
|
|
@@ -323,12 +323,12 @@ CategoryHeaderTemplate="{StaticResource HeaderTemplate}"/>
|
|
|
<RadioButton ToolTip="显示方式" Margin="0,0,15,0" Visibility="{Binding AsciiVisibility}" IsChecked="{Binding InfoFormat,Mode=TwoWay,Converter={StaticResource CheckConverter},ConverterParameter=0}" Style="{StaticResource RadioButtonStyle}" Content="ASCII" VerticalAlignment="Center" HorizontalAlignment="Right" />
|
|
|
<RadioButton ToolTip="显示方式" Margin="0,0,15,0" Visibility="{Binding HexVisibility}" IsChecked="{Binding InfoFormat,Mode=TwoWay,Converter={StaticResource CheckConverter},ConverterParameter=1}" Style="{StaticResource RadioButtonStyle}" Content="Hex" VerticalAlignment="Center" HorizontalAlignment="Right" />
|
|
|
<btn:ButtonControl Width="80" Command="{Binding Clear}" HorizontalAlignment="Right" VerticalAlignment="Center" BorderThickness="1,0,0,0"
|
|
|
-IsMouseOverBorderBrushColor="{DynamicResource Control.Border.One.Color}"
|
|
|
-BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
-IsPressedBorderBrushColor="{DynamicResource Control.Border.Two.Color}"
|
|
|
-Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
-Icon="{DynamicResource Clear}"
|
|
|
-Content="清空"/>
|
|
|
+ IsMouseOverBorderBrushColor="{DynamicResource Control.Border.One.Color}"
|
|
|
+ BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
+ IsPressedBorderBrushColor="{DynamicResource Control.Border.Two.Color}"
|
|
|
+ Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
+ Icon="{DynamicResource Clear}"
|
|
|
+ Content="清空"/>
|
|
|
</StackPanel>
|
|
|
<TextBox Grid.Row="1" Padding="5" Grid.ColumnSpan="2" Style="{DynamicResource TextBoxStyle2}" FontSize="13" VerticalContentAlignment="Top" HorizontalContentAlignment="Left" TextWrapping="Wrap" AcceptsReturn="True" VerticalScrollBarVisibility="Visible" Text="{Binding Info}" >
|
|
|
<i:Interaction.Triggers>
|
|
|
@@ -348,233 +348,233 @@ Content="清空"/>
|
|
|
|
|
|
<!--#region 暂不使用 -->
|
|
|
<!--<UserControl.Resources>
|
|
|
- <ResourceDictionary>
|
|
|
- <cs:CheckConverter x:Key="CheckConverter" />
|
|
|
- <ResourceDictionary.MergedDictionaries>
|
|
|
- <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_ComboBox.xaml" />
|
|
|
- <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_Button.xaml" />
|
|
|
- <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_DataGrid.xaml" />
|
|
|
- <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_Border.xaml" />
|
|
|
- <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_TbaControl.xaml" />
|
|
|
- <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_ScrollViewer.xaml" />
|
|
|
- <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_GroupBox.xaml" />
|
|
|
- <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_TextBox.xaml" />
|
|
|
- <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_TreeDataGrid.xaml" />
|
|
|
- <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_CheckBox.xaml" />
|
|
|
- <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_RadioButton.xaml" />
|
|
|
- </ResourceDictionary.MergedDictionaries>
|
|
|
- </ResourceDictionary>
|
|
|
+ <ResourceDictionary>
|
|
|
+ <cs:CheckConverter x:Key="CheckConverter" />
|
|
|
+ <ResourceDictionary.MergedDictionaries>
|
|
|
+ <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_ComboBox.xaml" />
|
|
|
+ <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_Button.xaml" />
|
|
|
+ <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_DataGrid.xaml" />
|
|
|
+ <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_Border.xaml" />
|
|
|
+ <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_TbaControl.xaml" />
|
|
|
+ <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_ScrollViewer.xaml" />
|
|
|
+ <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_GroupBox.xaml" />
|
|
|
+ <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_TextBox.xaml" />
|
|
|
+ <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_TreeDataGrid.xaml" />
|
|
|
+ <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_CheckBox.xaml" />
|
|
|
+ <ResourceDictionary Source="pack://application:,,,/YSAI.Core.Wpf;component/resources/style/Style_RadioButton.xaml" />
|
|
|
+ </ResourceDictionary.MergedDictionaries>
|
|
|
+ </ResourceDictionary>
|
|
|
</UserControl.Resources>
|
|
|
<Grid Height="830" Width="865">
|
|
|
- <Border CornerRadius="{DynamicResource WindowCornerRadius}" Background="{DynamicResource WindowContentBackground}">
|
|
|
- <Border.Effect>
|
|
|
- <BlurEffect Radius="0" />
|
|
|
- </Border.Effect>
|
|
|
- </Border>
|
|
|
- <GroupBox Style="{StaticResource GroupBoxTab}" Width="auto">
|
|
|
- <GroupBox.Header>
|
|
|
- <StackPanel Orientation="Horizontal">
|
|
|
- <Grid Background="transparent">
|
|
|
- <Grid.ColumnDefinitions>
|
|
|
- <ColumnDefinition Width="auto" />
|
|
|
- <ColumnDefinition Width="*" />
|
|
|
- </Grid.ColumnDefinitions>
|
|
|
- <Image Grid.Column="0" Margin="10,0,8,0" Source="{DynamicResource Communication}" Width="14" />
|
|
|
- <TextBlock Text="串口工具" FontSize="13" Grid.Column="1" Foreground="{DynamicResource Font.Content.Foreground}" />
|
|
|
- </Grid>
|
|
|
- </StackPanel>
|
|
|
- </GroupBox.Header>
|
|
|
- <Grid Grid.Row="0" Grid.Column="1">
|
|
|
- <Grid.RowDefinitions>
|
|
|
- <RowDefinition Height="120" />
|
|
|
- <RowDefinition Height="260" />
|
|
|
- <RowDefinition Height="400" />
|
|
|
- </Grid.RowDefinitions>
|
|
|
- --><!--设置区域--><!--
|
|
|
- <GroupBox Style="{StaticResource GroupBoxStyle}" Grid.Row="0" Grid.Column="0" Margin="5" Width="835">
|
|
|
- <GroupBox.Header>
|
|
|
- <Border>
|
|
|
- <TextBlock Text="{lang:Loc SetRegion}" Foreground="{DynamicResource Font.Head.Foreground}" />
|
|
|
- </Border>
|
|
|
- </GroupBox.Header>
|
|
|
- --><!--设置区域--><!--
|
|
|
- <Grid>
|
|
|
- <Grid.RowDefinitions>
|
|
|
- <RowDefinition />
|
|
|
- <RowDefinition />
|
|
|
- </Grid.RowDefinitions>
|
|
|
- <Grid.ColumnDefinitions>
|
|
|
- <ColumnDefinition Width="auto" />
|
|
|
- <ColumnDefinition Width="180" />
|
|
|
- <ColumnDefinition Width="*" />
|
|
|
- <ColumnDefinition Width="180" />
|
|
|
- <ColumnDefinition Width="*" />
|
|
|
- <ColumnDefinition Width="180" />
|
|
|
- </Grid.ColumnDefinitions>
|
|
|
-
|
|
|
- <Label Grid.Row="0" Grid.Column="0" Content="{lang:Loc [Channel]}" Foreground="{DynamicResource Font.Content.Foreground}" VerticalAlignment="Center" HorizontalAlignment="Right" />
|
|
|
- <ComboBox Grid.Row="0" Grid.Column="1" Height="30" Style="{StaticResource ComboBoxStyle}" Background="White" VerticalAlignment="Center" Margin="0,0,10,0"
|
|
|
- ItemsSource="{Binding Channel_ComboBoxDataList,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
|
|
- DisplayMemberPath="Key"
|
|
|
- SelectedItem="{Binding Channel_SelectedComboBoxData,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
|
|
- SelectedValue="Value" />
|
|
|
-
|
|
|
- <Label Grid.Row="0" Grid.Column="2" Content="{lang:Loc [BaudRate]}" Foreground="{DynamicResource Font.Content.Foreground}" VerticalAlignment="Center" HorizontalAlignment="Right" />
|
|
|
- <ComboBox Grid.Row="0" Grid.Column="3" Height="30" Style="{StaticResource ComboBoxStyle}" Background="White" VerticalAlignment="Center" Margin="0,0,10,0"
|
|
|
- ItemsSource="{Binding BaudRate_ComboBoxDataList,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
|
|
- DisplayMemberPath="Key"
|
|
|
- SelectedItem="{Binding BaudRate_SelectedComboBoxData,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
|
|
- SelectedValue="Value" />
|
|
|
-
|
|
|
- <Label Grid.Row="0" Grid.Column="4" Content="{lang:Loc [ParityBit]}" Foreground="{DynamicResource Font.Content.Foreground}" VerticalAlignment="Center" HorizontalAlignment="Right" />
|
|
|
- <ComboBox Grid.Row="0" Grid.Column="5" Height="30" Style="{StaticResource ComboBoxStyle}" Background="White" VerticalAlignment="Center" Margin="0,0,10,0"
|
|
|
- ItemsSource="{Binding ParityBit_ComboBoxDataList,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
|
|
- DisplayMemberPath="Key"
|
|
|
- SelectedItem="{Binding ParityBit_SelectedComboBoxData,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
|
|
- SelectedValue="Value" />
|
|
|
-
|
|
|
- <Label Grid.Row="1" Grid.Column="0" Content="{lang:Loc [StopBit]}" Foreground="{DynamicResource Font.Content.Foreground}" VerticalAlignment="Center" HorizontalAlignment="Right" />
|
|
|
- <ComboBox Grid.Row="1" Grid.Column="1" Height="30" Style="{StaticResource ComboBoxStyle}" Background="White" VerticalAlignment="Center" Margin="0,0,10,0"
|
|
|
- ItemsSource="{Binding StopBit_ComboBoxDataList,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
|
|
- DisplayMemberPath="Key"
|
|
|
- SelectedItem="{Binding StopBit_SelectedComboBoxData,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
|
|
- SelectedValue="Value" />
|
|
|
-
|
|
|
- <Label Grid.Row="1" Grid.Column="2" Content="{lang:Loc [DataBit]}" Foreground="{DynamicResource Font.Content.Foreground}" VerticalAlignment="Center" HorizontalAlignment="Right" />
|
|
|
- <ComboBox Grid.Row="1" Grid.Column="3" Height="30" Style="{StaticResource ComboBoxStyle}" Background="White" VerticalAlignment="Center" Margin="0,0,10,0"
|
|
|
- ItemsSource="{Binding DataBit_ComboBoxDataList,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
|
|
- DisplayMemberPath="Key"
|
|
|
- SelectedItem="{Binding DataBit_SelectedComboBoxData,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
|
|
- SelectedValue="Value" />
|
|
|
-
|
|
|
- <Grid Grid.Row="1" Grid.Column="4" HorizontalAlignment="Right">
|
|
|
- <Grid.ColumnDefinitions>
|
|
|
- <ColumnDefinition Width="auto" />
|
|
|
- <ColumnDefinition Width="auto" />
|
|
|
- <ColumnDefinition Width="auto" />
|
|
|
- </Grid.ColumnDefinitions>
|
|
|
- <Label Grid.Column="0" Content="[ " Foreground="{DynamicResource Font.Content.Foreground}" VerticalAlignment="Center" HorizontalAlignment="Right" />
|
|
|
- <cl:LedGaugeControl Grid.Column="1" Width="25" IsOn="{Binding LedIsOn}" IsFlashing="{Binding LedIsFlashing}" Color="{Binding LedColor}" HorizontalAlignment="Center" />
|
|
|
- <Label Grid.Column="2" Content=" ]" Foreground="{DynamicResource Font.Content.Foreground}" VerticalAlignment="Center" HorizontalAlignment="Left" />
|
|
|
- </Grid>
|
|
|
-
|
|
|
- <Grid Grid.Row="1" Grid.Column="5">
|
|
|
- <Grid.ColumnDefinitions>
|
|
|
- <ColumnDefinition Width="auto" />
|
|
|
- <ColumnDefinition Width="auto" />
|
|
|
- </Grid.ColumnDefinitions>
|
|
|
-
|
|
|
- <btn:ButtonControl Grid.Column="0" Width="80" Margin="0,0,10,0" Command="{Binding Close}" HorizontalAlignment="Center" VerticalAlignment="Center"
|
|
|
- IsMouseOverBorderBrushColor="{DynamicResource Control.Border.One.Color}"
|
|
|
- BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
- IsPressedBorderBrushColor="{DynamicResource Control.Border.Two.Color}"
|
|
|
- Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
- Icon="{DynamicResource CloseBase}"
|
|
|
- Content="{lang:Loc Close}"
|
|
|
- CornerRadius="{DynamicResource WindowCornerRadius}" />
|
|
|
-
|
|
|
- <btn:ButtonControl Grid.Column="1" Width="80" Margin="0,0,10,0" Command="{Binding Open}" HorizontalAlignment="Center" VerticalAlignment="Center"
|
|
|
- IsMouseOverBorderBrushColor="{DynamicResource Control.Border.One.Color}"
|
|
|
- BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
- IsPressedBorderBrushColor="{DynamicResource Control.Border.Two.Color}"
|
|
|
- Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
- Icon="{DynamicResource Open}"
|
|
|
- Content="{lang:Loc Open}"
|
|
|
- CornerRadius="{DynamicResource WindowCornerRadius}" />
|
|
|
-
|
|
|
-
|
|
|
- </Grid>
|
|
|
- </Grid>
|
|
|
- </GroupBox>
|
|
|
- --><!--发送区域--><!--
|
|
|
- <GroupBox Style="{StaticResource GroupBoxStyle}" Grid.Row="1" Margin="5" Width="835">
|
|
|
- <GroupBox.Header>
|
|
|
- <Border>
|
|
|
- <TextBlock Text="{lang:Loc SendRegion}" Foreground="{DynamicResource Font.Head.Foreground}" />
|
|
|
- </Border>
|
|
|
- </GroupBox.Header>
|
|
|
- <Grid>
|
|
|
- <Grid.RowDefinitions>
|
|
|
- <RowDefinition Height="45" />
|
|
|
- <RowDefinition />
|
|
|
- </Grid.RowDefinitions>
|
|
|
- <Grid.ColumnDefinitions>
|
|
|
- <ColumnDefinition Width="auto" />
|
|
|
- <ColumnDefinition Width="80" />
|
|
|
- <ColumnDefinition Width="auto" />
|
|
|
- <ColumnDefinition Width="80" />
|
|
|
- <ColumnDefinition Width="auto" />
|
|
|
- <ColumnDefinition Width="150" />
|
|
|
- <ColumnDefinition Width="*" />
|
|
|
- <ColumnDefinition Width="55" />
|
|
|
- <ColumnDefinition Width="55" />
|
|
|
- <ColumnDefinition Width="90" />
|
|
|
- </Grid.ColumnDefinitions>
|
|
|
-
|
|
|
- <Label Content="{lang:Loc [SendMode]}" Grid.Column="6" Foreground="{DynamicResource Font.Content.Foreground}" VerticalAlignment="Center" HorizontalAlignment="Right" Margin="0,0,10,0" />
|
|
|
- <RadioButton IsChecked="{Binding SendDataFormat,Mode=TwoWay,Converter={StaticResource CheckConverter},ConverterParameter=0}" Grid.Column="7" Style="{StaticResource RadioButtonStyle}" Content="ASCII" VerticalAlignment="Center" HorizontalAlignment="Center" />
|
|
|
- <RadioButton IsChecked="{Binding SendDataFormat,Mode=TwoWay,Converter={StaticResource CheckConverter},ConverterParameter=1}" Grid.Column="8" Style="{StaticResource RadioButtonStyle}" Content="Hex" VerticalAlignment="Center" HorizontalAlignment="Center" />
|
|
|
-
|
|
|
- <btn:ButtonControl Grid.Column="9" Width="80" Margin="0,0,10,0" Command="{Binding Send}" HorizontalAlignment="Left" VerticalAlignment="Center"
|
|
|
- IsMouseOverBorderBrushColor="{DynamicResource Control.Border.One.Color}"
|
|
|
- BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
- IsPressedBorderBrushColor="{DynamicResource Control.Border.Two.Color}"
|
|
|
- Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
- Icon="{DynamicResource Send}"
|
|
|
- Content="{lang:Loc Send}"
|
|
|
- CornerRadius="{DynamicResource WindowCornerRadius}" />
|
|
|
- <GroupBox Style="{StaticResource GroupBoxStyle}" Grid.Row="1" Grid.ColumnSpan="10">
|
|
|
- <GroupBox.Header>
|
|
|
- <Border>
|
|
|
- <TextBlock Text="{lang:Loc DataRegion}" Foreground="{DynamicResource Font.Head.Foreground}" />
|
|
|
- </Border>
|
|
|
- </GroupBox.Header>
|
|
|
- <TextBox Style="{DynamicResource TextBoxStyle2}" VerticalContentAlignment="Top" HorizontalContentAlignment="Left" TextWrapping="Wrap" AcceptsReturn="True" VerticalScrollBarVisibility="Visible" Margin="5" Text="{Binding SendData,UpdateSourceTrigger=PropertyChanged}" Height="auto" />
|
|
|
- </GroupBox>
|
|
|
- </Grid>
|
|
|
- </GroupBox>
|
|
|
- --><!--接收数据区域--><!--
|
|
|
- <GroupBox Style="{StaticResource GroupBoxStyle}" Grid.Row="2" Margin="5" Width="835">
|
|
|
- <GroupBox.Header>
|
|
|
- <Border>
|
|
|
- <TextBlock Text="{lang:Loc ReceptionRegion}" Foreground="{DynamicResource Font.Head.Foreground}" />
|
|
|
- </Border>
|
|
|
- </GroupBox.Header>
|
|
|
- <Grid>
|
|
|
- <Grid.RowDefinitions>
|
|
|
- <RowDefinition Height="45" />
|
|
|
- <RowDefinition />
|
|
|
- </Grid.RowDefinitions>
|
|
|
- <Grid.ColumnDefinitions>
|
|
|
- <ColumnDefinition />
|
|
|
- <ColumnDefinition Width="55" />
|
|
|
- <ColumnDefinition Width="55" />
|
|
|
- <ColumnDefinition Width="90" />
|
|
|
- </Grid.ColumnDefinitions>
|
|
|
- <Label Content="{lang:Loc DisplayMode}" Grid.Column="0" Foreground="{DynamicResource Font.Content.Foreground}" VerticalAlignment="Center" HorizontalAlignment="Right" Margin="0,0,10,0" />
|
|
|
- <RadioButton IsChecked="{Binding ReceiveDataFormat,Mode=TwoWay,Converter={StaticResource CheckConverter},ConverterParameter=0}" Grid.Column="1" Style="{StaticResource RadioButtonStyle}" Content="ASCII" VerticalAlignment="Center" HorizontalAlignment="Center" />
|
|
|
- <RadioButton IsChecked="{Binding ReceiveDataFormat,Mode=TwoWay,Converter={StaticResource CheckConverter},ConverterParameter=1}" Grid.Column="2" Style="{StaticResource RadioButtonStyle}" Content="Hex" VerticalAlignment="Center" HorizontalAlignment="Center" />
|
|
|
-
|
|
|
- <btn:ButtonControl Grid.Column="3" Width="80" Margin="0,0,10,0" Command="{Binding Empty}" HorizontalAlignment="Left" VerticalAlignment="Center"
|
|
|
- IsMouseOverBorderBrushColor="{DynamicResource Control.Border.One.Color}"
|
|
|
- BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
- IsPressedBorderBrushColor="{DynamicResource Control.Border.Two.Color}"
|
|
|
- Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
- Icon="{DynamicResource Clear}"
|
|
|
- Content="{lang:Loc Empty}"
|
|
|
- CornerRadius="{DynamicResource WindowCornerRadius}" />
|
|
|
- <GroupBox Style="{StaticResource GroupBoxStyle}" Grid.Row="1" Grid.ColumnSpan="7">
|
|
|
- <GroupBox.Header>
|
|
|
- <Border>
|
|
|
- <TextBlock Text="{lang:Loc DataRegion}" Foreground="{DynamicResource Font.Head.Foreground}" />
|
|
|
- </Border>
|
|
|
- </GroupBox.Header>
|
|
|
- <TextBox Style="{DynamicResource TextBoxStyle2}" VerticalContentAlignment="Top" HorizontalContentAlignment="Left" TextWrapping="Wrap" AcceptsReturn="True" VerticalScrollBarVisibility="Visible" Margin="5" Text="{Binding ReceiveData,UpdateSourceTrigger=PropertyChanged}" Height="auto" />
|
|
|
- </GroupBox>
|
|
|
- </Grid>
|
|
|
- </GroupBox>
|
|
|
- </Grid>
|
|
|
- </GroupBox>
|
|
|
+ <Border CornerRadius="{DynamicResource WindowCornerRadius}" Background="{DynamicResource WindowContentBackground}">
|
|
|
+ <Border.Effect>
|
|
|
+ <BlurEffect Radius="0" />
|
|
|
+ </Border.Effect>
|
|
|
+ </Border>
|
|
|
+ <GroupBox Style="{StaticResource GroupBoxTab}" Width="auto">
|
|
|
+ <GroupBox.Header>
|
|
|
+ <StackPanel Orientation="Horizontal">
|
|
|
+ <Grid Background="transparent">
|
|
|
+ <Grid.ColumnDefinitions>
|
|
|
+ <ColumnDefinition Width="auto" />
|
|
|
+ <ColumnDefinition Width="*" />
|
|
|
+ </Grid.ColumnDefinitions>
|
|
|
+ <Image Grid.Column="0" Margin="10,0,8,0" Source="{DynamicResource Communication}" Width="14" />
|
|
|
+ <TextBlock Text="串口工具" FontSize="13" Grid.Column="1" Foreground="{DynamicResource Font.Content.Foreground}" />
|
|
|
+ </Grid>
|
|
|
+ </StackPanel>
|
|
|
+ </GroupBox.Header>
|
|
|
+ <Grid Grid.Row="0" Grid.Column="1">
|
|
|
+ <Grid.RowDefinitions>
|
|
|
+ <RowDefinition Height="120" />
|
|
|
+ <RowDefinition Height="260" />
|
|
|
+ <RowDefinition Height="400" />
|
|
|
+ </Grid.RowDefinitions>
|
|
|
+ --><!--设置区域--><!--
|
|
|
+ <GroupBox Style="{StaticResource GroupBoxStyle}" Grid.Row="0" Grid.Column="0" Margin="5" Width="835">
|
|
|
+ <GroupBox.Header>
|
|
|
+ <Border>
|
|
|
+ <TextBlock Text="{lang:Loc SetRegion}" Foreground="{DynamicResource Font.Head.Foreground}" />
|
|
|
+ </Border>
|
|
|
+ </GroupBox.Header>
|
|
|
+ --><!--设置区域--><!--
|
|
|
+ <Grid>
|
|
|
+ <Grid.RowDefinitions>
|
|
|
+ <RowDefinition />
|
|
|
+ <RowDefinition />
|
|
|
+ </Grid.RowDefinitions>
|
|
|
+ <Grid.ColumnDefinitions>
|
|
|
+ <ColumnDefinition Width="auto" />
|
|
|
+ <ColumnDefinition Width="180" />
|
|
|
+ <ColumnDefinition Width="*" />
|
|
|
+ <ColumnDefinition Width="180" />
|
|
|
+ <ColumnDefinition Width="*" />
|
|
|
+ <ColumnDefinition Width="180" />
|
|
|
+ </Grid.ColumnDefinitions>
|
|
|
+
|
|
|
+ <Label Grid.Row="0" Grid.Column="0" Content="{lang:Loc [Channel]}" Foreground="{DynamicResource Font.Content.Foreground}" VerticalAlignment="Center" HorizontalAlignment="Right" />
|
|
|
+ <ComboBox Grid.Row="0" Grid.Column="1" Height="30" Style="{StaticResource ComboBoxStyle}" Background="White" VerticalAlignment="Center" Margin="0,0,10,0"
|
|
|
+ ItemsSource="{Binding Channel_ComboBoxDataList,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
|
|
+ DisplayMemberPath="Key"
|
|
|
+ SelectedItem="{Binding Channel_SelectedComboBoxData,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
|
|
+ SelectedValue="Value" />
|
|
|
+
|
|
|
+ <Label Grid.Row="0" Grid.Column="2" Content="{lang:Loc [BaudRate]}" Foreground="{DynamicResource Font.Content.Foreground}" VerticalAlignment="Center" HorizontalAlignment="Right" />
|
|
|
+ <ComboBox Grid.Row="0" Grid.Column="3" Height="30" Style="{StaticResource ComboBoxStyle}" Background="White" VerticalAlignment="Center" Margin="0,0,10,0"
|
|
|
+ ItemsSource="{Binding BaudRate_ComboBoxDataList,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
|
|
+ DisplayMemberPath="Key"
|
|
|
+ SelectedItem="{Binding BaudRate_SelectedComboBoxData,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
|
|
+ SelectedValue="Value" />
|
|
|
+
|
|
|
+ <Label Grid.Row="0" Grid.Column="4" Content="{lang:Loc [ParityBit]}" Foreground="{DynamicResource Font.Content.Foreground}" VerticalAlignment="Center" HorizontalAlignment="Right" />
|
|
|
+ <ComboBox Grid.Row="0" Grid.Column="5" Height="30" Style="{StaticResource ComboBoxStyle}" Background="White" VerticalAlignment="Center" Margin="0,0,10,0"
|
|
|
+ ItemsSource="{Binding ParityBit_ComboBoxDataList,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
|
|
+ DisplayMemberPath="Key"
|
|
|
+ SelectedItem="{Binding ParityBit_SelectedComboBoxData,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
|
|
+ SelectedValue="Value" />
|
|
|
+
|
|
|
+ <Label Grid.Row="1" Grid.Column="0" Content="{lang:Loc [StopBit]}" Foreground="{DynamicResource Font.Content.Foreground}" VerticalAlignment="Center" HorizontalAlignment="Right" />
|
|
|
+ <ComboBox Grid.Row="1" Grid.Column="1" Height="30" Style="{StaticResource ComboBoxStyle}" Background="White" VerticalAlignment="Center" Margin="0,0,10,0"
|
|
|
+ ItemsSource="{Binding StopBit_ComboBoxDataList,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
|
|
+ DisplayMemberPath="Key"
|
|
|
+ SelectedItem="{Binding StopBit_SelectedComboBoxData,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
|
|
+ SelectedValue="Value" />
|
|
|
+
|
|
|
+ <Label Grid.Row="1" Grid.Column="2" Content="{lang:Loc [DataBit]}" Foreground="{DynamicResource Font.Content.Foreground}" VerticalAlignment="Center" HorizontalAlignment="Right" />
|
|
|
+ <ComboBox Grid.Row="1" Grid.Column="3" Height="30" Style="{StaticResource ComboBoxStyle}" Background="White" VerticalAlignment="Center" Margin="0,0,10,0"
|
|
|
+ ItemsSource="{Binding DataBit_ComboBoxDataList,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
|
|
+ DisplayMemberPath="Key"
|
|
|
+ SelectedItem="{Binding DataBit_SelectedComboBoxData,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
|
|
+ SelectedValue="Value" />
|
|
|
+
|
|
|
+ <Grid Grid.Row="1" Grid.Column="4" HorizontalAlignment="Right">
|
|
|
+ <Grid.ColumnDefinitions>
|
|
|
+ <ColumnDefinition Width="auto" />
|
|
|
+ <ColumnDefinition Width="auto" />
|
|
|
+ <ColumnDefinition Width="auto" />
|
|
|
+ </Grid.ColumnDefinitions>
|
|
|
+ <Label Grid.Column="0" Content="[ " Foreground="{DynamicResource Font.Content.Foreground}" VerticalAlignment="Center" HorizontalAlignment="Right" />
|
|
|
+ <cl:LedGaugeControl Grid.Column="1" Width="25" IsOn="{Binding LedIsOn}" IsFlashing="{Binding LedIsFlashing}" Color="{Binding LedColor}" HorizontalAlignment="Center" />
|
|
|
+ <Label Grid.Column="2" Content=" ]" Foreground="{DynamicResource Font.Content.Foreground}" VerticalAlignment="Center" HorizontalAlignment="Left" />
|
|
|
+ </Grid>
|
|
|
+
|
|
|
+ <Grid Grid.Row="1" Grid.Column="5">
|
|
|
+ <Grid.ColumnDefinitions>
|
|
|
+ <ColumnDefinition Width="auto" />
|
|
|
+ <ColumnDefinition Width="auto" />
|
|
|
+ </Grid.ColumnDefinitions>
|
|
|
+
|
|
|
+ <btn:ButtonControl Grid.Column="0" Width="80" Margin="0,0,10,0" Command="{Binding Close}" HorizontalAlignment="Center" VerticalAlignment="Center"
|
|
|
+ IsMouseOverBorderBrushColor="{DynamicResource Control.Border.One.Color}"
|
|
|
+ BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
+ IsPressedBorderBrushColor="{DynamicResource Control.Border.Two.Color}"
|
|
|
+ Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
+ Icon="{DynamicResource CloseBase}"
|
|
|
+ Content="{lang:Loc Close}"
|
|
|
+ CornerRadius="{DynamicResource WindowCornerRadius}" />
|
|
|
+
|
|
|
+ <btn:ButtonControl Grid.Column="1" Width="80" Margin="0,0,10,0" Command="{Binding Open}" HorizontalAlignment="Center" VerticalAlignment="Center"
|
|
|
+ IsMouseOverBorderBrushColor="{DynamicResource Control.Border.One.Color}"
|
|
|
+ BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
+ IsPressedBorderBrushColor="{DynamicResource Control.Border.Two.Color}"
|
|
|
+ Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
+ Icon="{DynamicResource Open}"
|
|
|
+ Content="{lang:Loc Open}"
|
|
|
+ CornerRadius="{DynamicResource WindowCornerRadius}" />
|
|
|
+
|
|
|
+
|
|
|
+ </Grid>
|
|
|
+ </Grid>
|
|
|
+ </GroupBox>
|
|
|
+ --><!--发送区域--><!--
|
|
|
+ <GroupBox Style="{StaticResource GroupBoxStyle}" Grid.Row="1" Margin="5" Width="835">
|
|
|
+ <GroupBox.Header>
|
|
|
+ <Border>
|
|
|
+ <TextBlock Text="{lang:Loc SendRegion}" Foreground="{DynamicResource Font.Head.Foreground}" />
|
|
|
+ </Border>
|
|
|
+ </GroupBox.Header>
|
|
|
+ <Grid>
|
|
|
+ <Grid.RowDefinitions>
|
|
|
+ <RowDefinition Height="45" />
|
|
|
+ <RowDefinition />
|
|
|
+ </Grid.RowDefinitions>
|
|
|
+ <Grid.ColumnDefinitions>
|
|
|
+ <ColumnDefinition Width="auto" />
|
|
|
+ <ColumnDefinition Width="80" />
|
|
|
+ <ColumnDefinition Width="auto" />
|
|
|
+ <ColumnDefinition Width="80" />
|
|
|
+ <ColumnDefinition Width="auto" />
|
|
|
+ <ColumnDefinition Width="150" />
|
|
|
+ <ColumnDefinition Width="*" />
|
|
|
+ <ColumnDefinition Width="55" />
|
|
|
+ <ColumnDefinition Width="55" />
|
|
|
+ <ColumnDefinition Width="90" />
|
|
|
+ </Grid.ColumnDefinitions>
|
|
|
+
|
|
|
+ <Label Content="{lang:Loc [SendMode]}" Grid.Column="6" Foreground="{DynamicResource Font.Content.Foreground}" VerticalAlignment="Center" HorizontalAlignment="Right" Margin="0,0,10,0" />
|
|
|
+ <RadioButton IsChecked="{Binding SendDataFormat,Mode=TwoWay,Converter={StaticResource CheckConverter},ConverterParameter=0}" Grid.Column="7" Style="{StaticResource RadioButtonStyle}" Content="ASCII" VerticalAlignment="Center" HorizontalAlignment="Center" />
|
|
|
+ <RadioButton IsChecked="{Binding SendDataFormat,Mode=TwoWay,Converter={StaticResource CheckConverter},ConverterParameter=1}" Grid.Column="8" Style="{StaticResource RadioButtonStyle}" Content="Hex" VerticalAlignment="Center" HorizontalAlignment="Center" />
|
|
|
+
|
|
|
+ <btn:ButtonControl Grid.Column="9" Width="80" Margin="0,0,10,0" Command="{Binding Send}" HorizontalAlignment="Left" VerticalAlignment="Center"
|
|
|
+ IsMouseOverBorderBrushColor="{DynamicResource Control.Border.One.Color}"
|
|
|
+ BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
+ IsPressedBorderBrushColor="{DynamicResource Control.Border.Two.Color}"
|
|
|
+ Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
+ Icon="{DynamicResource Send}"
|
|
|
+ Content="{lang:Loc Send}"
|
|
|
+ CornerRadius="{DynamicResource WindowCornerRadius}" />
|
|
|
+ <GroupBox Style="{StaticResource GroupBoxStyle}" Grid.Row="1" Grid.ColumnSpan="10">
|
|
|
+ <GroupBox.Header>
|
|
|
+ <Border>
|
|
|
+ <TextBlock Text="{lang:Loc DataRegion}" Foreground="{DynamicResource Font.Head.Foreground}" />
|
|
|
+ </Border>
|
|
|
+ </GroupBox.Header>
|
|
|
+ <TextBox Style="{DynamicResource TextBoxStyle2}" VerticalContentAlignment="Top" HorizontalContentAlignment="Left" TextWrapping="Wrap" AcceptsReturn="True" VerticalScrollBarVisibility="Visible" Margin="5" Text="{Binding SendData,UpdateSourceTrigger=PropertyChanged}" Height="auto" />
|
|
|
+ </GroupBox>
|
|
|
+ </Grid>
|
|
|
+ </GroupBox>
|
|
|
+ --><!--接收数据区域--><!--
|
|
|
+ <GroupBox Style="{StaticResource GroupBoxStyle}" Grid.Row="2" Margin="5" Width="835">
|
|
|
+ <GroupBox.Header>
|
|
|
+ <Border>
|
|
|
+ <TextBlock Text="{lang:Loc ReceptionRegion}" Foreground="{DynamicResource Font.Head.Foreground}" />
|
|
|
+ </Border>
|
|
|
+ </GroupBox.Header>
|
|
|
+ <Grid>
|
|
|
+ <Grid.RowDefinitions>
|
|
|
+ <RowDefinition Height="45" />
|
|
|
+ <RowDefinition />
|
|
|
+ </Grid.RowDefinitions>
|
|
|
+ <Grid.ColumnDefinitions>
|
|
|
+ <ColumnDefinition />
|
|
|
+ <ColumnDefinition Width="55" />
|
|
|
+ <ColumnDefinition Width="55" />
|
|
|
+ <ColumnDefinition Width="90" />
|
|
|
+ </Grid.ColumnDefinitions>
|
|
|
+ <Label Content="{lang:Loc DisplayMode}" Grid.Column="0" Foreground="{DynamicResource Font.Content.Foreground}" VerticalAlignment="Center" HorizontalAlignment="Right" Margin="0,0,10,0" />
|
|
|
+ <RadioButton IsChecked="{Binding ReceiveDataFormat,Mode=TwoWay,Converter={StaticResource CheckConverter},ConverterParameter=0}" Grid.Column="1" Style="{StaticResource RadioButtonStyle}" Content="ASCII" VerticalAlignment="Center" HorizontalAlignment="Center" />
|
|
|
+ <RadioButton IsChecked="{Binding ReceiveDataFormat,Mode=TwoWay,Converter={StaticResource CheckConverter},ConverterParameter=1}" Grid.Column="2" Style="{StaticResource RadioButtonStyle}" Content="Hex" VerticalAlignment="Center" HorizontalAlignment="Center" />
|
|
|
+
|
|
|
+ <btn:ButtonControl Grid.Column="3" Width="80" Margin="0,0,10,0" Command="{Binding Empty}" HorizontalAlignment="Left" VerticalAlignment="Center"
|
|
|
+ IsMouseOverBorderBrushColor="{DynamicResource Control.Border.One.Color}"
|
|
|
+ BorderBrush="{DynamicResource Control.Border.Color}"
|
|
|
+ IsPressedBorderBrushColor="{DynamicResource Control.Border.Two.Color}"
|
|
|
+ Foreground="{DynamicResource Font.Content.Foreground}"
|
|
|
+ Icon="{DynamicResource Clear}"
|
|
|
+ Content="{lang:Loc Empty}"
|
|
|
+ CornerRadius="{DynamicResource WindowCornerRadius}" />
|
|
|
+ <GroupBox Style="{StaticResource GroupBoxStyle}" Grid.Row="1" Grid.ColumnSpan="7">
|
|
|
+ <GroupBox.Header>
|
|
|
+ <Border>
|
|
|
+ <TextBlock Text="{lang:Loc DataRegion}" Foreground="{DynamicResource Font.Head.Foreground}" />
|
|
|
+ </Border>
|
|
|
+ </GroupBox.Header>
|
|
|
+ <TextBox Style="{DynamicResource TextBoxStyle2}" VerticalContentAlignment="Top" HorizontalContentAlignment="Left" TextWrapping="Wrap" AcceptsReturn="True" VerticalScrollBarVisibility="Visible" Margin="5" Text="{Binding ReceiveData,UpdateSourceTrigger=PropertyChanged}" Height="auto" />
|
|
|
+ </GroupBox>
|
|
|
+ </Grid>
|
|
|
+ </GroupBox>
|
|
|
+ </Grid>
|
|
|
+ </GroupBox>
|
|
|
</Grid>-->
|
|
|
<!--#endregion-->
|
|
|
</UserControl>
|