diff options
Diffstat (limited to 'Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/RmlView.xaml')
| -rw-r--r-- | Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/RmlView.xaml | 71 |
1 files changed, 50 insertions, 21 deletions
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/RmlView.xaml b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/RmlView.xaml index 08af47ef4..eb6f50bbe 100644 --- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/RmlView.xaml +++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/RmlView.xaml @@ -5,6 +5,7 @@ xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:global="clr-namespace:Tango.MachineStudio.RML" xmlns:enumerations="clr-namespace:Tango.BL.Enumerations;assembly=Tango.BL" + xmlns:sys="clr-namespace:System;assembly=mscorlib" xmlns:observables="clr-namespace:Tango.BL.Entities;assembly=Tango.BL" xmlns:shapes="clr-namespace:Tango.SharedUI.Shapes;assembly=Tango.SharedUI" xmlns:controls="clr-namespace:Tango.SharedUI.Controls;assembly=Tango.SharedUI" @@ -21,6 +22,14 @@ <UserControl.Resources> <converters:ColorToIntegerConverter x:Key="ColorToIntegerConverter"></converters:ColorToIntegerConverter> <converters:EnumToItemsSourceConverter x:Key="EnumToItemsSourceConverter"/> + <converters:EnumToDescriptionConverter x:Key="EnumToDescriptionConverter"/> + + <ObjectDataProvider x:Key="Plies" ObjectType="{x:Type sys:Enum}" MethodName="GetValues"> + <ObjectDataProvider.MethodParameters> + <x:Type TypeName="enumerations:Plies"/> + </ObjectDataProvider.MethodParameters> + </ObjectDataProvider> + </UserControl.Resources> <Grid Margin="20"> @@ -94,45 +103,65 @@ <ComboBox ItemsSource="{Binding Purposes}" SelectedItem="{Binding ActiveRML.MediaPurpose,Mode=TwoWay}" DisplayMemberPath="Name"></ComboBox> <TextBlock Text="Condition:" ></TextBlock> - <ComboBox ItemsSource="{Binding Conditions}" SelectedItem="{Binding ActiveRML.MediaCondition,Mode=TwoWay}" DisplayMemberPath="Name"></ComboBox> + <ComboBox ItemsSource="{Binding Conditions}" SelectedItem="{Binding ActiveRML.MediaCondition,Mode=TwoWay}" DisplayMemberPath="Name"></ComboBox>--> + + + <TextBlock Text="Linear Density:" Margin="0 40 0 0" ></TextBlock> + <mahapps:NumericUpDown Margin="0 40 0 0" Minimum="0" Maximum="9999" InterceptArrowKeys="True" Background="Transparent" BorderThickness="0" InterceptMouseWheel="True" HasDecimals="False" HorizontalContentAlignment="Left" Value="{Binding ActiveRML.FiberSize,Mode=TwoWay}" FontSize="16"></mahapps:NumericUpDown> - <TextBlock Text="Linear Mass Density Unit:" ></TextBlock> + <TextBlock Text="Linear Density Unit:" ></TextBlock> <ComboBox ItemsSource="{Binding LinearMassDensityUnits}" SelectedItem="{Binding ActiveRML.LinearMassDensityUnit,Mode=TwoWay}" DisplayMemberPath="Name"></ComboBox> - <TextBlock Text="Fiber Shape:" ></TextBlock> - <ComboBox ItemsSource="{Binding FiberShapes}" SelectedItem="{Binding ActiveRML.FiberShape,Mode=TwoWay}" DisplayMemberPath="Name"></ComboBox> + <TextBlock Text="Plies:" ></TextBlock> + <ComboBox ItemsSource="{Binding Source={StaticResource Plies}}" SelectedItem="{Binding ActiveRML.RMLPlies, Mode=TwoWay}" > + <ComboBox.ItemTemplate> + <DataTemplate> + <TextBlock Text="{Binding Converter={StaticResource EnumToDescriptionConverter}}"></TextBlock> + </DataTemplate> + </ComboBox.ItemTemplate> + </ComboBox> - <TextBlock Text="Fiber Syntheses:" ></TextBlock> - <ComboBox ItemsSource="{Binding FiberSynths}" SelectedItem="{Binding ActiveRML.FiberSynth,Mode=TwoWay}" DisplayMemberPath="Name"></ComboBox> + <TextBlock Text="Filament count per plies:" ></TextBlock> + <mahapps:NumericUpDown Minimum="0" Maximum="10000" InterceptArrowKeys="True" Background="Transparent" BorderThickness="0" InterceptMouseWheel="True" HasDecimals="False" HorizontalContentAlignment="Left" Value="{Binding ActiveRML.PliesPerFiber,Mode=TwoWay}"></mahapps:NumericUpDown> - <TextBlock Text="Fiber Size:" ></TextBlock> - <mahapps:NumericUpDown Minimum="0" Maximum="10000" InterceptArrowKeys="True" Background="Transparent" BorderThickness="0" InterceptMouseWheel="True" HasDecimals="True" HorizontalContentAlignment="Left" Value="{Binding ActiveRML.FiberSize,Mode=TwoWay}"></mahapps:NumericUpDown> + <TextBlock Text="Count (den):" ></TextBlock> + <TextBlock Text="{Binding ActiveRML.DencityCount}" Foreground="Blue" ></TextBlock> - <TextBlock Text="Fibers Count:" ></TextBlock> - <mahapps:NumericUpDown Minimum="0" Maximum="10000" InterceptArrowKeys="True" Background="Transparent" BorderThickness="0" InterceptMouseWheel="True" HasDecimals="False" HorizontalContentAlignment="Left" Value="{Binding ActiveRML.NumberOfFibers,Mode=TwoWay}"></mahapps:NumericUpDown> + <TextBlock Text="Fiber count:" ></TextBlock> + <TextBlock Text="{Binding ActiveRML.FiberCount}" Foreground="Blue" ></TextBlock> - <TextBlock Text="Plies Per Fiber:" ></TextBlock> - <mahapps:NumericUpDown Minimum="0" Maximum="10000" InterceptArrowKeys="True" Background="Transparent" BorderThickness="0" InterceptMouseWheel="True" HasDecimals="False" HorizontalContentAlignment="Left" Value="{Binding ActiveRML.PliesPerFiber,Mode=TwoWay}"></mahapps:NumericUpDown> + <!--<TextBlock Text="Fiber Shape:" ></TextBlock> + <ComboBox ItemsSource="{Binding FiberShapes}" SelectedItem="{Binding ActiveRML.FiberShape,Mode=TwoWay}" DisplayMemberPath="Name"></ComboBox>--> + + <!--<TextBlock Text="Fiber Syntheses:" ></TextBlock> + <ComboBox ItemsSource="{Binding FiberSynths}" SelectedItem="{Binding ActiveRML.FiberSynth,Mode=TwoWay}" DisplayMemberPath="Name"></ComboBox>--> + + <!--<TextBlock Text="Fiber Size:" ></TextBlock> + <mahapps:NumericUpDown Minimum="0" Maximum="10000" InterceptArrowKeys="True" Background="Transparent" BorderThickness="0" InterceptMouseWheel="True" HasDecimals="True" HorizontalContentAlignment="Left" Value="{Binding ActiveRML.FiberSize,Mode=TwoWay}"></mahapps:NumericUpDown>--> + + <!--<TextBlock Text="Fibers Count:" ></TextBlock> + <mahapps:NumericUpDown Minimum="0" Maximum="10000" InterceptArrowKeys="True" Background="Transparent" BorderThickness="0" InterceptMouseWheel="True" HasDecimals="False" HorizontalContentAlignment="Left" Value="{Binding ActiveRML.NumberOfFibers,Mode=TwoWay}"></mahapps:NumericUpDown>--> - <TextBlock Text="Plies Per Thread:" ></TextBlock> - <mahapps:NumericUpDown Minimum="0" Maximum="10000" InterceptArrowKeys="True" Background="Transparent" BorderThickness="0" InterceptMouseWheel="True" HasDecimals="False" HorizontalContentAlignment="Left" Value="{Binding ActiveRML.PliesPerThread,Mode=TwoWay}"></mahapps:NumericUpDown> + <!--<TextBlock Text="Plies Per Thread:" ></TextBlock> + <mahapps:NumericUpDown Minimum="0" Maximum="10000" InterceptArrowKeys="True" Background="Transparent" BorderThickness="0" InterceptMouseWheel="True" HasDecimals="False" HorizontalContentAlignment="Left" Value="{Binding ActiveRML.PliesPerThread,Mode=TwoWay}"></mahapps:NumericUpDown>--> + - <TextBlock Text="Tensile Strength:" ></TextBlock> + <!--<TextBlock Text="Tensile Strength:" ></TextBlock> <mahapps:NumericUpDown Minimum="0" Maximum="10000" InterceptArrowKeys="True" Background="Transparent" BorderThickness="0" InterceptMouseWheel="True" HasDecimals="True" HorizontalContentAlignment="Left" Value="{Binding ActiveRML.TensileStrength,Mode=TwoWay}"></mahapps:NumericUpDown> <TextBlock Text="Elongation Break Percentage:" ></TextBlock> - <mahapps:NumericUpDown Minimum="0" Maximum="10000" InterceptArrowKeys="True" Background="Transparent" BorderThickness="0" InterceptMouseWheel="True" HasDecimals="True" HorizontalContentAlignment="Left" Value="{Binding ActiveRML.ElongationAtBreakPercentage,Mode=TwoWay}"></mahapps:NumericUpDown> + <mahapps:NumericUpDown Minimum="0" Maximum="10000" InterceptArrowKeys="True" Background="Transparent" BorderThickness="0" InterceptMouseWheel="True" HasDecimals="True" HorizontalContentAlignment="Left" Value="{Binding ActiveRML.ElongationAtBreakPercentage,Mode=TwoWay}"></mahapps:NumericUpDown>--> - <TextBlock Text="Estimated Thread Diameter:" ></TextBlock> - <mahapps:NumericUpDown Minimum="0" Maximum="10000" InterceptArrowKeys="True" Background="Transparent" BorderThickness="0" InterceptMouseWheel="True" HasDecimals="True" HorizontalContentAlignment="Left" Value="{Binding ActiveRML.EstimatedThreadDiameter,Mode=TwoWay}"></mahapps:NumericUpDown> + <!--<TextBlock Text="Estimated Thread Diameter:" ></TextBlock> + <mahapps:NumericUpDown Minimum="0" Maximum="10000" InterceptArrowKeys="True" Background="Transparent" BorderThickness="0" InterceptMouseWheel="True" HasDecimals="True" HorizontalContentAlignment="Left" Value="{Binding ActiveRML.EstimatedThreadDiameter,Mode=TwoWay}"></mahapps:NumericUpDown>--> - <TextBlock Text="Twisted:" ></TextBlock> + <!--<TextBlock Text="Twisted:" ></TextBlock> <ToggleButton HorizontalAlignment="Right" IsChecked="{Binding ActiveRML.Twisted}" Style="{StaticResource MaterialDesignSwitchToggleButton}" /> <TextBlock Text="Air Entanglement:" ></TextBlock> - <ToggleButton HorizontalAlignment="Right" IsChecked="{Binding ActiveRML.AirEntanglement}" Style="{StaticResource MaterialDesignSwitchToggleButton}" /> + <ToggleButton HorizontalAlignment="Right" IsChecked="{Binding ActiveRML.AirEntanglement}" Style="{StaticResource MaterialDesignSwitchToggleButton}" />--> - <TextBlock Text="Lubricant:" ></TextBlock> + <!--<TextBlock Text="Lubricant:" ></TextBlock> <ToggleButton HorizontalAlignment="Right" IsChecked="{Binding ActiveRML.Lubricant}" Style="{StaticResource MaterialDesignSwitchToggleButton}" />--> </controls:TableGrid> </DockPanel> |
