| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121 |
- <UserControl
- x:Class="SHJX.Service.Shell.Views.Setting.EquipmentSettingWindow"
- xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
- xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
- xmlns:SettingLibrary="clr-namespace:SHJX.Service.Library.Views.SettingLibrary;assembly=SHJX.Service.Library"
- xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
- xmlns:local="clr-namespace:SHJX.Service.Shell.Views.Setting"
- xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
- xmlns:prism="http://prismlibrary.com/"
- xmlns:pu="clr-namespace:Panuon.UI.Silver;assembly=Panuon.UI.Silver"
- Name="speedControl"
- d:DesignHeight="900"
- d:DesignWidth="800"
- prism:ViewModelLocator.AutoWireViewModel="True"
- mc:Ignorable="d">
- <UserControl.Resources>
- <!--#region Uniform样式-->
- <!-- 下面这段代码不用,不能变成Uniform的样式 -->
- <Style x:Key="ItemContainerStyle" TargetType="{x:Type ListViewItem}">
- <Setter Property="Template">
- <Setter.Value>
- <ControlTemplate TargetType="{x:Type ListViewItem}">
- <Border
- x:Name="Bd"
- Background="{TemplateBinding Background}"
- BorderBrush="{TemplateBinding BorderBrush}"
- BorderThickness="0">
- <ContentPresenter />
- </Border>
- <ControlTemplate.Triggers>
- <Trigger Property="IsSelected" Value="true">
- <Setter TargetName="Bd" Property="Background" Value="Transparent" />
- </Trigger>
- </ControlTemplate.Triggers>
- </ControlTemplate>
- </Setter.Value>
- </Setter>
- </Style>
- <!--#endregion-->
- <DataTemplate x:Key="itemTemplate">
- <SettingLibrary:SpeedControl
- AcSpeed="{Binding AcSpeed}"
- Content="{Binding}"
- DeSpeed="{Binding DeSpeed}"
- HeaderValue="{Binding HeaderValue}"
- SettingSpeedCommand="{Binding ElementName=speedControl, Path=DataContext.SettingSpeedCommand}"
- Speed="{Binding Speed}"
- TagValue="{Binding TagValue}" />
- </DataTemplate>
- </UserControl.Resources>
- <Grid>
- <Grid.RowDefinitions>
- <RowDefinition Height="6*" />
- <RowDefinition Height="6*" />
- <RowDefinition Height="5*" />
- </Grid.RowDefinitions>
- <Grid
- Grid.Row="0"
- HorizontalAlignment="Center"
- VerticalAlignment="Center">
- <GroupBox
- Grid.Row="3"
- Width="700"
- Height="320"
- Margin="0,5,0,5"
- HorizontalAlignment="Center"
- VerticalAlignment="Center"
- pu:GroupBoxHelper.CornerRadius="8"
- pu:GroupBoxHelper.IsSplitLineVisible="True"
- pu:GroupBoxHelper.ShadowColor="LightGray"
- Header="速度设置(*1:主滴定位;2:加液位和副滴定位)">
- <Grid>
- <DataGrid
- Grid.Row="1"
- Width="680"
- Height="260"
- Margin="-5,0,0,0"
- pu:DataGridHelper.ColumnHorizontalContentAlignment="Center"
- pu:DataGridHelper.HeaderMinHeight="45"
- pu:DataGridHelper.HoverBackground="#22B5B5B5"
- pu:DataGridHelper.SelectedBackground="#44B5B5B5"
- CanUserAddRows="False"
- ItemsSource="{Binding MotorSpeeds}">
- <pu:DataGridHelper.AutoGenerateCheckBoxStyle>
- <Style BasedOn="{StaticResource {x:Type CheckBox}}" TargetType="CheckBox">
- <Setter Property="pu:CheckBoxHelper.CheckBoxStyle" Value="Switch" />
- <Style.Triggers>
- <DataTrigger Binding="{Binding Path=(pu:CheckBoxHelper.CheckBoxStyle), RelativeSource={RelativeSource Self}}" Value="Switch">
- <Setter Property="pu:CheckBoxHelper.CheckedBackground" Value="#6452A4" />
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </pu:DataGridHelper.AutoGenerateCheckBoxStyle>
- </DataGrid>
- </Grid>
- </GroupBox>
- </Grid>
- <Grid Grid.Row="1">
- <SettingLibrary:GroupDataGridControl
- DataGridHeight="250"
- DataGridWidth="680"
- GroupBoxHeight="300"
- GroupBoxWidth="700"
- HeaderValue="加液设定(*1:主滴定位;2:加液位和副滴定位)"
- ItemSourceValue="{Binding LiquidVolumes}" />
- </Grid>
- <Grid Grid.Row="2">
- <SettingLibrary:GroupDataGridControl
- DataGridHeight="200"
- DataGridWidth="680"
- GroupBoxHeight="240"
- GroupBoxWidth="700"
- HeaderValue="液体总量"
- ItemSourceValue="{Binding LiquidTotals}" />
- </Grid>
- </Grid>
- </UserControl>
|