源适应性界面
This commit is contained in:
@@ -0,0 +1,410 @@
|
||||
<UserControl x:Class="PowerAdaptabilityModule.Views.PowerAdaptabilityView"
|
||||
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:i="http://schemas.microsoft.com/xaml/behaviors"
|
||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||
mc:Ignorable="d"
|
||||
xmlns:prism="http://prismlibrary.com/"
|
||||
xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
|
||||
xmlns:converters="clr-namespace:UIShare.Converters;assembly=UIShare"
|
||||
xmlns:oxy="http://oxyplot.org/wpf"
|
||||
prism:ViewModelLocator.AutoWireViewModel="True"
|
||||
d:DesignHeight="1080"
|
||||
d:DesignWidth="1920">
|
||||
<UserControl.Resources>
|
||||
<converters:BooleanToVisibilityConverter x:Key="BoolToVis" />
|
||||
</UserControl.Resources>
|
||||
|
||||
<Border Background="#F5F7FA">
|
||||
<Grid Margin="8">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="440" />
|
||||
<ColumnDefinition Width="*" />
|
||||
</Grid.ColumnDefinitions>
|
||||
|
||||
<!-- ============ 左侧:Chroma 命令面板 ============ -->
|
||||
<ScrollViewer Grid.Column="0"
|
||||
VerticalScrollBarVisibility="Auto"
|
||||
HorizontalScrollBarVisibility="Disabled"
|
||||
Margin="0,0,8,0">
|
||||
<StackPanel>
|
||||
|
||||
<!-- 设备状态卡片 -->
|
||||
<materialDesign:Card Margin="0,0,0,8" Padding="12,8">
|
||||
<Grid>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="Auto" />
|
||||
<ColumnDefinition Width="*" />
|
||||
<ColumnDefinition Width="Auto" />
|
||||
</Grid.ColumnDefinitions>
|
||||
<StackPanel Orientation="Horizontal" VerticalAlignment="Center">
|
||||
<materialDesign:PackIcon Kind="Flash"
|
||||
Width="22" Height="22"
|
||||
Foreground="#1565C0"
|
||||
Margin="0,0,8,0"
|
||||
VerticalAlignment="Center" />
|
||||
<TextBlock Text="电源适应性测试 · Chroma61800"
|
||||
FontSize="15" FontWeight="Bold"
|
||||
VerticalAlignment="Center" />
|
||||
<TextBlock Text="{Binding DeviceName, StringFormat=' [{0}]'}"
|
||||
FontSize="13" Foreground="#757575"
|
||||
VerticalAlignment="Center" Margin="4,0,0,0" />
|
||||
</StackPanel>
|
||||
<StackPanel Grid.Column="2" Orientation="Horizontal" VerticalAlignment="Center">
|
||||
<Border Width="10" Height="10" CornerRadius="5" Margin="0,0,6,0">
|
||||
<Border.Style>
|
||||
<Style TargetType="Border">
|
||||
<Setter Property="Background" Value="#F44336" />
|
||||
<Style.Triggers>
|
||||
<DataTrigger Binding="{Binding IsConnected}" Value="True">
|
||||
<Setter Property="Background" Value="#4CAF50" />
|
||||
</DataTrigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
</Border.Style>
|
||||
</Border>
|
||||
<TextBlock VerticalAlignment="Center" FontSize="12">
|
||||
<TextBlock.Style>
|
||||
<Style TargetType="TextBlock">
|
||||
<Setter Property="Text" Value="未连接" />
|
||||
<Setter Property="Foreground" Value="#F44336" />
|
||||
<Style.Triggers>
|
||||
<DataTrigger Binding="{Binding IsConnected}" Value="True">
|
||||
<Setter Property="Text" Value="已连接" />
|
||||
<Setter Property="Foreground" Value="#4CAF50" />
|
||||
</DataTrigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
</TextBlock.Style>
|
||||
</TextBlock>
|
||||
<ProgressBar IsIndeterminate="True" Width="60" Height="4"
|
||||
Margin="12,0,0,0"
|
||||
Visibility="{Binding IsBusy, Converter={StaticResource BoolToVis}}" />
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</materialDesign:Card>
|
||||
|
||||
<!-- 三相输出控制 -->
|
||||
<GroupBox Header="三相输出控制" Margin="0,0,0,8"
|
||||
materialDesign:ColorZoneAssist.Mode="PrimaryLight">
|
||||
<StackPanel Margin="4">
|
||||
<StackPanel Orientation="Horizontal" Margin="0,4">
|
||||
<Button Content="开启输出" Command="{Binding OutputOnCommand}"
|
||||
Style="{StaticResource CmdBtn}"
|
||||
Background="#388E3C" Foreground="White" />
|
||||
<Button Content="关闭输出" Command="{Binding OutputOffCommand}"
|
||||
Style="{StaticResource WarnBtn}" />
|
||||
<Button Content="复位" Command="{Binding ResetCommand}"
|
||||
Style="{StaticResource CmdBtn}" />
|
||||
<Button Content="查询 IDN" Command="{Binding QueryIdnCommand}"
|
||||
Style="{StaticResource CmdBtn}" />
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" Margin="0,4">
|
||||
<TextBlock Text="相模式" Style="{StaticResource ParamLabel}" />
|
||||
<Button Content="三相" Command="{Binding SetThreePhaseModeCommand}"
|
||||
Style="{StaticResource CmdBtn}" />
|
||||
<Button Content="单相" Command="{Binding SetSinglePhaseModeCommand}"
|
||||
Style="{StaticResource CmdBtn}" />
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" Margin="0,4">
|
||||
<TextBlock Text="耦合模式" Style="{StaticResource ParamLabel}" />
|
||||
<ComboBox Width="110" Height="32" FontSize="12" Margin="4,0"
|
||||
ItemsSource="{Binding CouplingOptions}"
|
||||
SelectedItem="{Binding CouplingMode}" />
|
||||
<Button Content="应用" Command="{Binding ApplyCouplingCommand}"
|
||||
Style="{StaticResource CmdBtn}" />
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" Margin="0,4">
|
||||
<TextBlock Text="三相关系" Style="{StaticResource ParamLabel}" />
|
||||
<ComboBox Width="110" Height="32" FontSize="12" Margin="4,0"
|
||||
ItemsSource="{Binding RelationOptions}"
|
||||
SelectedItem="{Binding ThreePhaseRelation}" />
|
||||
<Button Content="应用" Command="{Binding ApplyRelationCommand}"
|
||||
Style="{StaticResource CmdBtn}" />
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" Margin="0,4">
|
||||
<TextBlock Text="输出继电器" Style="{StaticResource ParamLabel}" />
|
||||
<Button Content="开启" Command="{Binding RelayOnCommand}"
|
||||
Style="{StaticResource CmdBtn}" />
|
||||
<Button Content="关闭" Command="{Binding RelayOffCommand}"
|
||||
Style="{StaticResource CmdBtn}" />
|
||||
</StackPanel>
|
||||
</StackPanel>
|
||||
</GroupBox>
|
||||
|
||||
<!-- 输出参数设置 -->
|
||||
<GroupBox Header="输出参数设置" Margin="0,0,0,8"
|
||||
materialDesign:ColorZoneAssist.Mode="PrimaryLight">
|
||||
<StackPanel Margin="4">
|
||||
<StackPanel Orientation="Horizontal" Margin="0,4">
|
||||
<TextBlock Text="电压 (V)" Style="{StaticResource ParamLabel}" />
|
||||
<TextBox Style="{StaticResource NumInput}"
|
||||
Text="{Binding Voltage, UpdateSourceTrigger=PropertyChanged}" />
|
||||
<Button Content="设置" Command="{Binding SetVoltageCommand}"
|
||||
Style="{StaticResource CmdBtn}" />
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" Margin="0,4">
|
||||
<TextBlock Text="频率 (Hz)" Style="{StaticResource ParamLabel}" />
|
||||
<TextBox Style="{StaticResource NumInput}"
|
||||
Text="{Binding Frequency, UpdateSourceTrigger=PropertyChanged}" />
|
||||
<Button Content="设置" Command="{Binding SetFrequencyCommand}"
|
||||
Style="{StaticResource CmdBtn}" />
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" Margin="0,4">
|
||||
<TextBlock Text="波形" Style="{StaticResource ParamLabel}" />
|
||||
<ComboBox Width="130" Height="32" FontSize="12" Margin="4,0"
|
||||
ItemsSource="{Binding WaveformOptions}"
|
||||
SelectedItem="{Binding Waveform}" />
|
||||
<Button Content="设置" Command="{Binding SetWaveformCommand}"
|
||||
Style="{StaticResource CmdBtn}" />
|
||||
</StackPanel>
|
||||
</StackPanel>
|
||||
</GroupBox>
|
||||
|
||||
<!-- LIST 模式 -->
|
||||
<GroupBox Header="LIST 模式" Margin="0,0,0,8"
|
||||
materialDesign:ColorZoneAssist.Mode="PrimaryLight">
|
||||
<StackPanel Margin="4">
|
||||
<StackPanel Orientation="Horizontal" Margin="0,4">
|
||||
<TextBlock Text="操作模态" Style="{StaticResource ParamLabel}" />
|
||||
<Button Content="FIXED 固定" Command="{Binding SetFixedModeCommand}"
|
||||
Style="{StaticResource CmdBtn}" />
|
||||
<Button Content="进入 LIST" Command="{Binding EnterListModeCommand}"
|
||||
Style="{StaticResource CmdBtn}" />
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" Margin="0,4">
|
||||
<TextBlock Text="列表耦合" Style="{StaticResource ParamLabel}" />
|
||||
<ComboBox Width="80" Height="32" FontSize="12" Margin="4,0"
|
||||
ItemsSource="{Binding ListCouplingOptions}"
|
||||
SelectedItem="{Binding ListCoupling}" />
|
||||
<TextBlock Text="触发" Style="{StaticResource ParamLabel}" />
|
||||
<ComboBox Width="100" Height="32" FontSize="12" Margin="4,0"
|
||||
ItemsSource="{Binding ListTriggerOptions}"
|
||||
SelectedItem="{Binding ListTrigger}" />
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" Margin="0,4">
|
||||
<TextBlock Text="执行次数" Style="{StaticResource ParamLabel}" />
|
||||
<TextBox Style="{StaticResource NumInput}" Width="80"
|
||||
Text="{Binding ListCount, UpdateSourceTrigger=PropertyChanged}" />
|
||||
<TextBlock Text="时间基础" Style="{StaticResource ParamLabel}" />
|
||||
<ComboBox Width="90" Height="32" FontSize="12" Margin="4,0"
|
||||
ItemsSource="{Binding ListTimeBaseOptions}"
|
||||
SelectedItem="{Binding ListTimeBase}" />
|
||||
</StackPanel>
|
||||
<Button Content="应用基础配置(耦合 / 触发 / 次数 / 时基)"
|
||||
Command="{Binding ApplyListBasicCommand}"
|
||||
Style="{StaticResource CmdBtn}"
|
||||
HorizontalAlignment="Left" Margin="0,4" />
|
||||
|
||||
<Separator Margin="0,6" />
|
||||
<TextBlock Text="序列设置(英文逗号分隔,留空则不下发)"
|
||||
FontSize="12" Foreground="#616161" Margin="4,2" />
|
||||
<Grid Margin="0,2">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="92" />
|
||||
<ColumnDefinition Width="*" />
|
||||
</Grid.ColumnDefinitions>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto" />
|
||||
<RowDefinition Height="Auto" />
|
||||
<RowDefinition Height="Auto" />
|
||||
<RowDefinition Height="Auto" />
|
||||
<RowDefinition Height="Auto" />
|
||||
<RowDefinition Height="Auto" />
|
||||
<RowDefinition Height="Auto" />
|
||||
</Grid.RowDefinitions>
|
||||
|
||||
<TextBlock Grid.Row="0" Grid.Column="0" Text="AC起始电压"
|
||||
Style="{StaticResource ParamLabel}" />
|
||||
<TextBox Grid.Row="0" Grid.Column="1" Style="{StaticResource NumInput}"
|
||||
Width="240" ToolTip="单位 V,如 0,50,100,150"
|
||||
Text="{Binding ListVoltAcStartText, UpdateSourceTrigger=PropertyChanged}" />
|
||||
|
||||
<TextBlock Grid.Row="1" Grid.Column="0" Text="AC结束电压"
|
||||
Style="{StaticResource ParamLabel}" />
|
||||
<TextBox Grid.Row="1" Grid.Column="1" Style="{StaticResource NumInput}"
|
||||
Width="240" ToolTip="单位 V,如 150,100,50,0"
|
||||
Text="{Binding ListVoltAcEndText, UpdateSourceTrigger=PropertyChanged}" />
|
||||
|
||||
<TextBlock Grid.Row="2" Grid.Column="0" Text="起始频率"
|
||||
Style="{StaticResource ParamLabel}" />
|
||||
<TextBox Grid.Row="2" Grid.Column="1" Style="{StaticResource NumInput}"
|
||||
Width="240" ToolTip="单位 Hz,如 50,60,50"
|
||||
Text="{Binding ListFreqStartText, UpdateSourceTrigger=PropertyChanged}" />
|
||||
|
||||
<TextBlock Grid.Row="3" Grid.Column="0" Text="结束频率"
|
||||
Style="{StaticResource ParamLabel}" />
|
||||
<TextBox Grid.Row="3" Grid.Column="1" Style="{StaticResource NumInput}"
|
||||
Width="240" ToolTip="单位 Hz,如 50,50,60"
|
||||
Text="{Binding ListFreqEndText, UpdateSourceTrigger=PropertyChanged}" />
|
||||
|
||||
<TextBlock Grid.Row="4" Grid.Column="0" Text="静止时间"
|
||||
Style="{StaticResource ParamLabel}" />
|
||||
<TextBox Grid.Row="4" Grid.Column="1" Style="{StaticResource NumInput}"
|
||||
Width="240" ToolTip="单位 ms,如 500,500,500"
|
||||
Text="{Binding ListDwellText, UpdateSourceTrigger=PropertyChanged}" />
|
||||
|
||||
<TextBlock Grid.Row="5" Grid.Column="0" Text="相位角度"
|
||||
Style="{StaticResource ParamLabel}" />
|
||||
<TextBox Grid.Row="5" Grid.Column="1" Style="{StaticResource NumInput}"
|
||||
Width="240" ToolTip="单位 °,如 0,120,240"
|
||||
Text="{Binding ListDegrText, UpdateSourceTrigger=PropertyChanged}" />
|
||||
|
||||
<TextBlock Grid.Row="6" Grid.Column="0" Text="波形顺序"
|
||||
Style="{StaticResource ParamLabel}" />
|
||||
<TextBox Grid.Row="6" Grid.Column="1" Style="{StaticResource NumInput}"
|
||||
Width="240" ToolTip="A / B 序列,如 A,B,A"
|
||||
Text="{Binding ListShapeText, UpdateSourceTrigger=PropertyChanged}" />
|
||||
</Grid>
|
||||
<Button Content="应用序列" Command="{Binding ApplyListSequencesCommand}"
|
||||
Style="{StaticResource CmdBtn}"
|
||||
HorizontalAlignment="Left" Margin="0,4" />
|
||||
|
||||
<Separator Margin="0,6" />
|
||||
<StackPanel Orientation="Horizontal" Margin="0,4">
|
||||
<Button Content="开始执行" Command="{Binding ListStartCommand}"
|
||||
Style="{StaticResource CmdBtn}"
|
||||
Background="#388E3C" Foreground="White" />
|
||||
<Button Content="停止执行" Command="{Binding ListStopCommand}"
|
||||
Style="{StaticResource WarnBtn}" />
|
||||
</StackPanel>
|
||||
</StackPanel>
|
||||
</GroupBox>
|
||||
|
||||
<!-- 数据采集 -->
|
||||
<GroupBox Header="数据采集" Margin="0,0,0,8"
|
||||
materialDesign:ColorZoneAssist.Mode="PrimaryLight">
|
||||
<StackPanel Margin="4">
|
||||
<StackPanel Orientation="Horizontal" Margin="0,4">
|
||||
<Button Content="开始采集" Command="{Binding StartSamplingCommand}"
|
||||
Style="{StaticResource CmdBtn}"
|
||||
Background="#388E3C" Foreground="White" />
|
||||
<Button Content="停止采集" Command="{Binding StopSamplingCommand}"
|
||||
Style="{StaticResource CmdBtn}" />
|
||||
<Button Content="清空图表" Command="{Binding ClearChartsCommand}"
|
||||
Style="{StaticResource CmdBtn}" />
|
||||
<TextBlock VerticalAlignment="Center" FontSize="12" Margin="8,0,0,0">
|
||||
<TextBlock.Style>
|
||||
<Style TargetType="TextBlock">
|
||||
<Setter Property="Text" Value="采集中…" />
|
||||
<Setter Property="Foreground" Value="#4CAF50" />
|
||||
<Style.Triggers>
|
||||
<DataTrigger Binding="{Binding IsSampling}" Value="False">
|
||||
<Setter Property="Text" Value="采集已停止" />
|
||||
<Setter Property="Foreground" Value="#9E9E9E" />
|
||||
</DataTrigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
</TextBlock.Style>
|
||||
</TextBlock>
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" Margin="0,4">
|
||||
<TextBlock Text="频率" Style="{StaticResource ParamLabel}" />
|
||||
<TextBox Style="{StaticResource MeasureBox}"
|
||||
Text="{Binding FrequencyNow, Mode=OneWay, StringFormat={}{0:F2}}" />
|
||||
<TextBlock Text="Hz" VerticalAlignment="Center" Margin="2,0,12,0" />
|
||||
<TextBlock Text="功率" Style="{StaticResource ParamLabel}" />
|
||||
<TextBox Style="{StaticResource MeasureBox}"
|
||||
Text="{Binding PowerNow, Mode=OneWay, StringFormat={}{0:F2}}" />
|
||||
<TextBlock Text="W" VerticalAlignment="Center" Margin="2,0,0,0" />
|
||||
</StackPanel>
|
||||
</StackPanel>
|
||||
</GroupBox>
|
||||
|
||||
<!-- 日志 -->
|
||||
<GroupBox Header="日志" materialDesign:ColorZoneAssist.Mode="PrimaryLight">
|
||||
<ScrollViewer Height="150" VerticalScrollBarVisibility="Auto">
|
||||
<TextBox Text="{Binding ResponseLog, Mode=OneWay}"
|
||||
IsReadOnly="True" TextWrapping="Wrap"
|
||||
FontSize="11" FontFamily="Consolas"
|
||||
Background="#FAFAFA" BorderThickness="0"
|
||||
VerticalAlignment="Top" />
|
||||
</ScrollViewer>
|
||||
</GroupBox>
|
||||
</StackPanel>
|
||||
</ScrollViewer>
|
||||
|
||||
<!-- ============ 右侧:三相正弦波(电压 / 电流 / 功率,横轴相位角 0~360°,有正有负) ============ -->
|
||||
<Grid Grid.Column="1">
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="*" />
|
||||
<RowDefinition Height="*" />
|
||||
<RowDefinition Height="*" />
|
||||
</Grid.RowDefinitions>
|
||||
|
||||
<!-- 三相电压 -->
|
||||
<Border Grid.Row="0" Background="White" BorderBrush="#DDD" BorderThickness="1" Margin="0,0,0,4">
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto" />
|
||||
<RowDefinition Height="*" />
|
||||
</Grid.RowDefinitions>
|
||||
<StackPanel Orientation="Horizontal" Margin="10,6">
|
||||
<TextBlock Text="三相电压 (V)" FontWeight="Bold" FontSize="13"
|
||||
VerticalAlignment="Center" Margin="0,0,16,0" />
|
||||
<TextBlock Text="A" FontSize="12" Foreground="#E53935" VerticalAlignment="Center" />
|
||||
<TextBlock Text="{Binding VoltageA, StringFormat={}{0:F1}}" FontSize="12"
|
||||
FontWeight="Bold" VerticalAlignment="Center" Margin="3,0,14,0" />
|
||||
<TextBlock Text="B" FontSize="12" Foreground="#43A047" VerticalAlignment="Center" />
|
||||
<TextBlock Text="{Binding VoltageB, StringFormat={}{0:F1}}" FontSize="12"
|
||||
FontWeight="Bold" VerticalAlignment="Center" Margin="3,0,14,0" />
|
||||
<TextBlock Text="C" FontSize="12" Foreground="#1E88E5" VerticalAlignment="Center" />
|
||||
<TextBlock Text="{Binding VoltageC, StringFormat={}{0:F1}}" FontSize="12"
|
||||
FontWeight="Bold" VerticalAlignment="Center" Margin="3,0,0,0" />
|
||||
</StackPanel>
|
||||
<oxy:PlotView Grid.Row="1" Model="{Binding VoltagePlot}"
|
||||
Background="Transparent" Margin="4,0,4,4" />
|
||||
</Grid>
|
||||
</Border>
|
||||
|
||||
<!-- 三相电流 -->
|
||||
<Border Grid.Row="1" Background="White" BorderBrush="#DDD" BorderThickness="1" Margin="0,0,0,4">
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto" />
|
||||
<RowDefinition Height="*" />
|
||||
</Grid.RowDefinitions>
|
||||
<StackPanel Orientation="Horizontal" Margin="10,6">
|
||||
<TextBlock Text="三相电流 (A)" FontWeight="Bold" FontSize="13"
|
||||
VerticalAlignment="Center" Margin="0,0,16,0" />
|
||||
<TextBlock Text="A" FontSize="12" Foreground="#E53935" VerticalAlignment="Center" />
|
||||
<TextBlock Text="{Binding CurrentA, StringFormat={}{0:F2}}" FontSize="12"
|
||||
FontWeight="Bold" VerticalAlignment="Center" Margin="3,0,14,0" />
|
||||
<TextBlock Text="B" FontSize="12" Foreground="#43A047" VerticalAlignment="Center" />
|
||||
<TextBlock Text="{Binding CurrentB, StringFormat={}{0:F2}}" FontSize="12"
|
||||
FontWeight="Bold" VerticalAlignment="Center" Margin="3,0,14,0" />
|
||||
<TextBlock Text="C" FontSize="12" Foreground="#1E88E5" VerticalAlignment="Center" />
|
||||
<TextBlock Text="{Binding CurrentC, StringFormat={}{0:F2}}" FontSize="12"
|
||||
FontWeight="Bold" VerticalAlignment="Center" Margin="3,0,0,0" />
|
||||
</StackPanel>
|
||||
<oxy:PlotView Grid.Row="1" Model="{Binding CurrentPlot}"
|
||||
Background="Transparent" Margin="4,0,4,4" />
|
||||
</Grid>
|
||||
</Border>
|
||||
|
||||
<!-- 三相功率 -->
|
||||
<Border Grid.Row="2" Background="White" BorderBrush="#DDD" BorderThickness="1">
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto" />
|
||||
<RowDefinition Height="*" />
|
||||
</Grid.RowDefinitions>
|
||||
<StackPanel Orientation="Horizontal" Margin="10,6">
|
||||
<TextBlock Text="三相功率 (W)" FontWeight="Bold" FontSize="13"
|
||||
VerticalAlignment="Center" Margin="0,0,16,0" />
|
||||
<TextBlock Text="总有功" FontSize="12" Foreground="#616161" VerticalAlignment="Center" />
|
||||
<TextBlock Text="{Binding PowerNow, StringFormat={}{0:F1}}" FontSize="12"
|
||||
FontWeight="Bold" VerticalAlignment="Center" Margin="3,0,14,0" />
|
||||
<TextBlock Text="频率" FontSize="12" Foreground="#616161" VerticalAlignment="Center" />
|
||||
<TextBlock Text="{Binding FrequencyNow, StringFormat={}{0:F2} Hz}" FontSize="12"
|
||||
FontWeight="Bold" VerticalAlignment="Center" Margin="3,0,0,0" />
|
||||
</StackPanel>
|
||||
<oxy:PlotView Grid.Row="1" Model="{Binding PowerPlot}"
|
||||
Background="Transparent" Margin="4,0,4,4" />
|
||||
</Grid>
|
||||
</Border>
|
||||
</Grid>
|
||||
</Grid>
|
||||
</Border>
|
||||
</UserControl>
|
||||
Reference in New Issue
Block a user