93 lines
5.5 KiB
Plaintext
93 lines
5.5 KiB
Plaintext
|
|
<Window x:Class="SSPCTester.UI.Views.CurvePopupWindow"
|
|||
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|||
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|||
|
|
xmlns:ctl="clr-namespace:SSPCTester.UI.Controls"
|
|||
|
|
xmlns:vm="clr-namespace:SSPCTester.UI.ViewModels"
|
|||
|
|
Title="曲线查看器"
|
|||
|
|
Width="1100" Height="720"
|
|||
|
|
MinWidth="600" MinHeight="400"
|
|||
|
|
WindowStartupLocation="CenterOwner"
|
|||
|
|
Background="{StaticResource BgAppBrush}"
|
|||
|
|
d:DataContext="{d:DesignInstance Type=vm:CurveTestViewModel}"
|
|||
|
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
|||
|
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|||
|
|
mc:Ignorable="d">
|
|||
|
|
<Grid Margin="16">
|
|||
|
|
<Grid.RowDefinitions>
|
|||
|
|
<RowDefinition Height="Auto" />
|
|||
|
|
<RowDefinition Height="*" />
|
|||
|
|
<RowDefinition Height="*" />
|
|||
|
|
</Grid.RowDefinitions>
|
|||
|
|
|
|||
|
|
<Grid Margin="0,0,0,12">
|
|||
|
|
<Grid.ColumnDefinitions>
|
|||
|
|
<ColumnDefinition Width="*" />
|
|||
|
|
<ColumnDefinition Width="Auto" />
|
|||
|
|
<ColumnDefinition Width="Auto" />
|
|||
|
|
</Grid.ColumnDefinitions>
|
|||
|
|
<TextBlock VerticalAlignment="Center" FontSize="{StaticResource FsH1}" FontWeight="Bold">
|
|||
|
|
<Run Text="曲线查看器 " />
|
|||
|
|
<Run Text="CH" Foreground="{StaticResource TextSecondaryBrush}" />
|
|||
|
|
<Run Text="{Binding SelectedChannel, Mode=OneWay}" Foreground="{StaticResource PrimaryBrush}" />
|
|||
|
|
</TextBlock>
|
|||
|
|
<ComboBox Grid.Column="1" Width="120" Margin="0,0,8,0"
|
|||
|
|
ItemsSource="{Binding Channels}" SelectedItem="{Binding SelectedChannel}" />
|
|||
|
|
<Button Grid.Column="2" Content="关闭" Width="80" IsCancel="True" Click="Close_Click" />
|
|||
|
|
</Grid>
|
|||
|
|
|
|||
|
|
<Border Grid.Row="1" Style="{StaticResource Card}" Margin="0,0,0,6">
|
|||
|
|
<DockPanel>
|
|||
|
|
<Grid DockPanel.Dock="Top">
|
|||
|
|
<Grid.ColumnDefinitions>
|
|||
|
|
<ColumnDefinition Width="*" />
|
|||
|
|
<ColumnDefinition Width="Auto" />
|
|||
|
|
</Grid.ColumnDefinitions>
|
|||
|
|
<TextBlock Style="{StaticResource CardTitle}" Text="开启曲线(电压上升,90% 阈值)" />
|
|||
|
|
<StackPanel Grid.Column="1" Orientation="Horizontal" VerticalAlignment="Center">
|
|||
|
|
<TextBlock Text="起点" VerticalAlignment="Center" Margin="0,0,4,0" />
|
|||
|
|
<TextBox Width="64" Height="26" Margin="0,0,8,0" Padding="4,0"
|
|||
|
|
Text="{Binding RisingViewStartMs, UpdateSourceTrigger=PropertyChanged, TargetNullValue=''}"
|
|||
|
|
FontFamily="{StaticResource FontMono}" />
|
|||
|
|
<TextBlock Text="终点" VerticalAlignment="Center" Margin="0,0,4,0" />
|
|||
|
|
<TextBox Width="64" Height="26" Margin="0,0,8,0" Padding="4,0"
|
|||
|
|
Text="{Binding RisingViewEndMs, UpdateSourceTrigger=PropertyChanged, TargetNullValue=''}"
|
|||
|
|
FontFamily="{StaticResource FontMono}" />
|
|||
|
|
<Button Content="默认" Width="54" Height="26" Padding="0"
|
|||
|
|
Command="{Binding ResetRisingViewCommand}" />
|
|||
|
|
</StackPanel>
|
|||
|
|
</Grid>
|
|||
|
|
<ctl:CurvePlotControl Curve="{Binding RisingCurve}" IsRising="True" VMax="{Binding VMax}"
|
|||
|
|
ViewStartMs="{Binding RisingViewStartMs}"
|
|||
|
|
ViewEndMs="{Binding RisingViewEndMs}" />
|
|||
|
|
</DockPanel>
|
|||
|
|
</Border>
|
|||
|
|
|
|||
|
|
<Border Grid.Row="2" Style="{StaticResource Card}" Margin="0,6,0,0">
|
|||
|
|
<DockPanel>
|
|||
|
|
<Grid DockPanel.Dock="Top">
|
|||
|
|
<Grid.ColumnDefinitions>
|
|||
|
|
<ColumnDefinition Width="*" />
|
|||
|
|
<ColumnDefinition Width="Auto" />
|
|||
|
|
</Grid.ColumnDefinitions>
|
|||
|
|
<TextBlock Style="{StaticResource CardTitle}" Text="关断曲线(电压下降,10% 阈值)" />
|
|||
|
|
<StackPanel Grid.Column="1" Orientation="Horizontal" VerticalAlignment="Center">
|
|||
|
|
<TextBlock Text="起点" VerticalAlignment="Center" Margin="0,0,4,0" />
|
|||
|
|
<TextBox Width="64" Height="26" Margin="0,0,8,0" Padding="4,0"
|
|||
|
|
Text="{Binding FallingViewStartMs, UpdateSourceTrigger=PropertyChanged, TargetNullValue=''}"
|
|||
|
|
FontFamily="{StaticResource FontMono}" />
|
|||
|
|
<TextBlock Text="终点" VerticalAlignment="Center" Margin="0,0,4,0" />
|
|||
|
|
<TextBox Width="64" Height="26" Margin="0,0,8,0" Padding="4,0"
|
|||
|
|
Text="{Binding FallingViewEndMs, UpdateSourceTrigger=PropertyChanged, TargetNullValue=''}"
|
|||
|
|
FontFamily="{StaticResource FontMono}" />
|
|||
|
|
<Button Content="默认" Width="54" Height="26" Padding="0"
|
|||
|
|
Command="{Binding ResetFallingViewCommand}" />
|
|||
|
|
</StackPanel>
|
|||
|
|
</Grid>
|
|||
|
|
<ctl:CurvePlotControl Curve="{Binding FallingCurve}" IsRising="False" VMax="{Binding VMax}"
|
|||
|
|
ViewStartMs="{Binding FallingViewStartMs}"
|
|||
|
|
ViewEndMs="{Binding FallingViewEndMs}" />
|
|||
|
|
</DockPanel>
|
|||
|
|
</Border>
|
|||
|
|
</Grid>
|
|||
|
|
</Window>
|