<Page x:Class="FLY.Thick.Base.UI.PgInitparam" 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:local="clr-namespace:FLY.Thick.Base.UI" xmlns:common="clr-namespace:FLY.Thick.Base.Common;assembly=FLY.Thick.Base" xmlns:iconPacks="http://metro.mahapps.com/winfx/xaml/iconpacks" xmlns:conv="clr-namespace:FLY.Thick.Base.UI.Converter" mc:Ignorable="d" d:DesignWidth="1280" Title="Page_Initparam" d:DataContext="{d:DesignInstance local:PgInitParamVm}"> <Page.Resources> <ResourceDictionary> <ResourceDictionary.MergedDictionaries> <ResourceDictionary Source="pack://application:,,,/FLY.ControlLibrary;component/Converter/Converters.xaml"/> </ResourceDictionary.MergedDictionaries> <conv:OutSpeed2mpminConverter x:Key="outsp2mpminconv" /> <conv:Pos2mmConverter x:Key="p2mmconv" /> </ResourceDictionary> </Page.Resources> <Grid Background="{StaticResource Brushes.Card.Background}"> <Grid.RowDefinitions> <RowDefinition Height="auto" /> <RowDefinition /> </Grid.RowDefinitions> <StackPanel Orientation="Horizontal" Background="{StaticResource Brushes.TitleBar.Background}"> <Button Style="{StaticResource Styles.TitleBar.BackButton2}" Command="BrowseBack" > <iconPacks:PackIconMaterial Kind="ArrowLeftThick" /> </Button> <TextBlock Style="{StaticResource Styles.TitleBar.Text}" Text="{StaticResource str.PgInitparam.Title}"/> </StackPanel> <ScrollViewer CanContentScroll="False" PanningMode="Both" Grid.Row="1" > <StackPanel Margin="{StaticResource ControlMargin}"> <Border Style="{StaticResource Styles.Card.Border}"> <StackPanel> <TextBlock Style="{StaticResource Styles.Card.Title}" Text="{StaticResource str.PgInitparam.Param}"/> <StackPanel > <StackPanel Orientation="Horizontal"> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.PgInitparam.AutoOrgInterval}" /> <StackPanel Orientation="Horizontal"> <TextBox Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding AutoOrgInterval}" /> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Unit}" Text="min" /> </StackPanel> </StackPanel> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.PgInitparam.PosLength}" /> <StackPanel Orientation="Horizontal"> <TextBox Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding PosLength}" /> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Separator}"/> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Unit}" > <Run> <MultiBinding Converter="{StaticResource p2mmconv}" Mode="OneWay" StringFormat="{}{0:F0}"> <Binding Path="PosLength" /> <Binding Path="Encoder1_mmpp"/> </MultiBinding> </Run> <Run Text="mm"/> </TextBlock> </StackPanel> </StackPanel> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.PgInitparam.mmpp1}" /> <StackPanel Orientation="Horizontal"> <TextBox Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding Encoder1_mmpp}" HorizontalAlignment="Left"/> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Unit}" > mm/<Run Text="{StaticResource str.PgInitparam.Pulse}"/> </TextBlock> </StackPanel> </StackPanel> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.PgInitparam.IsTimeGridAdvEnabled}" /> <ToggleButton Style="{StaticResource Styles.ToggleButton.YESNO}" IsChecked="{Binding IsTimeGridAdvEnabled}"/> </StackPanel> </StackPanel> <StackPanel Orientation="Horizontal"> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.PgInitparam.FilmVSrc}" /> <ComboBox Width="100" MinHeight="{StaticResource FontSize.FieldContent.Middle}" HorizontalAlignment="Left"> <ComboBox.Resources> <Style TargetType="TextBlock" BasedOn="{StaticResource Styles.Text.FieldContent}"> <Setter Property="FontSize" Value="{StaticResource FontSize.FieldContent.Middle}"/> </Style> </ComboBox.Resources> <ComboBoxItem IsSelected="{Binding FilmVSrc, Converter={StaticResource e2bconv}, ConverterParameter={x:Static common:FilmVSRC.EN2}}" > <TextBlock Text="{StaticResource str.PgInitparam.Encoder2}"/> </ComboBoxItem> <ComboBoxItem IsSelected="{Binding FilmVSrc, Converter={StaticResource e2bconv}, ConverterParameter={x:Static common:FilmVSRC.ROUND}}"> <TextBlock Text="{StaticResource str.PgInitparam.Roller}"/> </ComboBoxItem> </ComboBox> </StackPanel> <StackPanel Orientation="Horizontal" Visibility="{Binding IsSelected,Converter={StaticResource visbilityconv},ConverterParameter=Collapsed, ElementName=comboBoxotem_EN2}"> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.PgInitparam.mmpp2}" /> <StackPanel Orientation="Horizontal"> <TextBox Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding Encoder2_mmpp,StringFormat={}{0:F5}}" HorizontalAlignment="Left"/> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Unit}" > mm/<Run Text="{StaticResource str.PgInitparam.Pulse}"/> </TextBlock> </StackPanel> </StackPanel> </StackPanel> <StackPanel Orientation="Horizontal" Visibility="{Binding IsSelected,Converter={StaticResource visbilityconv},ConverterParameter=Collapsed, ElementName=comboBoxotem_ROUND}"> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.PgInitparam.MmOfR}" /> <StackPanel Orientation="Horizontal"> <TextBox HorizontalAlignment="Left" MaxWidth="150" Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding MmOfR,StringFormat={}{0:F1}}" /> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Unit}" Text="mm" /> </StackPanel> </StackPanel> </StackPanel> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.PgInitparam.FilmVThreshold}" /> <StackPanel Orientation="Horizontal"> <TextBox Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding FilmVThreshold}" HorizontalAlignment="Left"/> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Unit}" > <Run Text="m/min"/> </TextBlock> </StackPanel> </StackPanel> </StackPanel> <StackPanel Orientation="Horizontal"> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.PgInitparam.DataValidSrc}" /> <ComboBox Width="100" MinHeight="{StaticResource FontSize.FieldContent.Middle}" HorizontalAlignment="Left"> <ComboBox.Resources> <Style TargetType="TextBlock" BasedOn="{StaticResource Styles.Text.FieldContent}"> <Setter Property="FontSize" Value="{StaticResource FontSize.FieldContent.Middle}"/> </Style> </ComboBox.Resources> <ComboBoxItem IsSelected="{Binding DataValidSrc, Converter={StaticResource e2bconv}, ConverterParameter={x:Static common:DATAVALIDSRC.BYEN2}}"> <TextBlock Text="{StaticResource str.PgInitparam.FilmVelocity}"/> </ComboBoxItem> <ComboBoxItem IsSelected="{Binding DataValidSrc, Converter={StaticResource e2bconv}, ConverterParameter={x:Static common:DATAVALIDSRC.BYINPUT}}"> <TextBlock Text="{StaticResource str.PgInitparam.Input}"/> </ComboBoxItem> <ComboBoxItem IsSelected="{Binding DataValidSrc, Converter={StaticResource e2bconv}, ConverterParameter={x:Static common:DATAVALIDSRC.VALID}}" > <TextBlock Text="{StaticResource str.PgInitparam.VALID}"/> </ComboBoxItem> <ComboBoxItem IsSelected="{Binding DataValidSrc, Converter={StaticResource e2bconv}, ConverterParameter={x:Static common:DATAVALIDSRC.INVALID}}"> <TextBlock Text="{StaticResource str.PgInitparam.INVALID}"/> </ComboBoxItem> </ComboBox> </StackPanel> <StackPanel Orientation="Horizontal"> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable.Row2}" Text="{StaticResource str.PgInitparam.AutoF1F3}" /> <ToggleButton Style="{StaticResource Styles.ToggleButton.YESNO}" IsChecked="{Binding AutoF1F3}" HorizontalAlignment="Left"/> </StackPanel> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable.Row2}" Text="{StaticResource str.PgInitparam.ReStartDelay}" /> <StackPanel Orientation="Horizontal"> <TextBox HorizontalAlignment="Left" MaxWidth="150" Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding ReStartDelay}" /> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Unit}" Text="s" /> </StackPanel> </StackPanel> </StackPanel> </StackPanel> </StackPanel> </StackPanel> </Border> <Border Style="{StaticResource Styles.Card.Border}"> <StackPanel> <TextBlock Style="{StaticResource Styles.Card.Title}" Text="{StaticResource str.PgInitparam.Velocity}"/> <WrapPanel Grid.Column="1" Orientation="Horizontal"> <StackPanel Orientation="Horizontal"> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.PgInitparam.VScan}" /> <StackPanel Orientation="Horizontal"> <TextBox Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding VScan}" HorizontalAlignment="Left"/> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Separator}" /> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Unit}" > <Run> <MultiBinding Converter="{StaticResource outsp2mpminconv}" Mode="OneWay" StringFormat="{}{0:F1}"> <Binding Path="VScan" /> <Binding Path="Encoder1_mmpp" /> <Binding Path="Speed1Scale" /> </MultiBinding> </Run> <Run Text="m/min" /> </TextBlock> </StackPanel> </StackPanel> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.PgInitparam.VAccuracy}" /> <StackPanel Orientation="Horizontal"> <TextBox Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding VAccuracy}" /> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Separator}" /> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Unit}" > <Run> <MultiBinding Converter="{StaticResource outsp2mpminconv}" Mode="OneWay" StringFormat="{}{0:F1}"> <Binding Path="VAccuracy" /> <Binding Path="Encoder1_mmpp" /> <Binding Path="Speed1Scale" /> </MultiBinding> </Run> <Run Text="m/min" /> </TextBlock> </StackPanel> </StackPanel> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.PgInitparam.VJOG}" /> <StackPanel Orientation="Horizontal"> <TextBox Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding VJOG}" /> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Separator}" /> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Unit}" > <Run> <MultiBinding Converter="{StaticResource outsp2mpminconv}" Mode="OneWay" StringFormat="{}{0:F1}"> <Binding Path="VJOG" /> <Binding Path="Encoder1_mmpp" /> <Binding Path="Speed1Scale" /> </MultiBinding> </Run> <Run Text="m/min" /> </TextBlock> </StackPanel> </StackPanel> </StackPanel> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.PgInitparam.SVelocity}" /> <StackPanel Orientation="Horizontal"> <TextBox Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding SVelocity}" /> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Separator}" /> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Unit}" > <Run > <MultiBinding Converter="{StaticResource outsp2mpminconv}" Mode="OneWay" StringFormat="{}{0:F1}"> <Binding Path="SVelocity" /> <Binding Path="Encoder1_mmpp" /> <Binding Path="Speed1Scale" /> </MultiBinding> </Run> <Run Text="m/min" /> </TextBlock> </StackPanel> </StackPanel> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.PgInitparam.HV1}" /> <StackPanel Orientation="Horizontal"> <TextBox Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding HVelocity1}" /> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Separator}" /> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Unit}" > <Run > <MultiBinding Converter="{StaticResource outsp2mpminconv}" Mode="OneWay" StringFormat="{}{0:F1}"> <Binding Path="HVelocity1" /> <Binding Path="Encoder1_mmpp" /> <Binding Path="Speed1Scale" /> </MultiBinding> </Run> <Run Text="m/min" /> </TextBlock> </StackPanel> </StackPanel> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.PgInitparam.HV2}" /> <StackPanel Orientation="Horizontal"> <TextBox Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding HVelocity2}" /> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Separator}" /> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Unit}" > <Run > <MultiBinding Converter="{StaticResource outsp2mpminconv}" Mode="OneWay" StringFormat="{}{0:F1}"> <Binding Path="HVelocity2" /> <Binding Path="Encoder1_mmpp" /> <Binding Path="Speed1Scale" /> </MultiBinding> </Run> <Run Text="m/min" /> </TextBlock> </StackPanel> </StackPanel> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.PgInitparam.ATime}" /> <StackPanel Orientation="Horizontal"> <TextBox Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding ATime}" /> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Unit}" > <Run Text="ms" /> </TextBlock> </StackPanel> </StackPanel> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.PgInitparam.DTime }" /> <StackPanel Orientation="Horizontal"> <TextBox Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding DTime}" /> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Unit}" > <Run Text="ms" /> </TextBlock> </StackPanel> </StackPanel> </WrapPanel> </StackPanel> </Border> <Border Style="{StaticResource Styles.Card.Border}"> <StackPanel> <TextBlock Style="{StaticResource Styles.Card.Title}" Text="{StaticResource str.PgInitparam.Hardware}"/> <WrapPanel Orientation="Horizontal"> <StackPanel Orientation="Horizontal"> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable}" Text="{StaticResource str.PgInitparam.Punch}" /> <ToggleButton Style="{StaticResource Styles.ToggleButton.YESNO}" HorizontalAlignment="Left" IsChecked="{Binding HasPunch}" /> </StackPanel> <StackPanel Margin="{StaticResource ControlMargin}" Visibility="{Binding HasPunch,Converter={StaticResource visbilityconv}}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable.Row2}" Text="{StaticResource str.PgInitparam.PunchOffset}" /> <StackPanel Orientation="Horizontal"> <TextBox HorizontalAlignment="Left" MaxWidth="150" Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding PunchOffset}" /> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Unit}" Text="mm" /> </StackPanel> </StackPanel> </StackPanel> <StackPanel Orientation="Horizontal"> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable.Row2}" Text="{StaticResource str.PgInitparam.HasProfileSample}" /> <ToggleButton Style="{StaticResource Styles.ToggleButton.YESNO}" HorizontalAlignment="Left" IsChecked="{Binding HasProfileSample}" /> </StackPanel> </StackPanel> <StackPanel Orientation="Horizontal"> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable.Row2}" Text="{StaticResource str.PgInitparam.HasVSign}" /> <ToggleButton Style="{StaticResource Styles.ToggleButton.YESNO}" HorizontalAlignment="Left" IsChecked="{Binding HasVSign}" /> </StackPanel> <StackPanel Margin="{StaticResource ControlMargin}" Visibility="{Binding HasVSign,Converter={StaticResource visbilityconv}}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable.Row2}" Text="{StaticResource str.PgInitparam.VSignOffset}" /> <StackPanel Orientation="Horizontal"> <TextBox HorizontalAlignment="Left" MaxWidth="150" Style="{StaticResource Styles.Text.FieldContent.Input.Card}" Text="{Binding VSignOffset}" /> <TextBlock Style="{StaticResource Styles.Text.FieldContent.Unit}" Text="mm" /> </StackPanel> </StackPanel> </StackPanel> <StackPanel Orientation="Horizontal"> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable.Row2}" Text="{StaticResource str.PgInitparam.HasHSign}" /> <ToggleButton Style="{StaticResource Styles.ToggleButton.YESNO}" HorizontalAlignment="Left" IsChecked="{Binding HasHSign}" /> </StackPanel> </StackPanel> <StackPanel Orientation="Horizontal"> <StackPanel Margin="{StaticResource ControlMargin}"> <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable.Row2}" Text="{StaticResource str.PgInitparam.HasScanCorr}" /> <ToggleButton Style="{StaticResource Styles.ToggleButton.YESNO}" HorizontalAlignment="Left" IsChecked="{Binding HasScanCorr}" /> </StackPanel> </StackPanel> </WrapPanel> </StackPanel> </Border> </StackPanel> </ScrollViewer> <Button Style="{StaticResource Styles.Button.Apply}" VerticalAlignment="Bottom" Margin="0,0,20,20" Command="{Binding ApplyCmd}"/> </Grid> </Page>