1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
|
<UserControl x:Class="Tango.PPC.Jobs.Dialogs.VectorFineTuningDialog"
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:Tango.PPC.Jobs.Dialogs"
xmlns:converters="clr-namespace:Tango.PPC.Jobs.Converters"
xmlns:vm="clr-namespace:Tango.PPC.Jobs.Dialogs"
xmlns:controls="clr-namespace:Tango.PPC.Jobs.Controls"
xmlns:commonControls="clr-namespace:Tango.PPC.Common.Controls;assembly=Tango.PPC.Common"
xmlns:sharedConverters="clr-namespace:Tango.SharedUI.Converters;assembly=Tango.SharedUI"
xmlns:fa="http://schemas.fontawesome.io/icons/"
xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch"
xmlns:appBarItems="clr-namespace:Tango.PPC.Jobs.AppBarItems"
mc:Ignorable="d"
Background="{StaticResource TangoMidBackgroundBrush}"
d:DesignHeight="1280" d:DesignWidth="800" Width="750" Height="1200"
d:DataContext="{d:DesignInstance Type=vm:VectorFineTuningDialogVM, IsDesignTimeCreatable=False}" touch:TouchPanelEureka.MakeEurekaFullScreen="True">
<UserControl.Resources>
<ResourceDictionary>
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="../Resources/Styles.xaml" />
</ResourceDictionary.MergedDictionaries>
<sharedConverters:DateTimeUTCToShortDateTimeConverter x:Key="DateTimeUTCToShortDateTimeConverter" />
<sharedConverters:GreaterThanToBooleanConverter x:Key="GreaterThanToBooleanConverter"/>
<converters:DoubleNullConverter x:Key="DoubleNullConverter" />
<converters:DeltaLCHToTextConverter x:Key="DeltaLCHToTextConverter"/>
<converters:HueValueToTextConvereter x:Key="HueValueToTextConvereter"/>
<converters:ColorContrastConverter x:Key="ColorContrastConverter" />
<converters:RoundDoubleConverter x:Key="RoundDoubleConverter"/>
<BitmapImage x:Key="Close_mycolorsdlg" UriSource="../Images/ColorSelection/close_mycolorsdlg.png" />
<Style x:Key="GreyTextStyle" TargetType="TextBlock">
<Setter Property="Foreground" Value="{StaticResource TangoGrayTextBrush}"></Setter>
<Setter Property="FontSize" Value="{StaticResource TangoSmallFontSize}"></Setter>
<Setter Property="VerticalAlignment" Value="Center"></Setter>
<Setter Property="HorizontalAlignment" Value="Center"></Setter>
</Style>
</ResourceDictionary>
</UserControl.Resources>
<Grid x:Name="VFTgrid" DataContext="{Binding Path=DataContext.VectorFineTuningDialogVM, RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type local:ColorSelectionView}}}" d:DataContext="{d:DesignInstance Type=local:VectorFineTuningDialogVM, IsDesignTimeCreatable=False}">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="1*"/>
</Grid.RowDefinitions>
<Border Height="90" Background="{StaticResource TangoPrimaryBackgroundBrush}" BorderThickness="0 0 0 1" BorderBrush="{StaticResource TangoDividerBrush}">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<!--<Canvas>
<Border Canvas.Right="-20" Canvas.Top="0" BorderThickness="0 0 0 0" BorderBrush="{StaticResource TangoDividerBrush}" Margin="0 0 0 0">
<touch:TouchImageButton Padding="0" Width="Auto" Height="32" Image="{StaticResource Close_mycolorsdlg}" HorizontalAlignment="Right" VerticalAlignment="Top" Margin="0 2 20 2" EnableDropShadow="False" Background="Transparent" BorderThickness="0" Command="{Binding CloseCommand}"/>
</Border>
</Canvas>-->
<Grid Visibility="{Binding IsJobRunning,Converter={StaticResource BooleanToVisibilityInverseConverter}}" >
<TextBlock Margin="180 0 0 0" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="{StaticResource TangoComboBoxTitleFontSize}" FontWeight="SemiBold">Color Correction Tool</TextBlock>
<touch:TouchButton Margin="30 0 0 0" Command="{Binding ByPassTestCommand}" CornerRadius="25" Width="180" Height="50" Content="BYPASS TEST" HorizontalAlignment="Left" BorderThickness="1" RippleBrush="{StaticResource TangoRippleDarkBrush}" EnableDropShadow="False" FontSize="{StaticResource TangoButtonFontSize}">
<touch:TouchButton.Style >
<Style TargetType="touch:TouchButton" >
<Setter Property="Foreground" Value="{StaticResource TangoPrimaryAccentBrush}"></Setter>
<Setter Property="BorderBrush" Value="{StaticResource TangoPrimaryAccentBrush}"></Setter>
<Setter Property="TextElement.Foreground" Value="{StaticResource TangoPrimaryAccentBrush}"></Setter>
<Setter Property="Background" Value="Transparent"/>
<Setter Property="Visibility" Value="Collapsed"/>
<Style.Triggers>
<Trigger Property="IsEnabled" Value="False">
<Setter Property="Foreground" Value="{StaticResource TangoDisabledForegroundBrush}"></Setter>
<Setter Property="TextElement.Foreground" Value="{StaticResource TangoDisabledForegroundBrush}"></Setter>
<Setter Property="BorderBrush" Value="{StaticResource TangoDisabledForegroundBrush}"></Setter>
</Trigger>
<DataTrigger Binding="{Binding IsJobRunning}" Value="True">
<Setter Property="IsEnabled" Value="False"/>
<Setter Property="Foreground" Value="{StaticResource TangoDisabledForegroundBrush}"></Setter>
<Setter Property="TextElement.Foreground" Value="{StaticResource TangoDisabledForegroundBrush}"></Setter>
<Setter Property="BorderBrush" Value="{StaticResource TangoDisabledForegroundBrush}"></Setter>
</DataTrigger>
<!--<MultiDataTrigger>
<MultiDataTrigger.Conditions>
<Condition Binding="{Binding ApplicationManager.IsInTechnicianMode}" Value="true"/>
<Condition Binding="{Binding IsJobRunning}" Value="False"/>
</MultiDataTrigger.Conditions>
<Setter Property="Visibility" Value="Visible"/>
</MultiDataTrigger>-->
<DataTrigger Binding="{Binding IsJobRunning}" Value="False">
<Setter Property="Visibility" Value="Visible"/>
</DataTrigger>
</Style.Triggers>
</Style>
</touch:TouchButton.Style>
</touch:TouchButton>
</Grid>
<Grid Visibility="{Binding IsJobRunning,Converter={StaticResource BooleanToVisibilityConverter}, Delay=100}" Margin="40 0 0 0">
<DockPanel>
<StackPanel VerticalAlignment="Center" Background="Transparent" DockPanel.Dock="Right" Margin="15 0">
<commonControls:MachineStatusControl HorizontalAlignment="Center" DataContext="{Binding MachineProvider.MachineOperator}" />
<TextBlock Margin="0 10 0 0" Text="{Binding MachineProvider.MachineOperator.Status,Converter={StaticResource EnumToDescriptionConverter}}"></TextBlock>
</StackPanel>
<Grid>
<appBarItems:JobProgressAppBarItemView />
</Grid>
</DockPanel>
</Grid>
<Grid Background="{StaticResource TangoPrimaryBackgroundBrush}" Margin="20 0 0 0" Visibility="{Binding IsJobFailed,Converter={StaticResource BooleanToVisibilityConverter}}">
<DockPanel Margin="10">
<touch:TouchIcon VerticalAlignment="Top" Margin="0 5 0 0" Width="42" Icon="Alert" Foreground="{StaticResource TangoErrorBrush}" />
<Grid>
<StackPanel Margin="20 0 0 0">
<TextBlock FontSize="{StaticResource TangoButtonFontSize}">Job Failed</TextBlock>
<TextBlock Margin="0 5 0 0" Text="{Binding JobFailedReason}" FontSize="{StaticResource TangoDefaultFontSize}"></TextBlock>
</StackPanel>
</Grid>
</DockPanel>
</Grid>
<touch:TouchButton Grid.Column="1" Visibility="{Binding IsJobRunning,Converter={StaticResource BooleanToVisibilityInverseConverter}}" Command="{Binding TestCommand}" CornerRadius="25" Width="180" Height="50" Margin="0 2 10 2" Content="TEST" HorizontalAlignment="Right" TextElement.Foreground="{StaticResource TangoLightForegroundBrush}" EnableDropShadow="False" FontSize="{StaticResource TangoButtonFontSize}">
<touch:TouchButton.Style >
<Style TargetType="touch:TouchButton" >
<Setter Property="Foreground" Value="{StaticResource TangoLightForegroundBrush}"></Setter>
<Setter Property="Background" Value="{StaticResource TangoPrimaryAccentBrush}"/>
<Style.Triggers>
<Trigger Property="IsEnabled" Value="False">
<Setter Property="Foreground" Value="{StaticResource TangoDisabledForegroundBrush}"></Setter>
<Setter Property="Background" Value="{StaticResource TangoDisabledBackgroundBrush}"></Setter>
</Trigger>
</Style.Triggers>
</Style>
</touch:TouchButton.Style>
</touch:TouchButton>
<touch:TouchButton Grid.Column="1" Visibility="{Binding IsJobRunning,Converter={StaticResource BooleanToVisibilityConverter}}" Command="{Binding StopCommand}" CornerRadius="25" Width="180" Height="50" Margin="0 2 10 2" Content="STOP" HorizontalAlignment="Right" TextElement.Foreground="{StaticResource TangoLightForegroundBrush}" EnableDropShadow="True" FontSize="{StaticResource TangoButtonFontSize}" BlurRadius="16" ShadowDepth="8" ShadowColor="LightGray">
<touch:TouchButton.Style >
<Style TargetType="touch:TouchButton" >
<Setter Property="Foreground" Value="{StaticResource TangoLightForegroundBrush}"></Setter>
<Setter Property="Background" Value="{StaticResource TangoPrimaryAccentBrush}"/>
<Style.Triggers>
<Trigger Property="IsEnabled" Value="False">
<Setter Property="Foreground" Value="{StaticResource TangoDisabledForegroundBrush}"></Setter>
<Setter Property="Background" Value="{StaticResource TangoDisabledBackgroundBrush}"></Setter>
</Trigger>
</Style.Triggers>
</Style>
</touch:TouchButton.Style>
</touch:TouchButton>
</Grid>
</Border>
<Border Padding="24 16 24 0" Grid.Row="1" >
<Border BorderThickness="0" Background="{StaticResource TangoPrimaryBackgroundBrush}" >
<Grid >
<Grid.RowDefinitions>
<RowDefinition Height="1*"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<Grid Background="{StaticResource TangoPrimaryBackgroundBrush}">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"></RowDefinition>
<RowDefinition Height="Auto"></RowDefinition>
<RowDefinition Height="Auto"></RowDefinition>
</Grid.RowDefinitions>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"></RowDefinition>
<RowDefinition Height="30"></RowDefinition>
</Grid.RowDefinitions>
<StackPanel Orientation="Horizontal" VerticalAlignment="Top" HorizontalAlignment="Left" Margin="24 40 24 0">
<Image Stretch="Fill" Width="36" Height="36" RenderOptions.BitmapScalingMode="Fant" Source="../Images/JobView/color-length.png" HorizontalAlignment="Left"></Image>
<TextBlock Margin="11 0 0 0" HorizontalAlignment="Left" VerticalAlignment="Center" FontSize="{StaticResource TangoMessageBoxButtonFontSize}" Text="Target Color" />
</StackPanel>
<StackPanel Orientation="Horizontal" Margin="0 30 24 0" Grid.Column="1">
<Border Height="60" Width="56" HorizontalAlignment="Left" Background="{Binding ColorBrush}" CornerRadius="12">
<StackPanel Orientation="Vertical" VerticalAlignment="Center" HorizontalAlignment="Center" Visibility="{Binding IsOutOfGamut,Converter={StaticResource BooleanToVisibilityConverter}}">
<Image Margin="0" Stretch="Fill" Width="24" RenderOptions.BitmapScalingMode="Fant" Source="../Images/ColorSelection/Exclamation.png" HorizontalAlignment="Center"></Image>
</StackPanel>
</Border>
<UniformGrid Rows="1" Columns="3" Height="30" MinWidth="150" Margin="14 0 0 0">
<StackPanel Orientation="Horizontal">
<TextBlock Text="L" FontSize="{StaticResource TangoComboBoxItemFontSize}" VerticalAlignment="Center"/>
<Border Margin="10 0 0 0" Background="Transparent" BorderBrush="{StaticResource TangoGrayBrush}" BorderThickness="0.8" Width="50">
<TextBlock Style="{StaticResource GreyTextStyle}" Text="{Binding TargetL, StringFormat=0.00}" ></TextBlock>
</Border>
</StackPanel>
<StackPanel Orientation="Horizontal" Margin="5 0 0 0">
<TextBlock Text="a" FontSize="{StaticResource TangoComboBoxItemFontSize}" VerticalAlignment="Center"/>
<Border Margin="10 0 0 0" Background="Transparent" BorderBrush="{StaticResource TangoGrayBrush}" BorderThickness="0.8" Width="50">
<TextBlock Style="{StaticResource GreyTextStyle}" Text="{Binding TargetA, StringFormat=0.00}" ></TextBlock>
</Border>
</StackPanel>
<StackPanel Orientation="Horizontal" Margin="10 0 0 0">
<TextBlock Text="b" FontSize="{StaticResource TangoComboBoxItemFontSize}" VerticalAlignment="Center"/>
<Border Margin="10 0 0 0" Background="Transparent" BorderBrush="{StaticResource TangoGrayBrush}" BorderThickness="0.8" Width="50">
<TextBlock Style="{StaticResource GreyTextStyle}" Text="{Binding TargetB, StringFormat=0.00}" ></TextBlock>
</Border>
</StackPanel>
</UniformGrid>
</StackPanel>
<Rectangle Height="1" Fill="{StaticResource TangoDividerBrush}" Grid.ColumnSpan="2" Grid.Row="1" VerticalAlignment="Center" Margin="0 0 0 0"></Rectangle>
</Grid>
<Grid Grid.Row="1" x:Name="corrections" Margin="0 0 0 0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="60.6"/>
<RowDefinition Height="29.4"/>
<RowDefinition Height="1*"/>
</Grid.RowDefinitions>
<StackPanel Orientation="Horizontal" VerticalAlignment="Top" HorizontalAlignment="Left" Margin="24 10 24 0">
<Image Stretch="Fill" Width="36" Height="36" RenderOptions.BitmapScalingMode="Fant" Source="../Images/ColorSelection/CorrectionTrial.png" HorizontalAlignment="Left"></Image>
<TextBlock Margin="11 0 0 0" HorizontalAlignment="Left" VerticalAlignment="Center" FontSize="{StaticResource TangoMessageBoxButtonFontSize}" >
<Run Text="Correction " ></Run>
<Run Text="Trial #" Foreground="{StaticResource TangoGrayTextBrush}"></Run>
<Run Text="{Binding TrialNumber, Mode=OneWay}" Foreground="{StaticResource TangoGrayTextBrush}"></Run>
</TextBlock>
</StackPanel>
<Grid Grid.Row="1" HorizontalAlignment="Stretch" Grid.RowSpan="2" >
<touch:TouchNavigationLinks Grid.Row="1" BorderBrush="{StaticResource TangoDividerBrush}" BorderThickness="0 0 0 3" x:Name="navigationCSTLinks" SelectionChanged="TouchNavigationLinks_SelectionChanged" HorizontalContentAlignment="Center"
SelectedIndex="{Binding SelectedTabIndex,Mode=TwoWay}" VerticalAlignment="Bottom" Margin="0,0,0,30" Padding="40 0 40 0"
FontSize="{StaticResource TangoNavigationLinksFontSize}" Grid.RowSpan="2" PreviewMouseDown="NavigationCSTLinks_PreviewMouseDown" PreviewTouchDown="NavigationCSTLinks_PreviewTouchDown" >
<TextBlock HorizontalAlignment="Center" IsEnabled="{Binding IsOnlyManual, Converter={StaticResource BooleanInverseConverter}}" Text="Automatic">
<TextBlock.Style>
<Style TargetType="TextBlock">
<Style.Triggers>
<Trigger Property="IsEnabled" Value="False">
<Setter Property="Foreground" Value="{StaticResource TangoDisabledForegroundBrush}"></Setter>
</Trigger>
</Style.Triggers>
</Style>
</TextBlock.Style>
</TextBlock>
<TextBlock HorizontalAlignment="Center" >Manual</TextBlock>
<touch:TouchNavigationLinks.Style>
<Style TargetType="{x:Type touch:TouchNavigationLinks}">
<Setter Property="ItemsPanel">
<Setter.Value>
<ItemsPanelTemplate>
<StackPanel Orientation="Horizontal"/>
</ItemsPanelTemplate>
</Setter.Value>
</Setter>
</Style>
</touch:TouchNavigationLinks.Style>
</touch:TouchNavigationLinks>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right" Margin="0 0 20 20" >
<TextBlock HorizontalAlignment="Left" VerticalAlignment="Center" FontSize="{StaticResource TangoButtonFontSize}">Length:</TextBlock>
<touch:TouchNumericTextBox Margin="20 0 20 5" Width="80" Height="40" HorizontalAlignment="Stretch" BorderThickness="0.8" Minimum="60" Maximum="999" Value="{Binding FineTuningTrialLengthMeters, Mode=TwoWay}" FontSize="{StaticResource TangoButtonFontSize}" FontWeight="Normal" BorderBrush="{StaticResource TangoDividerBrush}" HideUnderline="True" HasDecimalPoint="False" HorizontalContentAlignment="Center" VerticalContentAlignment="Center"/>
</StackPanel>
</Grid>
<Grid Grid.Row="3" Margin="40 0 20 0">
<Grid Visibility="{Binding IsManualFineTuning, Converter={StaticResource BooleanToVisibilityInverseConverter}}" Margin="0 0 24 0" x:Name="Automatic">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<StackPanel Orientation="Vertical">
<StackPanel.Style >
<Style TargetType="StackPanel">
<Setter Property="IsEnabled" Value="True"/>
<Style.Triggers>
<DataTrigger Binding="{Binding IsJobRunning}" Value="True">
<Setter Property="IsEnabled" Value="False"/>
</DataTrigger>
</Style.Triggers>
</Style>
</StackPanel.Style>
<TextBlock FontSize="{StaticResource TangoComboBoxItemFontSize}">Enter Measurement Result:</TextBlock>
<UniformGrid Rows="3" Columns="1" Height="200" VerticalAlignment="Top" Width="Auto" HorizontalAlignment="Center" Margin="0 10 40 0">
<StackPanel Orientation="Horizontal">
<TextBlock Text="L" FontSize="{StaticResource TangoComboBoxItemFontSize}" FontWeight="SemiBold" VerticalAlignment="Center" />
<touch:TouchNumericTextBox Margin="20 0 20 0" Width="80" Height="40" HorizontalAlignment="Stretch" BorderThickness="0.8" Maximum="100" Minimum="0" Value="{Binding MeasuredL, Delay=1000, Converter={StaticResource DoubleNullConverter}, ConverterParameter=1}" FontSize="{StaticResource TangoButtonFontSize}" FontWeight="Bold" BorderBrush="{StaticResource TangoDividerBrush}" HideUnderline="True" HasDecimalPoint="True" HorizontalContentAlignment="Center" VerticalContentAlignment="Center"/>
</StackPanel>
<StackPanel Orientation="Horizontal" VerticalAlignment="Center">
<TextBlock Text="a" FontSize="{StaticResource TangoComboBoxItemFontSize}" FontWeight="SemiBold" VerticalAlignment="Center"/>
<touch:TouchNumericTextBox Margin="20 0 20 0" Width="80" Height="40" HorizontalAlignment="Stretch" BorderThickness="0.8" Maximum="127" Minimum="-128" Value="{Binding MeasuredA, Delay=1000, Converter={StaticResource DoubleNullConverter}, ConverterParameter=1}" FontSize="{StaticResource TangoButtonFontSize}" FontWeight="Bold" VerticalAlignment="Top" BorderBrush="{StaticResource TangoDividerBrush}" HideUnderline="True" HasDecimalPoint="True" HorizontalContentAlignment="Center" VerticalContentAlignment="Center"/>
</StackPanel>
<StackPanel Orientation="Horizontal">
<TextBlock Text="b" FontSize="{StaticResource TangoComboBoxItemFontSize}" FontWeight="SemiBold" VerticalAlignment="Center"/>
<touch:TouchNumericTextBox Margin="20 0 20 0" Width="80" Height="40" HorizontalAlignment="Stretch" BorderThickness="0.8" Maximum="127" Minimum="-128" Value="{Binding MeasuredB, Delay=1000, Converter={StaticResource DoubleNullConverter}, ConverterParameter=1}" FontSize="{StaticResource TangoButtonFontSize}" FontWeight="Bold" BorderBrush="{StaticResource TangoDividerBrush}" HideUnderline="True" HasDecimalPoint="True" HorizontalContentAlignment="Center" VerticalContentAlignment="Center"/>
</StackPanel>
</UniformGrid>
<touch:TouchCheckBox Margin="0 30 0 0" IsChecked="{Binding CorrectOnlyHue, Mode=TwoWay}" FontSize="{StaticResource TangoButtonFontSize}" FontWeight="Normal" BorderBrush="{StaticResource TangoPrimaryAccentBrush}">Correct Only Hue</touch:TouchCheckBox>
</StackPanel>
<StackPanel Orientation="Vertical" Grid.Column="1">
<TextBlock FontSize="{StaticResource TangoComboBoxItemFontSize}">Result Vs. Target:</TextBlock>
<UniformGrid Grid.Column="1" Columns="4" Rows="1" Height="Auto" VerticalAlignment="Top" Width="Auto" Margin="0 20 0 0">
<StackPanel Orientation="Vertical">
<StackPanel Orientation="Horizontal">
<Polygon Points="7.5,0 15,15, 0,15" Stroke="Black" Fill="Transparent" Margin=" 0 4 0 0"/>
<TextBlock Text="E" FontSize="{StaticResource TangoComboBoxItemFontSize}" FontWeight="SemiBold" VerticalAlignment="Center" Margin="7 0 0 0"/>
</StackPanel>
<TextBlock IsHitTestVisible="False" Text="{Binding DeltaE, StringFormat=0.00, Converter={StaticResource DoubleNullConverter}}" FontSize="{StaticResource TangoDefaultFontSize}" HorizontalAlignment="Left" VerticalAlignment="Center" Margin="0 20 0 0">
<TextBlock.Style>
<Style TargetType="TextBlock">
<Setter Property="Foreground" Value="{StaticResource TangoDarkForegroundBrush}"></Setter>
<Style.Triggers>
<DataTrigger Binding="{Binding DeltaE, Converter={StaticResource SmallerThanToBooleanConverter}, ConverterParameter=2}" Value="True">
<Setter Property="Foreground" Value="{StaticResource TangoGreenBrush}"></Setter>
</DataTrigger>
</Style.Triggers>
</Style>
</TextBlock.Style>
</TextBlock>
</StackPanel>
<StackPanel Orientation="Vertical" Margin="0 0 0 0">
<StackPanel Orientation="Horizontal">
<Polygon Points="7.5,0 15,15, 0,15" Stroke="Black" Fill="Transparent" Margin=" 0 4 0 0"/>
<TextBlock Text="L" FontSize="{StaticResource TangoComboBoxItemFontSize}" FontWeight="SemiBold" VerticalAlignment="Center" Margin="7 0 0 0"/>
</StackPanel>
<TextBlock IsHitTestVisible="False" Text="{Binding DL, StringFormat=0.00, Converter={StaticResource DoubleNullConverter}}" FontSize="{StaticResource TangoDefaultFontSize}" HorizontalAlignment="Left" VerticalAlignment="Center" Margin="0 20 0 0"/>
<TextBlock Text="{Binding DL, Converter={StaticResource DeltaLCHToTextConverter}, ConverterParameter=L}" FontSize="{StaticResource TangoSmallFontSize}" VerticalAlignment="Center" Margin="0 20 0 0"/>
</StackPanel>
<StackPanel Orientation="Vertical">
<StackPanel Orientation="Horizontal">
<Polygon Points="7.5,0 15,15, 0,15" Stroke="Black" Fill="Transparent" Margin=" 0 4 0 0"/>
<TextBlock Text="C" FontSize="{StaticResource TangoComboBoxItemFontSize}" FontWeight="SemiBold" VerticalAlignment="Center" Margin="7 0 0 0"/>
</StackPanel>
<TextBlock IsHitTestVisible="False" Text="{Binding DC, StringFormat=0.00, Converter={StaticResource DoubleNullConverter}}" FontSize="{StaticResource TangoDefaultFontSize}" HorizontalAlignment="Left" VerticalAlignment="Center" Margin="0 20 0 0"/>
<TextBlock Text="{Binding DC, Converter={StaticResource DeltaLCHToTextConverter}, ConverterParameter=C}" FontSize="{StaticResource TangoSmallFontSize}" VerticalAlignment="Center" Margin="0 20 0 0"/>
</StackPanel>
<StackPanel Orientation="Vertical">
<StackPanel Orientation="Horizontal">
<Polygon Points="7.5,0 15,15, 0,15" Stroke="Black" Fill="Transparent" Margin=" 0 4 0 0"/>
<TextBlock Text="H" FontSize="{StaticResource TangoComboBoxItemFontSize}" FontWeight="SemiBold" VerticalAlignment="Center" Margin="7 0 0 0"/>
</StackPanel>
<TextBlock IsHitTestVisible="False" Text="{Binding DH, StringFormat=0.00, Converter={StaticResource DoubleNullConverter}}" FontSize="{StaticResource TangoDefaultFontSize}" HorizontalAlignment="Left" VerticalAlignment="Center" Margin="0 20 0 0"/>
<TextBlock Text="{Binding MeasuredH, Converter={StaticResource DeltaLCHToTextConverter}, ConverterParameter=H}" FontSize="{StaticResource TangoSmallFontSize}" VerticalAlignment="Center" Margin="0 20 0 0"/>
</StackPanel>
</UniformGrid>
</StackPanel>
</Grid>
<Grid x:Name="visualCorrection" Visibility="{Binding IsManualFineTuning, Converter={StaticResource BooleanToVisibilityConverter}}" >
<Grid Margin="0 -20 5 40">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="30"/>
<RowDefinition Height="1*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1.4*"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<StackPanel Orientation="Vertical" Grid.Column="0">
<StackPanel.Style >
<Style TargetType="StackPanel">
<Setter Property="IsEnabled" Value="True"/>
<Style.Triggers>
<DataTrigger Binding="{Binding IsJobRunning}" Value="True">
<Setter Property="IsEnabled" Value="False"/>
</DataTrigger>
</Style.Triggers>
</Style>
</StackPanel.Style>
<TextBlock FontSize="{StaticResource TangoComboBoxItemFontSize}" FontWeight="SemiBold" >Enter Measurement Result (Optional):</TextBlock>
<UniformGrid Rows="1" Columns="3" Height="Auto" VerticalAlignment="Top" Width="Auto" HorizontalAlignment="Left" Margin="0 20 0 0" IsEnabled="{Binding IsOnlyManual, Converter={StaticResource BooleanInverseConverter}}">
<StackPanel Orientation="Vertical" VerticalAlignment="Center">
<TextBlock Text="L" FontSize="{StaticResource TangoComboBoxItemFontSize}" FontWeight="Bold" VerticalAlignment="Center" Margin="10 0 0 0"/>
<touch:TouchNumericTextBox Margin="0 10 5 0" Width="80" Height="40" HorizontalAlignment="Stretch" BorderThickness="0.8" BorderBrush="{StaticResource TangoDividerBrush}" Maximum="100" Minimum="0" Value="{Binding MeasuredL, Delay=1000, Converter={StaticResource DoubleNullConverter}, ConverterParameter=1}" FontSize="{StaticResource TangoButtonFontSize}" FontWeight="Bold" HideUnderline="True" HasDecimalPoint="True" HorizontalContentAlignment="Center" VerticalContentAlignment="Center"/>
</StackPanel>
<StackPanel Orientation="Vertical" VerticalAlignment="Center">
<TextBlock Text="a" FontSize="{StaticResource TangoComboBoxItemFontSize}" FontWeight="Bold" VerticalAlignment="Center" Margin="10 0 0 0"/>
<touch:TouchNumericTextBox Margin="0 10 5 0" Width="80" Height="40" HorizontalAlignment="Stretch" BorderThickness="0.8" BorderBrush="{StaticResource TangoDividerBrush}" Maximum="127" Minimum="-128" Value="{Binding MeasuredA, Delay=1000, Converter={StaticResource DoubleNullConverter}, ConverterParameter=1}" FontSize="{StaticResource TangoButtonFontSize}" FontWeight="Bold" HideUnderline="True" HasDecimalPoint="True" HorizontalContentAlignment="Center" VerticalContentAlignment="Center"/>
</StackPanel>
<StackPanel Orientation="Vertical">
<TextBlock Text="b" FontSize="{StaticResource TangoComboBoxItemFontSize}" FontWeight="Bold" VerticalAlignment="Center" Margin="10 0 0 0"/>
<touch:TouchNumericTextBox Margin="0 10 5 0" Width="80" Height="40" HorizontalAlignment="Stretch" BorderThickness="0.8" BorderBrush="{StaticResource TangoDividerBrush}" Maximum="127" Minimum="-128" Value="{Binding MeasuredB, Delay=1000, Converter={StaticResource DoubleNullConverter}, ConverterParameter=1}" FontSize="{StaticResource TangoButtonFontSize}" FontWeight="Bold" HideUnderline="True" HasDecimalPoint="True" HorizontalContentAlignment="Center" VerticalContentAlignment="Center"/>
</StackPanel>
</UniformGrid>
</StackPanel>
<StackPanel Orientation="Vertical" Grid.Column="1">
<TextBlock FontSize="{StaticResource TangoComboBoxItemFontSize}" >Result Vs. Target:</TextBlock>
<UniformGrid Grid.Column="1" Columns="4" Rows="1" Height="Auto" VerticalAlignment="Top" Width="Auto" Margin="0 20 0 0">
<StackPanel Orientation="Vertical">
<StackPanel Orientation="Horizontal">
<Polygon Points="7.5,0 15,15, 0,15" Stroke="Black" Fill="Transparent" Margin=" 0 4 0 0"/>
<TextBlock Text="E" FontSize="{StaticResource TangoComboBoxItemFontSize}" FontWeight="SemiBold" VerticalAlignment="Center" Margin="7 0 0 0"/>
</StackPanel>
<TextBlock IsHitTestVisible="False" Text="{Binding DeltaE, StringFormat=0.00, Converter={StaticResource DoubleNullConverter}}" FontSize="{StaticResource TangoDefaultFontSize}" HorizontalAlignment="Left" VerticalAlignment="Center" Margin="0 20 0 0">
<TextBlock.Style>
<Style TargetType="TextBlock">
<Setter Property="Foreground" Value="{StaticResource TangoDarkForegroundBrush}"></Setter>
<Style.Triggers>
<DataTrigger Binding="{Binding DeltaE, Converter={StaticResource SmallerThanToBooleanConverter}, ConverterParameter=2}" Value="True">
<Setter Property="Foreground" Value="{StaticResource TangoGreenBrush}"></Setter>
</DataTrigger>
</Style.Triggers>
</Style>
</TextBlock.Style>
</TextBlock>
</StackPanel>
<StackPanel Orientation="Vertical" Margin="0 0 0 0">
<StackPanel Orientation="Horizontal">
<Polygon Points="7.5,0 15,15, 0,15" Stroke="Black" Fill="Transparent" Margin=" 0 4 0 0"/>
<TextBlock Text="L" FontSize="{StaticResource TangoComboBoxItemFontSize}" FontWeight="SemiBold" VerticalAlignment="Center" Margin="7 0 0 0"/>
</StackPanel>
<TextBlock IsHitTestVisible="False" Text="{Binding DL, StringFormat=0.00, Converter={StaticResource DoubleNullConverter}}" FontSize="{StaticResource TangoDefaultFontSize}" HorizontalAlignment="Left" VerticalAlignment="Center" Margin="0 20 0 0"/>
<TextBlock Text="{Binding DL, Converter={StaticResource DeltaLCHToTextConverter}, ConverterParameter=L}" FontSize="{StaticResource TangoSmallFontSize}" VerticalAlignment="Center" Margin="0 20 0 0"/>
</StackPanel>
<StackPanel Orientation="Vertical">
<StackPanel Orientation="Horizontal">
<Polygon Points="7.5,0 15,15, 0,15" Stroke="Black" Fill="Transparent" Margin=" 0 4 0 0"/>
<TextBlock Text="C" FontSize="{StaticResource TangoComboBoxItemFontSize}" FontWeight="SemiBold" VerticalAlignment="Center" Margin="7 0 0 0"/>
</StackPanel>
<TextBlock IsHitTestVisible="False" Text="{Binding DC, StringFormat=0.00, Converter={StaticResource DoubleNullConverter}}" FontSize="{StaticResource TangoDefaultFontSize}" HorizontalAlignment="Left" VerticalAlignment="Center" Margin="0 20 0 0"/>
<TextBlock Text="{Binding DC, Converter={StaticResource DeltaLCHToTextConverter}, ConverterParameter=C}" FontSize="{StaticResource TangoSmallFontSize}" VerticalAlignment="Center" Margin="0 20 0 0"/>
</StackPanel>
<StackPanel Orientation="Vertical">
<StackPanel Orientation="Horizontal">
<Polygon Points="7.5,0 15,15, 0,15" Stroke="Black" Fill="Transparent" Margin=" 0 4 0 0"/>
<TextBlock Text="H" FontSize="{StaticResource TangoComboBoxItemFontSize}" FontWeight="SemiBold" VerticalAlignment="Center" Margin="7 0 0 0"/>
</StackPanel>
<TextBlock IsHitTestVisible="False" Text="{Binding DH, StringFormat=0.00, Converter={StaticResource DoubleNullConverter}}" FontSize="{StaticResource TangoDefaultFontSize}" HorizontalAlignment="Left" VerticalAlignment="Center" Margin="0 20 0 0"/>
<TextBlock Text="{Binding MeasuredH, Converter={StaticResource DeltaLCHToTextConverter}, ConverterParameter=H}" FontSize="{StaticResource TangoSmallFontSize}" VerticalAlignment="Center" Margin="0 20 0 0"/>
</StackPanel>
</UniformGrid>
</StackPanel>
<Rectangle Height="1" Fill="{StaticResource TangoDividerBrush}" Grid.ColumnSpan="2" Grid.Row="1" VerticalAlignment="Center" Margin="0 0 0 0"></Rectangle>
<DockPanel Grid.Row="2" Grid.ColumnSpan="2">
<StackPanel Orientation="Vertical" Margin="0 0 0 0">
<StackPanel.Style >
<Style TargetType="StackPanel">
<Setter Property="IsEnabled" Value="True"/>
<Style.Triggers>
<DataTrigger Binding="{Binding IsJobRunning}" Value="True">
<Setter Property="IsEnabled" Value="False"/>
</DataTrigger>
</Style.Triggers>
</Style>
</StackPanel.Style>
<TextBlock FontSize="{StaticResource TangoComboBoxItemFontSize}" FontWeight="SemiBold" >Enter Manual Correction:</TextBlock>
<Grid Height="Auto" Margin="0 10 0 0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="55"/>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="55"/>
</Grid.ColumnDefinitions>
<Border BorderBrush="Transparent" Background="{Binding VisualCorrectionModel.MinLightness.ColorBrush}" CornerRadius="8" Margin="0 25 0 0" Height="55" >
<TextBlock Text="Darker" HorizontalAlignment="Center" VerticalAlignment="Bottom" Margin="0 0 0 5" FontSize="{StaticResource TangoSmallFontSizeBar}" Foreground="{Binding VisualCorrectionModel.MinLightness.ColorBrush, Converter={StaticResource ColorContrastConverter}}"></TextBlock>
</Border>
<StackPanel Grid.Column="1" Orientation="Vertical" HorizontalAlignment="Center" VerticalAlignment="Top">
<TextBlock Text="Lightness:" HorizontalAlignment="Center" VerticalAlignment="Top" Margin="0 10 0 0" FontSize="{StaticResource TangoDefaultFontSize}"></TextBlock>
<touch:TouchNumericUpDownConrol Margin="10 5 10 0" Height="35" NumericPartWidth="50" HorizontalAlignment="Center" BorderThickness="2" MaxValue="6" MinValue="-6" Style="{StaticResource TouchNumericBorderUpDownControl}" Step="0.5" Value="{Binding LightnessOffset, Mode=TwoWay}" VerticalAlignment="Center" />
</StackPanel>
<Border BorderBrush="Transparent" Background="{Binding VisualCorrectionModel.MaxLightness.ColorBrush}" CornerRadius="8" Grid.Column="2" Height="55" Margin="0 25 0 0" >
<TextBlock Text="Lighter" HorizontalAlignment="Center" VerticalAlignment="Bottom" Margin="0 0 0 5" FontSize="{StaticResource TangoSmallFontSizeBar}" Foreground="{Binding VisualCorrectionModel.MaxLightness.ColorBrush, Converter={StaticResource ColorContrastConverter}}"></TextBlock>
</Border>
</Grid>
<Grid Height="Auto" Margin="0 0 0 0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="55"/>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="55"/>
</Grid.ColumnDefinitions>
<Border BorderBrush="Transparent" Background="{Binding VisualCorrectionModel.MinChroma.ColorBrush}" CornerRadius="8" Margin="0 25 0 0" Height="55">
<TextBlock Text="Duller" HorizontalAlignment="Center" VerticalAlignment="Bottom" Margin="0 0 0 5" FontSize="{StaticResource TangoSmallFontSizeBar}" Foreground="{Binding VisualCorrectionModel.MinChroma.ColorBrush, Converter={StaticResource ColorContrastConverter}}"></TextBlock>
</Border>
<StackPanel Grid.Column="1" Orientation="Vertical" HorizontalAlignment="Center" VerticalAlignment="Top">
<TextBlock Text="Chroma:" HorizontalAlignment="Center" VerticalAlignment="Top" Margin="0 10 0 0" FontSize="{StaticResource TangoDefaultFontSize}" ></TextBlock>
<touch:TouchNumericUpDownConrol Margin="10 5 10 0" Padding="0" Height="35" NumericPartWidth="50" HorizontalAlignment="Center" BorderThickness="2" MaxValue="6" MinValue="-6" Style="{StaticResource TouchNumericBorderUpDownControl}" Step="0.5" Value="{Binding ChromaOffset, Mode=TwoWay}" VerticalAlignment="Center"/>
</StackPanel>
<Border BorderBrush="Transparent" Background="{Binding VisualCorrectionModel.MaxChroma.ColorBrush}" CornerRadius="8" Grid.Column="2" Height="55" Margin="0 25 0 0" >
<TextBlock Text="Brighter" HorizontalAlignment="Center" VerticalAlignment="Bottom" Margin="0 0 0 5" FontSize="{StaticResource TangoSmallFontSizeBar}" Foreground="{Binding VisualCorrectionModel.MaxChroma.ColorBrush, Converter={StaticResource ColorContrastConverter}}"></TextBlock>
</Border>
</Grid>
<Grid Height="Auto" Margin="0 0 0 0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="55"/>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="55"/>
</Grid.ColumnDefinitions>
<Border BorderBrush="Transparent" Background="{Binding VisualCorrectionModel.MinHue.ColorBrush}" CornerRadius="8" Margin="0 25 0 0" Height="55" >
<TextBlock Text="{Binding VisualCorrectionModel.MinHue.H, Converter={StaticResource HueValueToTextConvereter}, ConverterParameter=Min}" HorizontalAlignment="Center" VerticalAlignment="Bottom" Margin="0 0 0 5" FontSize="{StaticResource TangoSmallFontSizeBar}" Foreground="{Binding VisualCorrectionModel.MinHue.ColorBrush, Converter={StaticResource ColorContrastConverter}}"></TextBlock>
</Border>
<StackPanel Grid.Column="1" Orientation="Vertical" HorizontalAlignment="Center" VerticalAlignment="Top">
<TextBlock Text="Hue:" HorizontalAlignment="Center" VerticalAlignment="Top" Margin="0 10 0 0" FontSize="{StaticResource TangoDefaultFontSize}"></TextBlock>
<touch:TouchNumericUpDownConrol Margin="10 5 10 0" Height="35" NumericPartWidth="50" HorizontalAlignment="Center" BorderThickness="2" MaxValue="6" MinValue="-6" Style="{StaticResource TouchNumericBorderUpDownControl}" Step="0.5" Value="{Binding HueOffset, Mode=TwoWay}" VerticalAlignment="Center"/>
</StackPanel>
<Border BorderBrush="Transparent" Background="{Binding VisualCorrectionModel.MaxHue.ColorBrush}" CornerRadius="8" Grid.Column="2" Height="55" Margin="0 25 0 0" >
<TextBlock Text="{Binding VisualCorrectionModel.MaxHue.H, Converter={StaticResource HueValueToTextConvereter}, ConverterParameter=Max}" HorizontalAlignment="Center" VerticalAlignment="Bottom" Margin="0 0 0 5" FontSize="{StaticResource TangoSmallFontSizeBar}" Foreground="{Binding VisualCorrectionModel.MaxHue.ColorBrush, Converter={StaticResource ColorContrastConverter}}"></TextBlock>
</Border>
</Grid>
</StackPanel>
<Grid Height="Auto" Margin="40 0 0 0" VerticalAlignment="Center" HorizontalAlignment="Stretch">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="20"/>
<RowDefinition Height="1*"/>
</Grid.RowDefinitions>
<TextBlock FontSize="{StaticResource TangoComboBoxItemFontSize}" FontWeight="SemiBold" Grid.ColumnSpan="2" VerticalAlignment="Center">Adjustment Preview:</TextBlock>
<StackPanel Orientation="Vertical" Grid.ColumnSpan="2" Grid.Row="1" Margin="0 10 0 0">
<TextBlock FontSize="{StaticResource TangoSmallFontSize}" FontWeight="SemiBold" Margin="10 0 0 -5" >Result</TextBlock>
<Border Grid.Row="1" Height="220" Margin="0 10 0 0" BorderBrush="{StaticResource TangoGrayBrush}" BorderThickness="0" Background="{Binding VisualCorrectionModel.SourceColorBrush}" CornerRadius="12" >
<UniformGrid Rows="3" Columns="1" VerticalAlignment="Bottom" Background="Transparent">
<TextBlock FontWeight="Medium" Margin="10 10 0 0" VerticalAlignment="Center" Foreground="{Binding VisualCorrectionModel.ManualColorBrush, Converter={StaticResource ColorContrastConverter}}" FontSize="{StaticResource TangoSmallFontSize}">
<Run Text="L:" ></Run>
<Run Text="{Binding VisualCorrectionModel.SourceL, StringFormat=0.##}"></Run>
</TextBlock>
<TextBlock FontWeight="Medium" Margin="10 5 0 0" VerticalAlignment="Center" Foreground="{Binding VisualCorrectionModel.ManualColorBrush, Converter={StaticResource ColorContrastConverter}}" FontSize="{StaticResource TangoSmallFontSize}">
<Run Text="a:" ></Run>
<Run Text="{Binding VisualCorrectionModel.SourceA, StringFormat=0.##}" ></Run>
</TextBlock>
<TextBlock FontWeight="Medium" Margin="10 5 0 10" VerticalAlignment="Center" Foreground="{Binding VisualCorrectionModel.ManualColorBrush, Converter={StaticResource ColorContrastConverter}}" FontSize="{StaticResource TangoSmallFontSize}">
<Run Text="b:"></Run>
<Run Text="{Binding VisualCorrectionModel.SourceB, StringFormat=0.##}"></Run>
</TextBlock>
</UniformGrid>
</Border>
</StackPanel>
<StackPanel Orientation="Vertical" Grid.Column="1" Grid.ColumnSpan="1" Grid.Row="1" Margin="0 10 0 0">
<TextBlock FontSize="{StaticResource TangoSmallFontSize}" FontWeight="SemiBold" Margin="10 0 0 -5" HorizontalAlignment="Left" >Correction</TextBlock>
<Border Grid.Row="1" Height="220" Margin="0 10 0 0" CornerRadius="0 0 0 0" BorderThickness="0" BorderBrush="{StaticResource TangoGrayBrush}" Background="{Binding VisualCorrectionModel.ManualColorBrush}" >
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="1*"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<StackPanel Grid.Row="0" Orientation="Vertical" VerticalAlignment="Center" HorizontalAlignment="Center" Visibility="{Binding VisualCorrectionModel.IsOutOfGamut,Converter={StaticResource BooleanToVisibilityConverter}}">
<Image Margin="30 0 24 0" Stretch="Fill" Width="47" Height="43" RenderOptions.BitmapScalingMode="Fant" Source="../Images/ColorSelection/Exclamation.png" HorizontalAlignment="Center"></Image>
<!--<Border Margin=" 0 10 0 0" MinWidth="115" Height="31" Background="{StaticResource TangoDarkForegroundBrush}" CornerRadius="2">
<TextBlock Margin="10 0" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="{StaticResource TangoLightForegroundBrush}" FontSize="{StaticResource TangoSmallFontSize}" FontWeight="SemiBold" Text="This color is not supported." ></TextBlock>
</Border>-->
</StackPanel>
<UniformGrid Grid.Row="1" Rows="3" Columns="1" VerticalAlignment="Bottom" Background="Transparent">
<TextBlock FontWeight="Medium" Margin="10 10 0 0" VerticalAlignment="Center" Foreground="{Binding VisualCorrectionModel.ManualColorBrush, Converter={StaticResource ColorContrastConverter}}" FontSize="{StaticResource TangoSmallFontSize}">
<Run Text="L:" ></Run>
<Run Text="{Binding VisualCorrectionModel.L, StringFormat={}{0:F2}}"></Run>
</TextBlock>
<TextBlock FontWeight="Medium" Margin="10 5 0 0" VerticalAlignment="Center" Foreground="{Binding VisualCorrectionModel.ManualColorBrush, Converter={StaticResource ColorContrastConverter}}" FontSize="{StaticResource TangoSmallFontSize}" >
<Run Text="a:" ></Run>
<Run Text="{Binding VisualCorrectionModel.A, Converter={StaticResource RoundDoubleConverter}}" ></Run>
</TextBlock>
<TextBlock FontWeight="Medium" Margin="10 5 0 10" VerticalAlignment="Center" Foreground="{Binding VisualCorrectionModel.ManualColorBrush, Converter={StaticResource ColorContrastConverter}}" FontSize="{StaticResource TangoSmallFontSize}">
<Run Text="b:"></Run>
<Run Text="{Binding VisualCorrectionModel.B, StringFormat={}{0:F2}}"></Run>
</TextBlock>
</UniformGrid>
</Grid>
</Border>
</StackPanel>
<StackPanel Orientation="Vertical" Grid.Column="2" Grid.Row="1" Margin="0 10 0 0" Visibility="{Binding IsTargetVisible, Converter={StaticResource BooleanToVisibilityConverter}, Mode=TwoWay}">
<TextBlock FontSize="{StaticResource TangoSmallFontSize}" FontWeight="SemiBold" Margin="10 0 0 -5" HorizontalAlignment="Left" >Target</TextBlock>
<Border Grid.Row ="1" Height="220" Margin="0 10 0 0" Background="{Binding ColorBrush}" BorderBrush="{StaticResource TangoGrayBrush}" BorderThickness="0" CornerRadius="0 12 12 0"></Border>
</StackPanel>
</Grid>
</DockPanel>
</Grid>
</Grid>
</Grid>
</Grid>
</Grid>
<Border BorderThickness="0" Grid.RowSpan="01" VerticalAlignment="Bottom">
<!--<Border.Style >
<Style TargetType="Border">
<Setter Property="IsEnabled" Value="True"/>
<Style.Triggers>
<DataTrigger Binding="{Binding IsJobRunning}" Value="True">
<Setter Property="IsEnabled" Value="False"/>
</DataTrigger>
</Style.Triggers>
</Style>
</Border.Style>-->
<touch:TouchExpander Grid.Row="1" x:Name="trailsListExpander" IsExpanded="{Binding IsExpanderOpened, Mode=TwoWay}" Margin="0 0 0 0 " FontSize="{StaticResource TangoSmallFontSize}" BorderThickness="0"
Style="{StaticResource TouchRoundedExpander}" IsTabStop="False" KeyboardNavigation.TabNavigation ="None">
<touch:TouchExpander.Header>
<DockPanel >
<StackPanel Orientation="Horizontal" DockPanel.Dock="Right" Margin="0 0 20 0" Visibility="{Binding IsExpanderOpened, Converter={StaticResource BooleanToVisibilityConverter}, Mode=TwoWay}">
<touch:TouchButton HorizontalAlignment="Right" VerticalAlignment="Center" EnableDropShadow="False" Background="Transparent" BorderThickness="0" Command="{Binding ClearTrialsCommand}" >
<touch:TouchButton.Style>
<Style TargetType="{x:Type touch:TouchButton}">
<Setter Property="IsEnabled" Value="True"/>
<Style.Triggers>
<DataTrigger Binding="{Binding IsJobRunning}" Value="True">
<Setter Property="IsEnabled" Value="False"/>
</DataTrigger>
</Style.Triggers>
</Style>
</touch:TouchButton.Style>
<DockPanel Width="Auto" Height="44" VerticalAlignment="Center">
<Image Source="../Images/ColorSelection/Clear.png" Width="19" DockPanel.Dock="Top"></Image>
<TextBlock DockPanel.Dock="Bottom" Margin="0 8 0 0" VerticalAlignment="Bottom" HorizontalAlignment="Center" FontSize="{StaticResource TangoSmallFontSize}" Foreground="{StaticResource TangoDarkForegroundBrush}">Clear</TextBlock>
</DockPanel>
</touch:TouchButton>
<touch:TouchButton Margin="46 0 20 0" HorizontalAlignment="Right" VerticalAlignment="Center" EnableDropShadow="False" Background="Transparent" BorderThickness="0" Command="{Binding ExportTrialsCommand}" >
<DockPanel Width="Auto" Height="44" VerticalAlignment="Center">
<Image Source="../Images/ColorSelection/Export.png" Width="19" DockPanel.Dock="Top"></Image>
<TextBlock DockPanel.Dock="Bottom" VerticalAlignment="Bottom" HorizontalAlignment="Center" FontSize="{StaticResource TangoSmallFontSize}" Foreground="{StaticResource TangoDarkForegroundBrush}">Export</TextBlock>
</DockPanel>
</touch:TouchButton>
</StackPanel>
<StackPanel DockPanel.Dock="Left" Orientation="Horizontal" VerticalAlignment="Center" >
<Image Source="../Images/JobView/job-summary.png" Width="39" />
<TextBlock FontWeight="Medium" Margin="20 0 0 0" VerticalAlignment="Center">
<Run Text="Trials Log" FontSize="{StaticResource TangoDefaultFontSize}"></Run>
<Run Text="(Max 10 Trials)" FontWeight="Normal"></Run></TextBlock>
</StackPanel>
</DockPanel>
</touch:TouchExpander.Header>
<Grid Margin=" 0 10 0 0" >
<touch:LightTouchDataGrid MaxHeight="450" AnimateSorting="False" EnableDragAndDrop="False" RenderOptions.EdgeMode="Unspecified" x:Name="dataGridTrialsLog" Style="{StaticResource TangoJobsGrid}" SelectedItem="{Binding SelectedLog, Mode=TwoWay}" SelectionMode="Single" IsMultiSelecting="False" ItemsSource="{Binding TrialsLogitems, Mode=OneWay}" Margin="0">
<touch:LightTouchDataGrid.Resources>
<Style TargetType="{x:Type touch:LightTouchDataGridRow}">
<Setter Property="Background" Value="{StaticResource TangoPrimaryBackgroundBrush}"></Setter>
<Setter Property="Foreground" Value="{StaticResource TangoDarkForegroundBrush}"></Setter>
<Setter Property="BorderThickness" Value="1"></Setter>
<Setter Property="BorderBrush" Value="{StaticResource TangoLightBorderBrush}"></Setter>
<Setter Property="Padding" Value="5"></Setter>
<Setter Property="CornerRadius" Value="2"></Setter>
<Setter Property="Margin" Value="5 8 0 0"></Setter>
<Setter Property="Height" Value="44"></Setter>
<Setter Property="IsEnabled" Value="True"/>
<Style.Triggers>
<DataTrigger Binding="{Binding IsSelectionEnable}" Value="False">
<Setter Property="IsEnabled" Value="False"/>
</DataTrigger>
<DataTrigger Binding="{Binding DataContext.IsJobRunning, RelativeSource={RelativeSource FindAncestor,AncestorType={x:Type touch:LightTouchDataGrid}}}" Value="True">
<Setter Property="IsEnabled" Value="False"/>
</DataTrigger>
</Style.Triggers>
</Style>
</touch:LightTouchDataGrid.Resources>
<touch:LightTouchDataGrid.Columns>
<touch:LightTouchDataGridColumn Width="50" Header="#" >
<touch:LightTouchDataGridColumn.CellTemplate >
<DataTemplate>
<TextBlock IsHitTestVisible="False" Text="{Binding Trial}" FontSize="{StaticResource TangoSmallFontSize}" HorizontalAlignment="Left" VerticalAlignment="Center"></TextBlock>
</DataTemplate>
</touch:LightTouchDataGridColumn.CellTemplate>
</touch:LightTouchDataGridColumn>
<touch:LightTouchDataGridColumn Width="140" Header="Date" HorizontalContentAlignment="Left">
<touch:LightTouchDataGridColumn.CellTemplate>
<DataTemplate>
<TextBlock IsHitTestVisible="False" Text="{Binding Date,Converter={StaticResource DateTimeUTCToShortDateTimeConverter}}" FontSize="{StaticResource TangoSmallFontSize}" HorizontalAlignment="Left" ></TextBlock>
</DataTemplate>
</touch:LightTouchDataGridColumn.CellTemplate>
</touch:LightTouchDataGridColumn>
<touch:LightTouchDataGridColumn Width="200" Header="CMYK" HorizontalContentAlignment="Left">
<touch:LightTouchDataGridColumn.CellTemplate>
<DataTemplate>
<TextBlock IsHitTestVisible="False" Text="{Binding CMYK}" FontSize="{StaticResource TangoSmallFontSize}" HorizontalAlignment="Left" VerticalAlignment="Center"></TextBlock>
</DataTemplate>
</touch:LightTouchDataGridColumn.CellTemplate>
</touch:LightTouchDataGridColumn>
<touch:LightTouchDataGridColumn Width="1*" Header="Measured L*a*b*" HorizontalContentAlignment="Left">
<touch:LightTouchDataGridColumn.CellTemplate>
<DataTemplate>
<TextBlock IsHitTestVisible="False" Text="{Binding LAB}" FontSize="{StaticResource TangoSmallFontSize}" HorizontalAlignment="Left" VerticalAlignment="Center"></TextBlock>
</DataTemplate>
</touch:LightTouchDataGridColumn.CellTemplate>
</touch:LightTouchDataGridColumn>
<touch:LightTouchDataGridColumn Header="dE(CMC)" Width="85" HorizontalContentAlignment="Left">
<touch:LightTouchDataGridColumn.CellTemplate>
<DataTemplate>
<DockPanel>
<TextBlock DockPanel.Dock="Left" IsHitTestVisible="False" Text="{Binding DeltaEDisplay}" FontSize="{StaticResource TangoSmallFontSize}" HorizontalAlignment="Left" VerticalAlignment="Center" Margin="0 0 10 0">
<TextBlock.Style>
<Style TargetType="TextBlock">
<Setter Property="Foreground" Value="{StaticResource TangoDarkForegroundBrush}"></Setter>
<Style.Triggers>
<DataTrigger Binding="{Binding DeltaE, Converter={StaticResource SmallerThanToBooleanConverter}, ConverterParameter=2}" Value="True">
<Setter Property="Foreground" Value="{StaticResource TangoGreenBrush}"></Setter>
</DataTrigger>
</Style.Triggers>
</Style>
</TextBlock.Style>
</TextBlock>
<touch:TouchButton DockPanel.Dock="Right" HorizontalAlignment="Right" VerticalAlignment="Center" EnableDropShadow="False" Background="Transparent" BorderThickness="0" Command="{Binding DataContext.DeleteTrialCommand, RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type touch:LightTouchDataGrid}}}" >
<DockPanel Width="Auto" Height="44" VerticalAlignment="Center">
<Image Source="../Images/ColorSelection/Clear.png" Width="19" DockPanel.Dock="Top"></Image>
</DockPanel>
<touch:TouchButton.Style>
<Style TargetType="touch:TouchButton">
<Setter Property="Visibility" Value="Hidden"></Setter>
<Style.Triggers>
<DataTrigger Binding="{Binding RelativeSource={RelativeSource AncestorType=touch:LightTouchDataGridRow},Path=IsSelected}" Value="True">
<Setter Property="Visibility" Value="Visible"></Setter>
</DataTrigger>
</Style.Triggers>
</Style>
</touch:TouchButton.Style>
</touch:TouchButton>
</DockPanel>
</DataTemplate>
</touch:LightTouchDataGridColumn.CellTemplate>
</touch:LightTouchDataGridColumn>
</touch:LightTouchDataGrid.Columns>
</touch:LightTouchDataGrid>
</Grid>
</touch:TouchExpander>
</Border>
<DockPanel Grid.Row="2" Margin="0 20 0 41" Background="{StaticResource TangoPrimaryBackgroundBrush}" >
<touch:TouchButton DockPanel.Dock="Right" HorizontalAlignment="Center" CornerRadius="25" Command="{Binding OKCommand}" Width="200" Height="50" VerticalAlignment="Bottom" TextElement.Foreground="{StaticResource TangoLightForegroundBrush}" FontSize="{StaticResource TangoButtonFontSize}" ShadowDepth="0" Content="APPLY" Margin="0 0 82 0">
<touch:TouchButton.Style >
<Style TargetType="touch:TouchButton" >
<Setter Property="Foreground" Value="{StaticResource TangoPrimaryAccentBrush}"></Setter>
<Setter Property="Background" Value="{StaticResource TangoPrimaryAccentBrush}"/>
<Style.Triggers>
<Trigger Property="IsEnabled" Value="False">
<Setter Property="Foreground" Value="{StaticResource TangoDisabledForegroundBrush}"></Setter>
<Setter Property="Background" Value="{StaticResource TangoDisabledBackgroundBrush}"></Setter>
</Trigger>
</Style.Triggers>
</Style>
</touch:TouchButton.Style>
</touch:TouchButton>
<touch:TouchButton x:Name="VFTCancelBtn" HorizontalAlignment="Left" Margin="82 0 0 0" BorderThickness="1" RippleBrush="{StaticResource TangoRippleDarkBrush}" CornerRadius="25" Command="{Binding CloseCommand}" Width="200" Height="50" VerticalAlignment="Bottom" FontSize="{StaticResource TangoButtonFontSize}" ShadowDepth="0" Content="EXIT" EnableDropShadow="False" >
<touch:TouchButton.Style >
<Style TargetType="touch:TouchButton" >
<Setter Property="IsEnabled" Value="True"/>
<Setter Property="Foreground" Value="{StaticResource TangoPrimaryAccentBrush}"></Setter>
<Setter Property="BorderBrush" Value="{StaticResource TangoPrimaryAccentBrush}"></Setter>
<Setter Property="TextElement.Foreground" Value="{StaticResource TangoPrimaryAccentBrush}"></Setter>
<Setter Property="Background" Value="Transparent"/>
<Style.Triggers>
<DataTrigger Binding="{Binding IsJobRunning}" Value="True">
<Setter Property="IsEnabled" Value="False"/>
<Setter Property="Foreground" Value="{StaticResource TangoDisabledForegroundBrush}"></Setter>
<Setter Property="TextElement.Foreground" Value="{StaticResource TangoDisabledForegroundBrush}"></Setter>
<Setter Property="BorderBrush" Value="{StaticResource TangoDisabledForegroundBrush}"></Setter>
</DataTrigger>
</Style.Triggers>
</Style>
</touch:TouchButton.Style>
</touch:TouchButton>
</DockPanel>
</Grid>
</Border>
</Border>
</Grid>
</UserControl>
|