900 lines
55 KiB
XML
900 lines
55 KiB
XML
<UserControl x:Class="PartPageV"
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:local="clr-namespace:EgtDOORCreator"
|
|
xmlns:EgtDOORCreator="clr-namespace:EgtDOORCreator"
|
|
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5">
|
|
|
|
<UserControl.Resources>
|
|
<EgtDOORCreator:SplitConverter x:Key="SplitConverter"/>
|
|
<local:DoorVisibilityConverter x:Key="DoorVisibilityConverter"/>
|
|
<local:TemplateListConverter x:Key="TemplateListConverter"/>
|
|
<EgtDOORCreator:TrueToFalse x:Key="TrueToFalse"/>
|
|
</UserControl.Resources>
|
|
|
|
<Grid IsEnabled="{Binding EnablePageDoor}">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="5*"/>
|
|
</Grid.ColumnDefinitions>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="1*"/>
|
|
</Grid.RowDefinitions>
|
|
|
|
<Grid Margin="0,0,0,0.2" Grid.Column="1" IsEnabled="{Binding IsReadOnly}">
|
|
<Grid.InputBindings>
|
|
<KeyBinding Key="Enter" Command="{Binding DataContext.RefreshCmd,RelativeSource={RelativeSource AncestorType={x:Type UserControl}}}"/>
|
|
<KeyBinding Key="F1" Command="{Binding DataContext.GuideCmd,RelativeSource={RelativeSource AncestorType={x:Type UserControl}}}"/>
|
|
</Grid.InputBindings>
|
|
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="Auto"/>
|
|
<RowDefinition Height="1*"/>
|
|
</Grid.RowDefinitions>
|
|
|
|
<!--<GroupBox Header="{Binding GeneralMsg}" Margin="0,0,0,0"
|
|
Visibility="{Binding CurrProject.DoorList,
|
|
Converter={StaticResource DoorVisibilityConverter}}">-->
|
|
<GroupBox>
|
|
<GroupBox.Header>
|
|
<StackPanel Orientation="Horizontal">
|
|
<TextBlock Text="{Binding GeneralMsg}" Width="Auto"/>
|
|
<Button Grid.Column="4" Grid.ColumnSpan="2" Grid.Row="5"
|
|
VerticalAlignment="Stretch"
|
|
Height="Auto"
|
|
Padding="2,0,2,2"
|
|
Margin="5,0,0,0"
|
|
Visibility="{Binding OrderButtonVisibility}"
|
|
Content="Order" Command="{Binding OrderCmd}"/>
|
|
</StackPanel>
|
|
</GroupBox.Header>
|
|
<Grid>
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="Auto"/>
|
|
<ColumnDefinition Width="Auto"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
</Grid.ColumnDefinitions>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="1*"/>
|
|
<RowDefinition Height="1*"/>
|
|
<RowDefinition Height="1*"/>
|
|
<RowDefinition Height="1*"/>
|
|
<RowDefinition Height="1*"/>
|
|
<RowDefinition Height="1*"/>
|
|
<RowDefinition Height="Auto"/>
|
|
<RowDefinition Height="Auto"/>
|
|
</Grid.RowDefinitions>
|
|
|
|
<Border BorderBrush="Gainsboro" BorderThickness="1" Grid.Column="2" Grid.ColumnSpan="5"
|
|
Grid.RowSpan="5" Margin="5,-2,2,0" CornerRadius="3"/>
|
|
<TextBlock Grid.Column="3" Grid.Row="0" Text="{Binding EdgeMsg}" VerticalAlignment="Center"
|
|
Style="{StaticResource DoorParamsTxBl}" Margin="2,0,5,0"/>
|
|
<TextBlock Grid.Column="4" Grid.Row="0" Text="{Binding ResizeMsg}" VerticalAlignment="Center"
|
|
Style="{StaticResource DoorParamsTxBl}" Margin="-10,0,0,0"
|
|
Visibility="Collapsed"/>
|
|
<TextBlock Grid.Column="5" Grid.Row="0" Text="{Binding MachMsg}" VerticalAlignment="Center"
|
|
Style="{StaticResource DoorParamsTxBl}" />
|
|
<TextBlock Grid.Column="6" Grid.Row="0" Text="{Binding OverMaterialMsg}" VerticalAlignment="Center"
|
|
Style="{StaticResource DoorParamsTxBl}" Margin="10,0,5,0" MaxWidth="120"/>
|
|
|
|
<!--General-->
|
|
<!--Margin="0.4,2,39.6,3.2"-->
|
|
<TextBlock Text="{Binding WidthMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="2,2,0,2"
|
|
Grid.Row="0"/>
|
|
<TextBox Grid.Column="1" Grid.Row="0"
|
|
Style="{StaticResource DoorParamsTxBx}"
|
|
Text="{Binding CurrPart.Width, UpdateSourceTrigger=PropertyChanged}"
|
|
ToolTip="{Binding CurrPart.ToolTipEvaluatedWidth}"
|
|
MaxWidth="120" Margin="0.4,2,10,3.2"
|
|
VerticalAlignment="Stretch"
|
|
Height="Auto" IsReadOnly="{Binding DisableWidth}"/>
|
|
|
|
<TextBlock Grid.Row="1" Text="{Binding HeightMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="2,0,0,2"/>
|
|
<TextBox Grid.Column="1" Grid.Row="1" Style="{StaticResource DoorParamsTxBx}"
|
|
Text="{Binding CurrPart.Height, UpdateSourceTrigger=PropertyChanged}"
|
|
MaxWidth="120" Margin="0.4,2,10,3.2"
|
|
VerticalAlignment="Stretch" Height="Auto"
|
|
ToolTip="{Binding CurrPart.ToolTipEvaluatedHeight}"
|
|
IsReadOnly="{Binding DisableHeight}"/>
|
|
|
|
<TextBlock Grid.Row="2" Text="{Binding ThicknessMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="2,0,0,2"/>
|
|
<TextBox Grid.Column="1" Grid.Row="2" Style="{StaticResource DoorParamsTxBx}"
|
|
Text="{Binding CurrPart.Thickness, UpdateSourceTrigger=PropertyChanged}"
|
|
MaxWidth="120" Margin="0.4,2,10,3.2"
|
|
VerticalAlignment="Stretch" Height="Auto"
|
|
ToolTip="{Binding CurrPart.ToolTipEvaluatedThickness}"
|
|
IsReadOnly="{Binding IsRaedOnly}"/>
|
|
|
|
<TextBlock Grid.Row="3" Text="{Binding SwingMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="2,0,0,2"/>
|
|
<ComboBox Grid.Column="1" Grid.Row="3"
|
|
MaxWidth="120" Margin="0.4,2,10,3.2"
|
|
ItemsSource="{Binding CurrPart.SwingTypeList}"
|
|
SelectedItem="{Binding CurrPart.Swing}"
|
|
Style="{StaticResource DoorParamsCmBx}" Height="Auto"
|
|
IsEnabled="{Binding IsRaedOnly, Converter={StaticResource TrueToFalse}}"/>
|
|
|
|
<TextBlock Grid.Row="4" Text="{Binding WeightMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="2,0,0,2" Visibility="{Binding CurrPart.VisibilityWeight}"/>
|
|
|
|
<TextBox Grid.Row="4" Grid.Column="1"
|
|
Style="{StaticResource DoorParamsTxBx}"
|
|
Text="{Binding CurrPart.Weight, UpdateSourceTrigger=PropertyChanged}"
|
|
ToolTip="{Binding CurrPart.ToolTipEvaluatedWeight}"
|
|
MaxWidth="120" Margin="0.4,2,10,3.2"
|
|
VerticalAlignment="Stretch" Height="Auto"
|
|
Visibility="{Binding CurrPart.VisibilityWeight}"
|
|
IsReadOnly="{Binding IsRaedOnly}"/>
|
|
|
|
<!--Seconda colonna -->
|
|
<!-- Profiles-->
|
|
<TextBlock Grid.Column="2" Grid.Row="1" Text="{Binding LockedgeMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="20,2,0,2"/>
|
|
<ComboBox Grid.Column="3" Grid.Row="1"
|
|
ItemsSource="{Binding CurrPart.LockEdgeTypeList}"
|
|
SelectedItem="{Binding CurrPart.LockEdgeType}"
|
|
Style="{StaticResource DoorEdgeParamsCmBx}"
|
|
Margin="0.4,2,30,4"
|
|
IsEnabled="{Binding IsRaedOnly, Converter={StaticResource TrueToFalse}}"/>
|
|
|
|
<TextBlock Grid.Column="2" Grid.Row="2"
|
|
Text="{Binding HingeedgeMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="20,2,0,2"/>
|
|
<ComboBox Grid.Column="3" Grid.Row="2"
|
|
ItemsSource="{Binding CurrPart.HingeEdgeTypeList}"
|
|
SelectedItem="{Binding CurrPart.HingeEdgeType}"
|
|
Style="{StaticResource DoorEdgeParamsCmBx}"
|
|
Margin="0.4,2,30,4"
|
|
IsEnabled="{Binding IsRaedOnly, Converter={StaticResource TrueToFalse}}"/>
|
|
|
|
|
|
<TextBlock Grid.Column="2" Grid.Row="3"
|
|
Text="{Binding TopMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="20,2,0,2"/>
|
|
<ComboBox Grid.Column="3" Grid.Row="3"
|
|
ItemsSource="{Binding CurrPart.TopEdgeTypeList}"
|
|
SelectedItem="{Binding CurrPart.TopType}"
|
|
Style="{StaticResource DoorEdgeParamsCmBx}"
|
|
Margin="0.4,2,30,4"
|
|
IsEnabled="{Binding IsRaedOnly, Converter={StaticResource TrueToFalse}}"/>
|
|
|
|
<TextBlock Grid.Row="4" Grid.Column="2"
|
|
Text="{Binding BottomMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="20,2,0,2"/>
|
|
<ComboBox Grid.Column="3" Grid.Row="4"
|
|
ItemsSource="{Binding CurrPart.BottomEdgeTypeList}"
|
|
SelectedItem="{Binding CurrPart.BottomType}"
|
|
Style="{StaticResource DoorEdgeParamsCmBx}"
|
|
Margin="0.4,2,30,4"
|
|
IsEnabled="{Binding IsRaedOnly, Converter={StaticResource TrueToFalse}}"/>
|
|
|
|
<!--<TextBlock Grid.Row="5" Grid.Column="2"
|
|
Visibility="{Binding DispositionVisibility}"
|
|
Text="{Binding DispositionMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="20,2,0,2"/>-->
|
|
|
|
<!--Resize-->
|
|
<CheckBox Grid.Column="4" Grid.Row="1" Grid.RowSpan="2"
|
|
IsChecked="{Binding CurrPart.ResizeLockHinge}"
|
|
Name="LockHingeEdge"
|
|
Margin="0,0,20,0"
|
|
Style="{StaticResource DoorParamsChBx}"
|
|
Visibility="Collapsed"/>
|
|
<CheckBox Grid.Column="4" Grid.Row="3" Grid.RowSpan="2"
|
|
IsChecked="{Binding CurrPart.ResizeTopBottom}"
|
|
Name="TopBottomEdge"
|
|
Margin="0,0,20,0"
|
|
Style="{StaticResource DoorParamsChBx}"
|
|
Visibility="Collapsed"/>
|
|
<!--Machining-->
|
|
<CheckBox Grid.Column="5" Grid.Row="1"
|
|
Name="LockEdge" Style="{StaticResource DoorParamsChBx}"
|
|
IsChecked="{Binding CurrPart.LockEdgeMachining}"
|
|
IsEnabled="{Binding IsRaedOnly, Converter={StaticResource TrueToFalse}}"/>
|
|
<CheckBox Grid.Column="5" Grid.Row="2"
|
|
Name="HingeEdge" Style="{StaticResource DoorParamsChBx}"
|
|
IsChecked="{Binding CurrPart.HingeEdgeMachining}"
|
|
IsEnabled="{Binding IsRaedOnly, Converter={StaticResource TrueToFalse}}"/>
|
|
<CheckBox Grid.Column="5" Grid.Row="3"
|
|
Name="Top" Style="{StaticResource DoorParamsChBx}"
|
|
IsChecked="{Binding CurrPart.TopMachining}"
|
|
IsEnabled="{Binding IsRaedOnly, Converter={StaticResource TrueToFalse}}"/>
|
|
<CheckBox Grid.Column="5" Grid.Row="4"
|
|
Name="Bottom" Style="{StaticResource DoorParamsChBx}"
|
|
IsChecked="{Binding CurrPart.BottomMachining}"
|
|
IsEnabled="{Binding IsRaedOnly, Converter={StaticResource TrueToFalse}}"/>
|
|
|
|
<!--<CheckBox Grid.Column="5" Grid.Row="5"
|
|
Visibility="{Binding CurrPart.VisibilityInvertBevel}"
|
|
Name="InvertBevel" Style="{StaticResource DoorParamsChBx}"
|
|
IsChecked="{Binding CurrPart.InvertBevel}"
|
|
Margin="0,2,0,4"
|
|
IsEnabled="{Binding IsInactive}"/>
|
|
<TextBlock Grid.Row="5" Grid.Column="6"
|
|
Visibility="{Binding CurrPart.VisibilityInvertBevel}"
|
|
Text="{Binding InvertBevelMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
MaxWidth="120" Margin="10,2,10,4"/>-->
|
|
<!--<ComboBox Grid.Column="3" Grid.Row="5"
|
|
Visibility="{Binding DispositionVisibility}"
|
|
ItemsSource="{Binding CurrPart.DispositionList}"
|
|
SelectedItem="{Binding CurrPart.DispositionItem}"
|
|
DisplayMemberPath="Name"
|
|
Style="{StaticResource DoorEdgeParamsCmBx}"
|
|
Margin="0.4,2,30,4"
|
|
IsEnabled="{Binding IsRaedOnly, Converter={StaticResource TrueToFalse}}"/>-->
|
|
|
|
<TextBox Grid.Column="6" Grid.Row="1" Style="{StaticResource DoorParamsTxBx}"
|
|
Text="{Binding CurrPart.LockEdgeOverMaterial, UpdateSourceTrigger=PropertyChanged}"
|
|
IsEnabled="{Binding IsChecked, ElementName=LockEdge}"
|
|
ToolTip="{Binding CurrPart.ToolTipEvaluatedLockOverMaterial}"
|
|
MaxWidth="120" Margin="10,2,20,4"
|
|
IsReadOnly="{Binding IsRaedOnly}"/>
|
|
<TextBox Grid.Column="6" Grid.Row="2" Style="{StaticResource DoorParamsTxBx}"
|
|
Text="{Binding CurrPart.HingeEdgeOverMaterial, UpdateSourceTrigger=PropertyChanged}"
|
|
IsEnabled="{Binding IsChecked, ElementName=HingeEdge}"
|
|
ToolTip="{Binding CurrPart.ToolTipEvaluatedHingeOverMaterial}"
|
|
MaxWidth="120" Margin="10,2,20,4"
|
|
IsReadOnly="{Binding IsRaedOnly}"/>
|
|
<TextBox Grid.Column="6" Grid.Row="3" Style="{StaticResource DoorParamsTxBx}"
|
|
Text="{Binding CurrPart.TopOverMaterial, UpdateSourceTrigger=PropertyChanged}"
|
|
IsEnabled="{Binding IsChecked, ElementName=Top}"
|
|
ToolTip="{Binding CurrPart.ToolTipEvaluatedTopOverMaterial}"
|
|
MaxWidth="120" Margin="10,2,20,4"
|
|
IsReadOnly="{Binding IsReadOnly}"/>
|
|
<TextBox Grid.Column="6" Grid.Row="4" Style="{StaticResource DoorParamsTxBx}"
|
|
Text="{Binding CurrPart.BottomOverMaterial, UpdateSourceTrigger=PropertyChanged}"
|
|
IsEnabled="{Binding IsChecked, ElementName=Bottom}"
|
|
ToolTip="{Binding CurrPart.ToolTipEvaluatedBottomOverMaterial}"
|
|
MaxWidth="120" Margin="10,2,20,4"
|
|
IsReadOnly="{Binding IsRaedOnly}"/>
|
|
<!--Margin="10,2,40,4"-->
|
|
|
|
<!--Material and properties-->
|
|
<!--Visibility="{Binding CurrPart.PropertiesIsVisible}"-->
|
|
<!--<Grid Margin="0,0,0,2" Grid.Column="2" Grid.ColumnSpan="5" Grid.Row="5">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="Auto"/>
|
|
</Grid.ColumnDefinitions>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="1*"/>
|
|
<RowDefinition Height="1*"/>
|
|
<RowDefinition Height="1*"/>
|
|
</Grid.RowDefinitions>-->
|
|
|
|
<GroupBox Grid.Column="2" Grid.ColumnSpan="5" Grid.Row="5" Margin="2,0,2,0" BorderBrush="White">
|
|
<GroupBox.Header>
|
|
<StackPanel Orientation="Horizontal">
|
|
<CheckBox Grid.Row="0" Grid.Column="5"
|
|
Visibility="{Binding AllignGropBox}"
|
|
Style="{StaticResource DoorParamsChBx}"
|
|
VerticalAlignment="Stretch"
|
|
Margin="2,0,0.2,0"
|
|
IsEnabled="{Binding IsRaedOnly, Converter={StaticResource TrueToFalse}}"/>
|
|
<ComboBox Style="{StaticResource DoorParamsCmBx}" Width="100"
|
|
Visibility="{Binding AllignGropBox}"
|
|
VerticalAlignment="Stretch" Height="Auto"
|
|
Margin="2,0,0,0" IsEnabled="{Binding IsRaedOnly, Converter={StaticResource TrueToFalse}}"/>
|
|
</StackPanel>
|
|
</GroupBox.Header>
|
|
|
|
<Grid Margin="0,0,0,0" Grid.Column="2" Grid.ColumnSpan="5" Grid.Row="5">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="Auto"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
</Grid.ColumnDefinitions>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="1*"/>
|
|
<RowDefinition Height="1*"/>
|
|
</Grid.RowDefinitions>
|
|
|
|
<TextBlock Grid.Column="0" Grid.Row="0"
|
|
Visibility="{Binding DispositionVisibility}"
|
|
Text="{Binding DispositionMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="12,2,5,2" />
|
|
<ComboBox Grid.Column="1" Grid.Row="0"
|
|
Visibility="{Binding DispositionVisibility}"
|
|
ItemsSource="{Binding CurrPart.DispositionList}"
|
|
SelectedItem="{Binding CurrPart.DispositionItem}"
|
|
DisplayMemberPath="Name"
|
|
Style="{StaticResource DoorEdgeParamsCmBx}"
|
|
MaxWidth="120" Margin="-7,0,38,0"
|
|
IsEnabled="{Binding IsRaedOnly, Converter={StaticResource TrueToFalse}}"/>
|
|
<CheckBox Grid.Column="2" Grid.Row="0"
|
|
Margin="0,0,0,0"
|
|
Visibility="{Binding CurrPart.VisibilityInvertBevel}"
|
|
Name="InvertBevel" Style="{StaticResource DoorParamsChBx}"
|
|
IsChecked="{Binding CurrPart.InvertBevel}"
|
|
IsEnabled="{Binding IsInactive}"/>
|
|
<TextBlock Grid.Column="3" Grid.Row="0"
|
|
Visibility="{Binding CurrPart.VisibilityInvertBevel}"
|
|
Text="{Binding InvertBevelMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
MaxWidth="120" Margin="18,0,12,0"/>
|
|
|
|
<!--materieli-->
|
|
<TextBlock Grid.Column="0" Grid.Row="1"
|
|
Visibility="{Binding Visibility, ElementName=Material}"
|
|
Text="{Binding MaterialMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="12,2,0,0" />
|
|
<!--Solo se senza materiali allora stampo questo messaggio-->
|
|
<TextBlock Grid.Column="1" Grid.Row="1"
|
|
Visibility="{Binding CurrPart.ShowPropeperty}"
|
|
Text="{Binding PropertyMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="12,0,5,0" />
|
|
<!--Lista materiali-->
|
|
<ComboBox Grid.Column="1" Grid.Row="1"
|
|
MaxWidth="120" Margin="-7,0,38,0"
|
|
Style="{StaticResource DoorEdgeParamsCmBx}"
|
|
Name="Material"
|
|
Visibility="{Binding CurrPart.MaterialIsVisible}"
|
|
ItemsSource="{Binding CurrPart.MaterialsList}"
|
|
SelectedItem="{Binding CurrPart.SelectedMaterial}"
|
|
IsEnabled="{Binding IsRaedOnly, Converter={StaticResource TrueToFalse}}"
|
|
DisplayMemberPath="Name">
|
|
</ComboBox>
|
|
<!--lLsta proprietà-->
|
|
<ComboBox Grid.Column="3" Grid.Row="1"
|
|
MaxWidth="120" Margin="18,0,12,0"
|
|
Style="{StaticResource DoorEdgeParamsCmBx}"
|
|
Visibility="{Binding CurrPart.PropertiesIsVisible}"
|
|
ItemsSource="{Binding CurrPart.PropertiesList}"
|
|
SelectedItem="{Binding CurrPart.SelectedProperty}"
|
|
IsEnabled="{Binding IsRaedOnly, Converter={StaticResource TrueToFalse}}"
|
|
DisplayMemberPath="GraphicName">
|
|
</ComboBox>
|
|
</Grid>
|
|
</GroupBox>
|
|
|
|
<Grid Margin="0,0,0,0.1" Grid.Row="5" Grid.ColumnSpan="4" Visibility="{Binding VisibilityTopShape}">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
</Grid.ColumnDefinitions>
|
|
|
|
<!--TopArc-->
|
|
<GroupBox Grid.Row="6" Margin="2,0,2,0">
|
|
<GroupBox.Header>
|
|
<StackPanel Orientation="Horizontal">
|
|
<CheckBox Grid.Row="0" Grid.Column="5"
|
|
Name="TopShape"
|
|
Style="{StaticResource DoorParamsChBx}"
|
|
IsChecked="{Binding CurrPart.TopShapeIsChecked}"
|
|
VerticalAlignment="Stretch"
|
|
IsEnabled="{Binding IsRaedOnly, Converter={StaticResource TrueToFalse}}"
|
|
Margin="2,0,0.2,0"/>
|
|
<ComboBox Style="{StaticResource DoorParamsCmBx}" Width="100"
|
|
ItemsSource="{Binding CurrPart.TopShapeList}"
|
|
SelectedItem="{Binding CurrPart.SelectedShape}"
|
|
VerticalAlignment="Stretch" Height="Auto"
|
|
Margin="2,0,0,0"
|
|
IsEnabled="{Binding IsRaedOnly, Converter={StaticResource TrueToFalse}}"
|
|
DisplayMemberPath="Name"/>
|
|
</StackPanel>
|
|
</GroupBox.Header>
|
|
|
|
<Grid Margin="0,0,0,0" IsEnabled="{Binding IsChecked, ElementName=TopShape}">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
</Grid.ColumnDefinitions>
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="1*"/>
|
|
<RowDefinition Height="1*"/>
|
|
</Grid.RowDefinitions>
|
|
<!--TopArc-->
|
|
<TextBlock Grid.Column="0" Grid.ColumnSpan="2"
|
|
Visibility="{Binding CurrPart.VisibilityTopArch}"
|
|
Text="{Binding RadiusMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="2,2,0,2"/>
|
|
<TextBox Grid.Column="1" Grid.ColumnSpan="2"
|
|
Visibility="{Binding CurrPart.VisibilityTopArch}"
|
|
Style="{StaticResource DoorParamsTxBx}"
|
|
Text="{Binding CurrPart.Radius, UpdateSourceTrigger=PropertyChanged}"
|
|
ToolTip="{Binding CurrPart.ToolTipEvaluatedRadius}"
|
|
MaxWidth="120" Margin="0.4,2,1,2"
|
|
IsReadOnly="{Binding IsRaedOnly}"/>
|
|
<TextBlock Grid.Column="0" Grid.Row="1" Grid.ColumnSpan="2"
|
|
Visibility="{Binding CurrPart.VisibilityTopArch}"
|
|
Text="{Binding PosxMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="2,2,0,2"/>
|
|
<TextBox Grid.Column="1" Grid.Row="1" Grid.ColumnSpan="2"
|
|
Visibility="{Binding CurrPart.VisibilityTopArch}"
|
|
Style="{StaticResource DoorParamsTxBx}"
|
|
Text="{Binding CurrPart.Posx, UpdateSourceTrigger=PropertyChanged}"
|
|
ToolTip="{Binding CurrPart.ToolTipEvaluatedPosx}"
|
|
MaxWidth="120" Margin="0.4,2,1,2"
|
|
IsReadOnly="{Binding IsRaedOnly}"/>
|
|
<!--TopAngle-->
|
|
<!--Margin="0.4,2,10.6,3.2"-->
|
|
<TextBlock Grid.Column="0" Grid.ColumnSpan="2"
|
|
Visibility="{Binding CurrPart.VisibilityTopAngle}"
|
|
Text="{Binding AngleMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="2,2,0,2"/>
|
|
<TextBox Grid.Column="2" Grid.ColumnSpan="2"
|
|
Visibility="{Binding CurrPart.VisibilityTopAngle}"
|
|
Style="{StaticResource DoorParamsTxBx}"
|
|
Text="{Binding CurrPart.Angle, UpdateSourceTrigger=PropertyChanged}"
|
|
ToolTip="{Binding CurrPart.Angle}"
|
|
MaxWidth="120" Margin="0.4,0,1,0"
|
|
IsReadOnly="{Binding IsRaedOnly}"/>
|
|
<TextBlock Grid.Column="0" Grid.Row="1" Grid.ColumnSpan="2"
|
|
Visibility="{Binding CurrPart.VisibilityTopAngle}"
|
|
Text="{Binding PosxMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="2,2,0,0.2"/>
|
|
<TextBox Grid.Column="2" Grid.Row="1" Grid.ColumnSpan="2"
|
|
Visibility="{Binding CurrPart.VisibilityTopAngle}"
|
|
Style="{StaticResource DoorParamsTxBx}"
|
|
Text="{Binding CurrPart.PosxAngle, UpdateSourceTrigger=PropertyChanged}"
|
|
ToolTip="{Binding CurrPart.ToolTipEvaluatedPosxAngle}"
|
|
MaxWidth="120" Margin="0.4,0,1,0"
|
|
IsReadOnly="{Binding IsRaedOnly}"/>
|
|
</Grid>
|
|
</GroupBox>
|
|
|
|
<!--TopArc--><!--
|
|
<GroupBox Grid.Row="6" Margin="2,0,2,0">
|
|
<GroupBox.Header>
|
|
<StackPanel Orientation="Horizontal">
|
|
<CheckBox Grid.Row="0" Grid.Column="5"
|
|
Name="TopArc"
|
|
Style="{StaticResource DoorParamsChBx}"
|
|
IsChecked="{Binding CurrPart.TopArcIsChecked}"
|
|
Margin="0,0,2,0" VerticalAlignment="Stretch" Height="Auto"/>
|
|
<TextBlock Text="{Binding TopArcMsg}" Width="Auto"/>
|
|
</StackPanel>
|
|
</GroupBox.Header>
|
|
|
|
<Grid Margin="0,0,0,2" IsEnabled="{Binding IsChecked, ElementName=TopArc}">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
</Grid.ColumnDefinitions>
|
|
|
|
<TextBlock Grid.Column="0"
|
|
Text="{Binding RadiusMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="2,2,0,2"/>
|
|
<TextBox Grid.Column="1"
|
|
Style="{StaticResource DoorParamsTxBx}"
|
|
Text="{Binding CurrPart.Radius, UpdateSourceTrigger=PropertyChanged}"
|
|
ToolTip="{Binding CurrPart.ToolTipEvaluatedRadius}"
|
|
Margin="0.4,2,10.6,3.2"
|
|
IsReadOnly="{Binding IsRaedOnly}"/>
|
|
<TextBlock Grid.Column="2"
|
|
Text="{Binding PosxMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="2,2,0,2"/>
|
|
<TextBox Grid.Column="3"
|
|
Style="{StaticResource DoorParamsTxBx}"
|
|
Text="{Binding CurrPart.Posx, UpdateSourceTrigger=PropertyChanged}"
|
|
ToolTip="{Binding CurrPart.ToolTipEvaluatedPosx}"
|
|
Margin="0.4,2,10.6,3.2"
|
|
IsReadOnly="{Binding IsRaedOnly}"/>
|
|
</Grid>
|
|
</GroupBox>-->
|
|
|
|
<!--TopAngle-->
|
|
<!--<GroupBox Grid.Row="6" Grid.Column="1" Margin="2,0,2,0">
|
|
<GroupBox.Header>
|
|
<StackPanel Orientation="Horizontal">
|
|
<CheckBox Grid.Row="0" Grid.Column="5"
|
|
Name="TopAngle"
|
|
Style="{StaticResource DoorParamsChBx}"
|
|
IsChecked="{Binding CurrPart.TopAngleIsChecked}"
|
|
Margin="0,0,2,0" VerticalAlignment="Stretch" Height="Auto"/>
|
|
<TextBlock Text="{Binding TopAngleMsg}" Width="Auto"/>
|
|
</StackPanel>
|
|
</GroupBox.Header>
|
|
|
|
<Grid Margin="0,0,0,2" IsEnabled="{Binding IsChecked, ElementName=TopAngle}">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
</Grid.ColumnDefinitions>
|
|
|
|
<TextBlock Grid.Column="0"
|
|
Text="{Binding AngleMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="2,2,0,2"/>
|
|
<TextBox Grid.Column="1"
|
|
Style="{StaticResource DoorParamsTxBx}"
|
|
Text="{Binding CurrPart.Angle, UpdateSourceTrigger=PropertyChanged}"
|
|
ToolTip="{Binding CurrPart.Angle}"
|
|
Margin="0.4,2,10.6,3.2"
|
|
IsReadOnly="{Binding IsRaedOnly}"/>
|
|
<TextBlock Grid.Column="2"
|
|
Text="{Binding PosxMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="2,2,0,2"/>
|
|
<TextBox Grid.Column="3"
|
|
Style="{StaticResource DoorParamsTxBx}"
|
|
Text="{Binding CurrPart.PosxAngle, UpdateSourceTrigger=PropertyChanged}"
|
|
ToolTip="{Binding CurrPart.ToolTipEvaluatedPosxAngle}"
|
|
Margin="0.4,2,10.6,3.2"
|
|
IsReadOnly="{Binding IsRaedOnly}"/>
|
|
</Grid>
|
|
</GroupBox>-->
|
|
|
|
<!--Cut NON IN USO-->
|
|
<GroupBox Grid.Row="6" Grid.Column="1" Margin="2,0,2,0" Visibility="Collapsed">
|
|
<GroupBox.Header>
|
|
<StackPanel Orientation="Horizontal">
|
|
<CheckBox Grid.Row="0" Grid.Column="5"
|
|
Name="Cut"
|
|
Style="{StaticResource DoorParamsChBx}"
|
|
IsChecked="{Binding CurrPart.Cut}"
|
|
Margin="0,0,2,0" VerticalAlignment="Stretch" Height="Auto"/>
|
|
<TextBlock Text="{Binding CutMsg}" Width="Auto"/>
|
|
</StackPanel>
|
|
</GroupBox.Header>
|
|
|
|
<Grid Margin="0,0,0,2" IsEnabled="{Binding IsChecked, ElementName=Cut}">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
</Grid.ColumnDefinitions>
|
|
|
|
<TextBlock Grid.Column="0"
|
|
Text="{Binding PosCutMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="2,2,0,2"/>
|
|
<TextBox Grid.Column="1"
|
|
Style="{StaticResource DoorParamsTxBx}"
|
|
Text="{Binding CurrPart.PosCut, UpdateSourceTrigger=PropertyChanged}"
|
|
ToolTip="{Binding CurrPart.ToolTipEvaluatedPosCut}"
|
|
Margin="0.4,2,10.6,3.2"
|
|
IsReadOnly="{Binding IsRaedOnly}"/>
|
|
<TextBlock Grid.Column="2"
|
|
Text="{Binding OrientationMsg}"
|
|
Style="{StaticResource DoorParamsTxBl}"
|
|
Margin="2,2,0,2"/>
|
|
<ComboBox Grid.Column="3"
|
|
ItemsSource="{Binding CurrPart.CutDirectionList}"
|
|
SelectedItem="{Binding CurrPart.SelectedDirection}">
|
|
</ComboBox>
|
|
</Grid>
|
|
</GroupBox>
|
|
|
|
</Grid>
|
|
</Grid>
|
|
</GroupBox>
|
|
|
|
<!--.....................................Elenco degli item...............................................-->
|
|
<ListBox Name="DoorParamsItemsControl" Grid.Row="2" IsEnabled="{Binding EnablePageDoor}"
|
|
ItemsSource="{Binding CurrPart.CompoList}" SelectedItem="{Binding CurrPart.SelCompo}">
|
|
<ListBox.Style>
|
|
<Style TargetType="ListBox">
|
|
<Setter Property="ItemsPanel">
|
|
<Setter.Value>
|
|
<ItemsPanelTemplate>
|
|
<WrapPanel Orientation="Vertical"/>
|
|
</ItemsPanelTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type ItemsControl}">
|
|
<ScrollViewer HorizontalScrollBarVisibility="Auto" VerticalScrollBarVisibility="Disabled" CanContentScroll="True">
|
|
<ItemsPresenter/>
|
|
</ScrollViewer>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
<EventSetter Event="SelectionChanged" Handler="ItemsControl_SelectionChanged"/>
|
|
</Style>
|
|
</ListBox.Style>
|
|
<ListBox.InputBindings>
|
|
<KeyBinding Key="Enter" Command="{Binding RefreshCmd}"/>
|
|
</ListBox.InputBindings>
|
|
<ListBox.ItemContainerStyle>
|
|
<Style TargetType="ListBoxItem">
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="ListBoxItem">
|
|
<ContentPresenter/>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
</ListBox.ItemContainerStyle>
|
|
<ListBox.ItemTemplate>
|
|
<DataTemplate>
|
|
<GroupBox Width="{Binding ActualWidth,ElementName=DoorParamsItemsControl,
|
|
Converter={StaticResource SplitConverter},ConverterParameter=2}" Padding="0,0,1,0">
|
|
<GroupBox.Style>
|
|
<Style TargetType="GroupBox">
|
|
<Setter Property="BorderBrush" Value="LightGray"/>
|
|
<Setter Property="BorderThickness" Value="1"/>
|
|
<Style.Triggers>
|
|
<DataTrigger Binding="{Binding IsError}" Value="True">
|
|
<Setter Property="BorderBrush" Value="{Binding ErrorColor}"/>
|
|
<Setter Property="BorderThickness" Value="2"/>
|
|
</DataTrigger>
|
|
<DataTrigger Binding="{Binding IsError}" Value="False">
|
|
<Setter Property="BorderBrush" Value="{Binding BorderColor}"/>
|
|
<Setter Property="BorderThickness" Value="{Binding BorderThickness}"/>
|
|
</DataTrigger>
|
|
</Style.Triggers>
|
|
</Style>
|
|
</GroupBox.Style>
|
|
<GroupBox.Header >
|
|
<StackPanel Orientation="Horizontal" IsEnabled="{Binding IsReadOnly, Converter={StaticResource TrueToFalse}}">
|
|
<Button x:Name="ReloadCompoRef"
|
|
Visibility="{Binding VisibilitiReloadBtn}"
|
|
ToolTip="{Binding DataContext.ReloadCompoRefToolTip,RelativeSource={RelativeSource AncestorType={x:Type UserControl}}}"
|
|
Command="{Binding ReloadCompoRefCmd}" Margin="2,2,10,2"
|
|
Width="{Binding ActualHeight, RelativeSource={RelativeSource Self}}"
|
|
Focusable="False">
|
|
<Image Source="/Resources/TopCommandBar/Create Assembly.png" Height="12" Stretch="Uniform"/>
|
|
</Button>
|
|
<TextBlock Text="{Binding CompoType.Name}" Width="Auto" Background="{Binding BackGroundColor}">
|
|
<TextBlock.Style>
|
|
<Style TargetType="TextBlock">
|
|
<Setter Property="Foreground" Value="Black"/>
|
|
<Setter Property="FontWeight" Value="Normal"/>
|
|
<Style.Triggers>
|
|
<DataTrigger Binding="{Binding IsError}" Value="True">
|
|
<Setter Property="Foreground" Value="{Binding ErrorColor}"/>
|
|
<Setter Property="FontWeight" Value="Bold"/>
|
|
</DataTrigger>
|
|
<DataTrigger Binding="{Binding IsError}" Value="false">
|
|
<Setter Property="Foreground" Value="{Binding Foreground}"/>
|
|
<Setter Property="FontWeight" Value="{Binding FontBold}"/>
|
|
</DataTrigger>
|
|
</Style.Triggers>
|
|
</Style>
|
|
</TextBlock.Style>
|
|
</TextBlock>
|
|
<Button x:Name="Cross"
|
|
ToolTip="{Binding DataContext.DeleteCompoToolTip,RelativeSource={RelativeSource AncestorType={x:Type UserControl}}}"
|
|
Command="{Binding DeleteCommand}" Margin="10,2,0,2"
|
|
Width="{Binding ActualHeight, RelativeSource={RelativeSource Self}}"
|
|
Focusable="False">
|
|
<Image Source="{Binding ImageButton}" Height="12" Stretch="Uniform"/>
|
|
</Button>
|
|
<Button x:Name="GoToHardware"
|
|
ToolTip="{Binding DataContext.GoToHardwareToolTip, RelativeSource={RelativeSource AncestorType={x:Type UserControl}}}"
|
|
Width="{Binding ActualHeight, RelativeSource={RelativeSource Self}}"
|
|
Command="{Binding GoToHardwareCmd}" Margin="10,2,0,2"
|
|
Focusable="False">
|
|
<Image Source="{Binding ImageHardware}" Height="12" Stretch="Uniform"/>
|
|
</Button>
|
|
|
|
</StackPanel>
|
|
</GroupBox.Header>
|
|
<StackPanel >
|
|
<!--Brand Template-->
|
|
<UniformGrid Columns="2" Visibility="{Binding TemplateVisibility}">
|
|
<!--Brand-->
|
|
<TextBlock Text="{Binding BrandMsg}">
|
|
<TextBlock.Style>
|
|
<Style TargetType="TextBlock" >
|
|
<Setter Property="FontStyle" Value="Normal"/>
|
|
<Setter Property="Foreground" Value="Black"/>
|
|
<Style.Triggers>
|
|
<DataTrigger Binding="{Binding MissingDirectory}" Value="True">
|
|
<Setter Property="FontStyle" Value="{Binding FontStyleCompoBrandFile}"/>
|
|
<Setter Property="Foreground" Value="{Binding ErrorColor}"/>
|
|
</DataTrigger>
|
|
</Style.Triggers>
|
|
</Style>
|
|
</TextBlock.Style>
|
|
</TextBlock>
|
|
<ComboBox ItemsSource="{Binding BrandListPart, Converter={StaticResource TemplateListConverter}}"
|
|
Margin="0,0,0,2"
|
|
SelectedItem="{Binding SelBrandPart}"
|
|
Style="{StaticResource DoorParamsCmBx}"
|
|
IsEnabled="{Binding IsReadOnly, Converter={StaticResource TrueToFalse}}"/>
|
|
<!--File-->
|
|
<TextBlock Text="{Binding TemplateName}">
|
|
<TextBlock.Style>
|
|
<Style TargetType="TextBlock" >
|
|
<Setter Property="Foreground" Value="Black"/>
|
|
<Style.Triggers>
|
|
<DataTrigger Binding="{Binding MissingFile}" Value="True">
|
|
<Setter Property="FontStyle" Value="{Binding FontStyleCompoBrandFile}"/>
|
|
<Setter Property="Foreground" Value="{Binding ErrorColor}"/>
|
|
</DataTrigger>
|
|
</Style.Triggers>
|
|
</Style>
|
|
</TextBlock.Style>
|
|
</TextBlock>
|
|
<ComboBox ItemsSource="{Binding FileList, Converter={StaticResource TemplateListConverter}}"
|
|
Margin="0,0,0,2"
|
|
SelectedItem="{Binding SelFile}"
|
|
Style="{StaticResource DoorParamsCmBx}"
|
|
IsEnabled="{Binding IsReadOnly, Converter={StaticResource TrueToFalse}}"/>
|
|
</UniformGrid>
|
|
|
|
<!--Lista dei parametri-->
|
|
<ItemsControl ItemsSource="{Binding CompoParamList}"
|
|
Visibility="{Binding ShowParamList}">
|
|
<ItemsControl.Resources>
|
|
<!-- ComboBox -->
|
|
<DataTemplate DataType="{x:Type local:ComboBoxParam}">
|
|
<UniformGrid Columns="2">
|
|
<TextBlock Text="{Binding Name}" >
|
|
<!--Style="{StaticResource DoorParamsTxBl}"-->
|
|
<TextBlock.Style>
|
|
<Style TargetType="TextBlock" >
|
|
<Setter Property="Foreground" Value="Black"/>
|
|
<Style.Triggers>
|
|
<DataTrigger Binding="{Binding ErrorParameter}" Value="True">
|
|
<Setter Property="FontStyle" Value="Italic"/>
|
|
<Setter Property="Foreground" Value="{Binding ColorParam}"/>
|
|
</DataTrigger>
|
|
</Style.Triggers>
|
|
</Style>
|
|
</TextBlock.Style>
|
|
</TextBlock>
|
|
<ComboBox ItemsSource="{Binding ItemList}" Margin="0,0,0,2"
|
|
SelectedItem="{Binding SelItem}"
|
|
Style="{StaticResource DoorParamsCmBx}"
|
|
IsEnabled="{Binding CurrCompo.IsReadOnly, Converter={StaticResource TrueToFalse}}"/>
|
|
</UniformGrid>
|
|
</DataTemplate>
|
|
<!-- ComboBoxOnOff -->
|
|
<DataTemplate DataType="{x:Type local:ComboBoxOnOffParam}">
|
|
<Grid IsEnabled="{Binding CurrCompo.IsReadOnly, Converter={StaticResource TrueToFalse}}">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
</Grid.ColumnDefinitions>
|
|
|
|
<Grid >
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="Auto"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
</Grid.ColumnDefinitions>
|
|
|
|
<CheckBox Name="ChBxBox" IsChecked="{Binding IsActive}"
|
|
Style="{StaticResource DoorParamsChBx}"
|
|
VerticalAlignment="Top"/>
|
|
<TextBlock Text="{Binding Name}" Grid.Column="1"
|
|
Margin="2,0,0,2">
|
|
<TextBlock.Style>
|
|
<Style TargetType="TextBlock" >
|
|
<Setter Property="Foreground" Value="Black"/>
|
|
<Style.Triggers>
|
|
<DataTrigger Binding="{Binding ErrorParameter}" Value="True">
|
|
<Setter Property="FontStyle" Value="Italic"/>
|
|
<Setter Property="Foreground" Value="{Binding ColorParam}"/>
|
|
</DataTrigger>
|
|
</Style.Triggers>
|
|
</Style>
|
|
</TextBlock.Style>
|
|
</TextBlock>
|
|
|
|
</Grid>
|
|
<ComboBox ItemsSource="{Binding ItemList}" Grid.Column="2"
|
|
Margin="0,0,0,2"
|
|
SelectedItem="{Binding SelItem}"
|
|
Style="{StaticResource DoorParamsCmBx}"
|
|
IsEnabled="{Binding IsChecked, ElementName=ChBxBox}"/>
|
|
</Grid>
|
|
</DataTemplate>
|
|
<!-- TextBox -->
|
|
<DataTemplate DataType="{x:Type local:TextBoxParam}">
|
|
<UniformGrid Columns="2">
|
|
<UniformGrid.InputBindings>
|
|
<KeyBinding Key="Enter" Command="{Binding DataContext.RefreshCmd,RelativeSource={RelativeSource AncestorType={x:Type UserControl}}}"
|
|
FocusManager.FocusedElement="{Binding ElementName=Stk}"/>
|
|
</UniformGrid.InputBindings>
|
|
|
|
<TextBlock Text="{Binding Name}">
|
|
<TextBlock.Style>
|
|
<Style TargetType="TextBlock" >
|
|
<Setter Property="Foreground" Value="Black"/>
|
|
<Style.Triggers>
|
|
<DataTrigger Binding="{Binding ErrorParameter}" Value="True">
|
|
<Setter Property="FontStyle" Value="Italic"/>
|
|
<Setter Property="Foreground" Value="{Binding ColorParam}"/>
|
|
</DataTrigger>
|
|
</Style.Triggers>
|
|
</Style>
|
|
</TextBlock.Style>
|
|
</TextBlock>
|
|
|
|
<TextBox Text="{Binding Value,UpdateSourceTrigger=PropertyChanged}"
|
|
Name="TxTData"
|
|
Style="{StaticResource DoorParamsTxBx}"
|
|
Margin="0,0,0,2"
|
|
ToolTip="{Binding ToolTipValue}"
|
|
IsReadOnly="{Binding CurrCompo.IsReadOnly}"/>
|
|
</UniformGrid>
|
|
</DataTemplate>
|
|
<!-- TextBoxOnOff -->
|
|
<DataTemplate DataType="{x:Type local:TextBoxOnOffParam}">
|
|
<Grid>
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="1*"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
</Grid.ColumnDefinitions>
|
|
|
|
<Grid>
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="Auto"/>
|
|
<ColumnDefinition Width="1*"/>
|
|
</Grid.ColumnDefinitions>
|
|
|
|
<CheckBox Name="ChBx" IsChecked="{Binding IsActive}"
|
|
Style="{StaticResource DoorParamsChBx}"
|
|
VerticalAlignment="Top"
|
|
IsEnabled="{Binding CurrCompo.IsReadOnly, Converter={StaticResource TrueToFalse}}"/>
|
|
<TextBlock Text="{Binding Name}" Grid.Column="1"
|
|
Margin="2,0,0,2">
|
|
<TextBlock.Style>
|
|
<Style TargetType="TextBlock" >
|
|
<Setter Property="Foreground" Value="Black"/>
|
|
<Style.Triggers>
|
|
<DataTrigger Binding="{Binding ErrorParameter}" Value="True">
|
|
<Setter Property="FontStyle" Value="Italic"/>
|
|
<Setter Property="Foreground" Value="{Binding ColorParam}"/>
|
|
</DataTrigger>
|
|
</Style.Triggers>
|
|
</Style>
|
|
</TextBlock.Style>
|
|
</TextBlock>
|
|
|
|
</Grid>
|
|
<TextBox Text="{Binding Value,UpdateSourceTrigger=PropertyChanged}" Grid.Column="2"
|
|
Style="{StaticResource DoorParamsTxBx}"
|
|
IsEnabled="{Binding IsChecked, ElementName=ChBx}"
|
|
IsReadOnly="{Binding CurrCompo.IsReadOnly}"
|
|
Margin="0,0,0,2"
|
|
ToolTip="{Binding ToolTipValue,UpdateSourceTrigger=PropertyChanged}"/>
|
|
</Grid>
|
|
</DataTemplate>
|
|
</ItemsControl.Resources>
|
|
|
|
</ItemsControl>
|
|
</StackPanel>
|
|
</GroupBox>
|
|
</DataTemplate>
|
|
</ListBox.ItemTemplate>
|
|
</ListBox>
|
|
|
|
</Grid>
|
|
<ContentControl Grid.Column="0" Grid.Row="0" Content="{Binding CompoPanelControl}"/>
|
|
<!--<EgtDOORCreator:CompoPanelV Grid.Column="0" DataContext="{Binding CompoPanelPartVM}"/>-->
|
|
</Grid>
|
|
</UserControl>
|