From 8a968daaae4e16cee641bee868227de45bd4c8c0 Mon Sep 17 00:00:00 2001 From: Victoria Plitt Date: Sun, 30 Oct 2022 08:16:40 +0200 Subject: Visual Fine Tuning --- .../Dialogs/VectorFineTuningDialog.xaml | 269 +++++++++++--- .../Dialogs/VectorFineTuningDialogVM.cs | 388 ++++++++++++++++++++- .../Tango.PPC.JobsV2/Models/TrialsLogModel.cs | 26 +- .../Tango.PPC.JobsV2/Tango.PPC.JobsV2.csproj | 6 +- .../Visual_Studio/PPC/Tango.PPC.UI/app.manifest | 2 +- .../Controls/TouchNumericUpDownConrol.cs | 19 +- .../Styles/TouchNumericUpDownControl.xaml | 2 +- 7 files changed, 640 insertions(+), 72 deletions(-) diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Dialogs/VectorFineTuningDialog.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Dialogs/VectorFineTuningDialog.xaml index 56e3ff211..8ab9c52e9 100644 --- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Dialogs/VectorFineTuningDialog.xaml +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Dialogs/VectorFineTuningDialog.xaml @@ -127,7 +127,9 @@ - + + + @@ -159,73 +161,236 @@ + + + + + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - + + - - - - - - - - - - - - - - - - - + Vector correction: + + + + + + + + + + + + + + + + + + + + + + + + + + Correct Lightness + Correct Chroma + Correct Hue + + + + + + + + + + + + Visual correction: + + + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - + - + diff --git a/Software/Visual_Studio/Tango.Touch/Controls/TouchNumericUpDownConrol.cs b/Software/Visual_Studio/Tango.Touch/Controls/TouchNumericUpDownConrol.cs index 2b85e8168..d12dd27b6 100644 --- a/Software/Visual_Studio/Tango.Touch/Controls/TouchNumericUpDownConrol.cs +++ b/Software/Visual_Studio/Tango.Touch/Controls/TouchNumericUpDownConrol.cs @@ -60,6 +60,17 @@ namespace Tango.Touch.Controls public static readonly DependencyProperty MaxValueProperty = DependencyProperty.Register("MaxValue", typeof(double), typeof(TouchNumericUpDownConrol), new PropertyMetadata(100.0)); + public double Step + { + get { return (double)GetValue(StepProperty); } + set { SetValue(StepProperty, value); } + } + + /// + /// The slider minimum value property + /// + public static readonly DependencyProperty StepProperty = + DependencyProperty.Register("Step", typeof(double), typeof(TouchNumericUpDownConrol), new PropertyMetadata(1.0)); public double NumericPartWidth @@ -105,11 +116,11 @@ namespace Tango.Touch.Controls { IncrementCommand = new RelayCommand(()=> { - Value += 1; - } , (x)=> { return (Value + 1) <= MaxValue; }); + Value += Step; + } , (x)=> { return (Value + Step) <= MaxValue; }); DecrementCommand = new RelayCommand(() => { - Value -= 1; - }, (x) => { return (Value - 1) >= MinValue; }); + Value -= Step; + }, (x) => { return (Value - Step) >= MinValue; }); _changedFromAnotherControl = false; } diff --git a/Software/Visual_Studio/Tango.Touch/Styles/TouchNumericUpDownControl.xaml b/Software/Visual_Studio/Tango.Touch/Styles/TouchNumericUpDownControl.xaml index 961b22c0f..d29cd2a48 100644 --- a/Software/Visual_Studio/Tango.Touch/Styles/TouchNumericUpDownControl.xaml +++ b/Software/Visual_Studio/Tango.Touch/Styles/TouchNumericUpDownControl.xaml @@ -82,7 +82,7 @@ + Value="{Binding Value,RelativeSource={RelativeSource AncestorType=controls:TouchNumericUpDownConrol}, Mode=TwoWay}" Minimum="{Binding MinValue,RelativeSource={RelativeSource AncestorType=controls:TouchNumericUpDownConrol}}" Maximum="{Binding MaxValue,RelativeSource={RelativeSource AncestorType=controls:TouchNumericUpDownConrol}, Mode=TwoWay}" HideUnderline="True" HasDecimalPoint="True"/> -- cgit v1.3.1