aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobView.xaml
blob: 557576d22a2fb24efde501d4eb5f04d85f0b875a (plain)
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
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
                    xmlns:local="clr-namespace:Tango.Touch.Controls">

    <ResourceDictionary.MergedDictionaries>
        <ResourceDictionary Source="../Resources/Colors.xaml" />
    </ResourceDictionary.MergedDictionaries>

    <Style x:Key="TouchScrollBarThumb" TargetType="{x:Type Thumb}">
        <Setter Property="OverridesDefaultStyle" Value="true"/>
        <Setter Property="IsTabStop" Value="false"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type Thumb}">
                    <Border Height="{TemplateBinding Height}" SnapsToDevicePixels="True" Width="{TemplateBinding Width}" CornerRadius="5" Background="#90000000" />
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="TouchScrollBar" TargetType="{x:Type ScrollBar}">
        <Setter Property="Stylus.IsPressAndHoldEnabled" Value="false"/>
        <Setter Property="Stylus.IsFlicksEnabled" Value="false"/>
        <Setter Property="Background" Value="#33000000"/>
        <Setter Property="BorderBrush" Value="#33000000"/>
        <Setter Property="Foreground" Value="Gray"/>
        <Setter Property="BorderThickness" Value="0"/>
        <Setter Property="Width" Value="5"/>
        <Setter Property="MinWidth" Value="5"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type ScrollBar}">
                    <Grid x:Name="Bg" SnapsToDevicePixels="true" Background="{TemplateBinding Background}">
                        <Border BorderBrush="{TemplateBinding BorderBrush}" HorizontalAlignment="Right" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" Grid.Row="1"/>
                        <Track x:Name="PART_Track" IsDirectionReversed="true" HorizontalAlignment="Right" Width="5" IsEnabled="{TemplateBinding IsMouseOver}" Grid.Row="1">
                            <Track.Thumb>
                                <Thumb Style="{StaticResource TouchScrollBarThumb}"></Thumb>
                            </Track.Thumb>
                        </Track>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style TargetType="{x:Type local:TouchScrollViewer}">
        <Setter Property="HorizontalScrollBarVisibility" Value="Disabled"></Setter>
        <Setter Property="PanningMode" Value="VerticalOnly"></Setter>
        <Setter Property="VerticalScrollBarVisibility" Value="Visible"></Setter>
        <Setter Property="Focusable" Value="False"></Setter>
        <Setter Property="CanContentScroll" Value="true"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type ScrollViewer}">
                    <Grid>
                        <Grid.RowDefinitions>
                            <RowDefinition Height="Auto"/>
                            <RowDefinition Height="*"/>
                        </Grid.RowDefinitions>

                        <DataGridColumnHeadersPresenter x:Name="PART_ColumnHeadersPresenter" Visibility="{Binding HeadersVisibility, ConverterParameter={x:Static DataGridHeadersVisibility.Column}, Converter={x:Static DataGrid.HeadersVisibilityConverter}, RelativeSource={RelativeSource AncestorType={x:Type DataGrid}}}"/>
                        <ScrollContentPresenter x:Name="PART_ScrollContentPresenter" CanContentScroll="{TemplateBinding CanContentScroll}" Grid.Row="1"/>
                        <ScrollBar Opacity="0" Grid.Row="1" x:Name="PART_VerticalScrollBar" Style="{StaticResource TouchScrollBar}" HorizontalAlignment="Right" AutomationProperties.AutomationId="VerticalScrollBar" Cursor="Arrow" Grid.Column="1" Maximum="{TemplateBinding ScrollableHeight}" Minimum="0" Visibility="{TemplateBinding ComputedVerticalScrollBarVisibility}" Value="{Binding VerticalOffset, Mode=OneWay, RelativeSource={RelativeSource TemplatedParent}}" ViewportSize="{TemplateBinding ViewportHeight}"/>
                    </Grid>

                    <ControlTemplate.Triggers>
                        <EventTrigger RoutedEvent="ScrollViewer.ScrollChanged">
                            <EventTrigger.Actions>
                                <BeginStoryboard>
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetName="PART_VerticalScrollBar" Storyboard.TargetProperty="Opacity" Duration="00:00:01" FillBehavior="Stop">
                                            <EasingDoubleKeyFrame KeyTime="00:00:0.2" Value="1"></EasingDoubleKeyFrame>
                                            <DiscreteDoubleKeyFrame KeyTime="00:00:0.2" Value="1"></DiscreteDoubleKeyFrame>
                                            <EasingDoubleKeyFrame KeyTime="00:00:01" Value="0"></EasingDoubleKeyFrame>
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </BeginStoryboard>
                            </EventTrigger.Actions>
                        </EventTrigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
</ResourceDictionary>
href='#n451'>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 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239
<UserControl x:Class="Tango.PPC.Jobs.Views.JobView"
             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:vm="clr-namespace:Tango.PPC.Jobs.ViewModels"
             xmlns:fa="http://schemas.fontawesome.io/icons/"
             xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch"
             xmlns:keyboard="clr-namespace:Tango.Touch.Keyboard;assembly=Tango.Touch"
             xmlns:global="clr-namespace:Tango.PPC.Jobs"
             xmlns:controls="clr-namespace:Tango.SharedUI.Controls;assembly=Tango.SharedUI"
             xmlns:enumerations="clr-namespace:Tango.BL.Enumerations;assembly=Tango.BL"
             xmlns:converters="clr-namespace:Tango.SharedUI.Converters;assembly=Tango.SharedUI"
             xmlns:entities="clr-namespace:Tango.BL.Entities;assembly=Tango.BL"
             xmlns:localConverters="clr-namespace:Tango.PPC.Jobs.Converters"
             xmlns:dragAndDrop="clr-namespace:Tango.DragAndDrop;assembly=Tango.DragAndDrop"
             xmlns:localControls="clr-namespace:Tango.PPC.Jobs.Controls"
             xmlns:local="clr-namespace:Tango.PPC.Jobs.Views"
             mc:Ignorable="d" 
             d:DesignHeight="2000" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:JobViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.JobViewVM}" x:Name="view">

    <UserControl.Resources>

        <localConverters:ColorSpaceToVisibilityConverter x:Key="ColorSpaceToVisibilityConverter" />
        <localConverters:JobToEmbroideryImageConverter x:Key="JobToEmbroideryImageConverter" />
        <BitmapImage x:Key="Image_Out_Of_Gamut" UriSource="../Images/JobView/error.png" />
        <BitmapImage x:Key="Image_Replace_Color" UriSource="../Images/JobView/replace-color.png" />
        <BitmapImage x:Key="Image_Color_Picker" UriSource="../Images/JobView/color-picker.png" />
        <BitmapImage x:Key="Image_Transparent" UriSource="../Images/JobView/transparent.jpg" />
        <BitmapImage x:Key="Image_TransparentSmall" UriSource="../Images/JobView/transparent_small.jpg" />


        <Style TargetType="FrameworkElement" x:Key="Level1Container">
            <Setter Property="Margin" Value="20 15 60 15"></Setter>
        </Style>
        <Style TargetType="FrameworkElement" x:Key="Level2Container">
            <Setter Property="Margin" Value="80 30 60 0"></Setter>
        </Style>
        <Style TargetType="FrameworkElement" x:Key="Level2ContainerExtraMargin">
            <Setter Property="Margin" Value="80 40 60 0"></Setter>
        </Style>

        <DataTemplate x:Key="Volume_Template" DataType="{x:Type entities:BrushStop}">
            <Grid>
                <ItemsControl ItemsSource="{Binding LiquidVolumesOrderedPigmented}" VerticalAlignment="Center" Margin="0 0 -90 0">
                    <ItemsControl.ItemsPanel>
                        <ItemsPanelTemplate>
                            <StackPanel VerticalAlignment="Center" Orientation="Horizontal" IsItemsHost="True"></StackPanel>
                        </ItemsPanelTemplate>
                    </ItemsControl.ItemsPanel>
                    <ItemsControl.ItemTemplate>
                        <DataTemplate>
                            <Border>
                                <touch:TouchNumericTextBox DisplayWatermarkHint="True" Width="50" Watermark="{Binding IdsPack.LiquidType.Name,IsAsync=True}" Margin="2 0" ValueChanged="OnLiquidVolumeFieldValueChanged" HorizontalContentAlignment="Center" Value="{Binding Volume}" keyboard:KeyboardView.Container="{Binding ElementName=Container}" HasDecimalPoint="True" Minimum="0" Maximum="200" JoggingFactor="0.5" StringFormat="0.0"  />
                            </Border>
                        </DataTemplate>
                    </ItemsControl.ItemTemplate>
                </ItemsControl>

                <Canvas VerticalAlignment="Bottom" Visibility="{Binding IsLiquidVolumesOutOfRange,Converter={StaticResource BooleanToVisibilityConverter}}">
                    <TextBlock Canvas.Top="2" Foreground="{StaticResource TangoErrorBrush}" FontSize="{StaticResource TangoSmallFontSize}" Text="Liquid volumes are out of range."></TextBlock>
                </Canvas>
            </Grid>
        </DataTemplate>

        <DataTemplate x:Key="RGB_Template" DataType="{x:Type entities:BrushStop}">
            <UniformGrid Rows="1" Columns="3">
                <touch:TouchNumericTextBox Margin="2 0" ValueChanged="OnBrushStopFieldValueChanged" HorizontalContentAlignment="Center" Value="{Binding Red}" keyboard:KeyboardView.Container="{Binding ElementName=Container}" Maximum="255" />
                <touch:TouchNumericTextBox Margin="2 0" ValueChanged="OnBrushStopFieldValueChanged" HorizontalContentAlignment="Center" Value="{Binding Green}" keyboard:KeyboardView.Container="{Binding ElementName=Container}" Maximum="255" />
                <touch:TouchNumericTextBox Margin="2 0" ValueChanged="OnBrushStopFieldValueChanged" HorizontalContentAlignment="Center" Value="{Binding Blue}" keyboard:KeyboardView.Container="{Binding ElementName=Container}" Maximum="255" />
            </UniformGrid>
        </DataTemplate>

        <DataTemplate x:Key="CMYK_Template" DataType="{x:Type entities:BrushStop}">
            <UniformGrid Rows="1" Columns="4">
                <touch:TouchNumericTextBox Margin="2 0" ValueChanged="OnBrushStopFieldValueChanged" HorizontalContentAlignment="Center" Value="{Binding Cyan,Converter={StaticResource OneToPercentConverter}}" keyboard:KeyboardView.Container="{Binding ElementName=Container}" HasDecimalPoint="True" Maximum="100"  StringFormat="0"  />
                <touch:TouchNumericTextBox Margin="2 0" ValueChanged="OnBrushStopFieldValueChanged" HorizontalContentAlignment="Center" Value="{Binding Magenta,Converter={StaticResource OneToPercentConverter}}" keyboard:KeyboardView.Container="{Binding ElementName=Container}" HasDecimalPoint="True" Maximum="100" StringFormat="0" />
                <touch:TouchNumericTextBox Margin="2 0" ValueChanged="OnBrushStopFieldValueChanged" HorizontalContentAlignment="Center" Value="{Binding Yellow,Converter={StaticResource OneToPercentConverter}}" keyboard:KeyboardView.Container="{Binding ElementName=Container}" HasDecimalPoint="True" Maximum="100" StringFormat="0" />
                <touch:TouchNumericTextBox Margin="2 0" ValueChanged="OnBrushStopFieldValueChanged" HorizontalContentAlignment="Center" Value="{Binding Black,Converter={StaticResource OneToPercentConverter}}" keyboard:KeyboardView.Container="{Binding ElementName=Container}" HasDecimalPoint="True" Maximum="100" StringFormat="0" />
            </UniformGrid>
        </DataTemplate>

        <DataTemplate x:Key="LAB_Template" DataType="{x:Type entities:BrushStop}">
            <UniformGrid Rows="1" Columns="3">
                <touch:TouchNumericTextBox Margin="2 0" ValueChanged="OnBrushStopFieldValueChanged" HorizontalContentAlignment="Center" Value="{Binding L}" keyboard:KeyboardView.Container="{Binding ElementName=Container}" HasDecimalPoint="True" Minimum="0" Maximum="100" StringFormat="0.00" />
                <touch:TouchNumericTextBox Margin="2 0" ValueChanged="OnBrushStopFieldValueChanged" HorizontalContentAlignment="Center" Value="{Binding A}" keyboard:KeyboardView.Container="{Binding ElementName=Container}" HasDecimalPoint="True" Minimum="-128" Maximum="128" StringFormat="0.00" />
                <touch:TouchNumericTextBox Margin="2 0" ValueChanged="OnBrushStopFieldValueChanged" HorizontalContentAlignment="Center" Value="{Binding B}" keyboard:KeyboardView.Container="{Binding ElementName=Container}" HasDecimalPoint="True" Minimum="-128" Maximum="128" StringFormat="0.00" />
            </UniformGrid>
        </DataTemplate>

        <DataTemplate x:Key="CATALOG_Template" DataType="{x:Type entities:BrushStop}">
            <DockPanel>
                <touch:TouchIconButton Margin="0 0 -50 -10" CornerRadius="50" Width="50" Height="50" Padding="13" RippleBrush="{StaticResource TangoRippleDarkBrush}" DockPanel.Dock="Right" Icon="Palette" Foreground="{StaticResource TangoPrimaryAccentBrush}" Command="{Binding RelativeSource={RelativeSource AncestorType=UserControl},Path=DataContext.OpenCatalogCommand}" CommandParameter="{Binding}"></touch:TouchIconButton>
                <touch:TouchAutoComplete Margin="2 0" ItemsSource="{Binding ElementName=view,Path=DataContext.CatalogItems}" Watermark="Color Code" PopupHeight="250" DisplayMemberPath="Name" AutoCompleteProvider="{Binding ElementName=view,Path=DataContext.CatalogAutoCompleteProvider}" SelectedItem="{Binding ColorCatalogsItem,Mode=TwoWay,ValidatesOnDataErrors=True,ValidatesOnNotifyDataErrors=True}" keyboard:KeyboardView.Container="{Binding ElementName=Container}">
                    <touch:TouchAutoComplete.ItemTemplate>
                        <DataTemplate>
                            <DockPanel Margin="2">
                                <Rectangle Width="24" Height="24">
                                    <Rectangle.Fill>
                                        <SolidColorBrush Color="{Binding Color,Mode=OneWay}"></SolidColorBrush>
                                    </Rectangle.Fill>
                                </Rectangle>
                                <TextBlock Margin="5 0 0 0" Text="{Binding Name}" VerticalAlignment="Center"></TextBlock>
                            </DockPanel>
                        </DataTemplate>
                    </touch:TouchAutoComplete.ItemTemplate>
                </touch:TouchAutoComplete>
            </DockPanel>
        </DataTemplate>

        <DataTemplate x:Key="BrushStop_Template" DataType="{x:Type entities:BrushStop}">
            <Grid Margin="50 20 140 20">
                <StackPanel>
                    <StackPanel Orientation="Horizontal">
                        <Border Width="48" Height="48" CornerRadius="5" BorderThickness="1" BorderBrush="{StaticResource TangoGrayBrush}">
                            <Border.Style>
                                <Style TargetType="Border">
                                    <Setter Property="Background">
                                        <Setter.Value>
                                            <SolidColorBrush Color="{Binding Color,IsAsync=True}" />
                                        </Setter.Value>
                                    </Setter>
                                    <Style.Triggers>
                                        <DataTrigger Binding="{Binding IsTransparent,IsAsync=True}" Value="True" >
                                            <Setter Property="Background">
                                                <Setter.Value>
                                                    <ImageBrush ImageSource="{StaticResource Image_TransparentSmall}" Stretch="None" />
                                                </Setter.Value>
                                            </Setter>
                                        </DataTrigger>
                                    </Style.Triggers>
                                </Style>
                            </Border.Style>
                        </Border>

                        <TextBlock Margin="30 0 0 0" FontSize="{StaticResource TangoTitleFontSize}">
                                                                                        <Run>#</Run><Run Text="{Binding Segment.SegmentIndex}"></Run><Run>.</Run><Run Text="{Binding StopIndex}"></Run>
                        </TextBlock>
                    </StackPanel>

                    <DockPanel LastChildFill="False" Margin="0 20 0 0">
                        <TextBlock VerticalAlignment="Bottom" DockPanel.Dock="Left">Color code:</TextBlock>
                        <ContentControl Focusable="False" Margin="20 0 0 0" DockPanel.Dock="Right" HorizontalAlignment="Right" Width="300" Content="{Binding}">
                            <ContentControl.Style>
                                <Style TargetType="ContentControl">
                                    <Setter Property="ContentTemplate">
                                        <Setter.Value>
                                            <DataTemplate/>
                                        </Setter.Value>
                                    </Setter>
                                    <Style.Triggers>
                                        <DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="RGB">
                                            <Setter Property="ContentTemplate" Value="{StaticResource RGB_Template}" />
                                        </DataTrigger>
                                        <DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="CMYK">
                                            <Setter Property="ContentTemplate" Value="{StaticResource CMYK_Template}" />
                                        </DataTrigger>
                                        <DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="LAB">
                                            <Setter Property="ContentTemplate" Value="{StaticResource LAB_Template}" />
                                        </DataTrigger>
                                        <DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="Catalog">
                                            <Setter Property="ContentTemplate" Value="{StaticResource CATALOG_Template}" />
                                        </DataTrigger>
                                        <DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="Volume">
                                            <Setter Property="ContentTemplate" Value="{StaticResource Volume_Template}" />
                                        </DataTrigger>
                                        <DataTrigger Binding="{Binding IsTransparent,IsAsync=True}" Value="True">
                                            <Setter Property="ContentTemplate">
                                                <Setter.Value>
                                                    <DataTemplate>
                                                        <Grid Height="40">
                                                            <TextBlock VerticalAlignment="Bottom" Foreground="{StaticResource TangoGrayBrush}">Transparent</TextBlock>
                                                        </Grid>
                                                    </DataTemplate>
                                                </Setter.Value>
                                            </Setter>
                                        </DataTrigger>
                                    </Style.Triggers>
                                </Style>
                            </ContentControl.Style>
                        </ContentControl>
                    </DockPanel>

                    <Canvas Visibility="{Binding IsOutOfGamut,IsAsync=True,Converter={StaticResource BooleanToVisibilityConverter}}">
                        <TextBlock Canvas.Top="2" Foreground="{StaticResource TangoErrorBrush}" FontSize="{StaticResource TangoSmallFontSize}" Text="Color is out of gamut. Modify color or select an alternative."></TextBlock>
                    </Canvas>

                    <DockPanel LastChildFill="False" Margin="0 20 0 0" IsEnabled="{Binding IsMiddle}">
                        <TextBlock VerticalAlignment="Bottom" DockPanel.Dock="Left">Position (m):</TextBlock>
                        <Grid Margin="20 0 0 0" Width="300" DockPanel.Dock="Right">
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="1*" />
                                <ColumnDefinition Width="2*" />
                            </Grid.ColumnDefinitions>

                            <touch:TouchNumericTextBox Value="{Binding OffsetMeters}" HasDecimalPoint="True" StringFormat="0.0" Maximum="{Binding Segment.Length}" KeyboardContainer="{Binding ElementName=Container}"></touch:TouchNumericTextBox>
                            <!--<touch:TouchSlider Grid.Column="1" Height="30" Margin="10 0 0 -23" Maximum="{Binding Segment.Length}" Value="{Binding OffsetMeters}" />-->
                        </Grid>
                    </DockPanel>
                </StackPanel>

                <StackPanel Orientation="Horizontal" Margin="0 0 -130 0" HorizontalAlignment="Right" VerticalAlignment="Top">
                    <StackPanel Orientation="Horizontal" Visibility="{Binding ElementName=toggleEdit,Path=IsChecked,IsAsync=True,Converter={StaticResource BooleanToVisibilityInverseConverter}}">
                        <!--<touch:TouchToggleIconButton Padding="15" Width="60" Height="60" CornerRadius="30" Icon="EyeOutline" CheckedIcon="EyeOffOutline" Foreground="{StaticResource TangoGrayBrush}" CheckedForeground="{StaticResource TangoGrayBrush}" IsChecked="{Binding IsTransparent,IsAsync=True}"></touch:TouchToggleIconButton>-->
                        <touch:TouchImageButton Command="{Binding ElementName=view,Path=DataContext.ReplaceBrushStopCommand,IsAsync=True}" CommandParameter="{Binding}" Visibility="{Binding ColorSpace,Converter={StaticResource ColorSpaceToVisibilityConverter},IsAsync=True}" Width="50" Height="50" Padding="10" Image="{StaticResource Image_Replace_Color}" CornerRadius="30"></touch:TouchImageButton>
                    </StackPanel>
                    <touch:TouchIconButton Margin="0 0 50 0" Visibility="{Binding ElementName=toggleEdit,Path=IsChecked,Converter={StaticResource BooleanToVisibilityConverter}}" Command="{Binding ElementName=view,Path=DataContext.RemoveBrushStopCommand,IsAsync=True}" CommandParameter="{Binding}" EnableDropShadow="False" Icon="TrashAltRegular" Padding="12" Foreground="{StaticResource TangoPrimaryAccentBrush}" Width="50" Height="50" RippleBrush="{StaticResource TangoRippleDarkBrush}" CornerRadius="30" />
                </StackPanel>
            </Grid>
        </DataTemplate>

        <DataTemplate x:Key="Segment_Template" DataType="{x:Type entities:Segment}">
            <touch:TouchVirtualizedContentControl Margin="0 0 0 15">
                <Border RenderOptions.EdgeMode="Unspecified" CornerRadius="8" Background="{StaticResource TangoPrimaryBackgroundBrush}" BorderThickness="1" BorderBrush="{StaticResource TangoGrayBrush}">
                    <Border.CacheMode>
                        <BitmapCache RenderAtScale="1" SnapsToDevicePixels="True" />
                    </Border.CacheMode>
                    <!--<Border.Effect>
                    <DropShadowEffect Opacity="0.5" Color="{StaticResource TangoDropShadowColor}" BlurRadius="10" ShadowDepth="15" />
                </Border.Effect>-->
                    <Grid>
                        <Grid.RowDefinitions>
                            <RowDefinition Height="Auto" />
                            <RowDefinition Height="Auto" />
                        </Grid.RowDefinitions>
                        <Grid Background="Transparent" dragAndDrop:DragAndDropService.DropCommand="{Binding ElementName=view,Path=DataContext.SegmentDroppedCommand}"  dragAndDrop:DragAndDropService.Draggable="True" dragAndDrop:DragAndDropService.Droppable="True" dragAndDrop:DragAndDropService.DraggingSurface="{Binding ElementName=DraggingSurface}">
                            <Grid.Style>
                                <Style TargetType="Grid">
                                    <Setter Property="Opacity" Value="1"></Setter>
                                    <Style.Triggers>
                                        <Trigger Property="dragAndDrop:DragAndDropService.IsDraggableOver" Value="True">
                                            <Setter Property="Opacity" Value="0.5"></Setter>
                                        </Trigger>
                                    </Style.Triggers>
                                </Style>
                            </Grid.Style>
                            <DockPanel>
                                <DockPanel.Style>
                                    <Style TargetType="DockPanel">
                                        <Setter Property="Height" Value="163"></Setter>
                                        <Style.Triggers>
                                            <DataTrigger Binding="{Binding ElementName=toggle_small_list,Path=IsChecked,IsAsync=True}" Value="True">
                                                <Setter Property="Height" Value="74"></Setter>
                                            </DataTrigger>
                                        </Style.Triggers>
                                    </Style>
                                </DockPanel.Style>

                                <Border DockPanel.Dock="Left" BorderThickness="0 0 1 0" BorderBrush="{StaticResource TangoLightBorderBrush}">
                                    <Border.Background>
                                        <ImageBrush ImageSource="{StaticResource Image_Transparent}" Stretch="None" />
                                    </Border.Background>
                                    <Border.Style>
                                        <Style TargetType="Border">
                                            <Setter Property="CornerRadius" Value="8 0 0 8"></Setter>
                                            <Setter Property="Width" Value="{Binding RelativeSource={RelativeSource Self},Path=ActualHeight,IsAsync=True}"></Setter>
                                            <Style.Triggers>
                                                <DataTrigger Binding="{Binding ElementName=toggle_small_list,Path=IsChecked,IsAsync=True}" Value="True">
                                                    <Setter Property="Width" Value="{Binding RelativeSource={RelativeSource Self},Path=ActualHeight,Converter={StaticResource MathOperatorConverter},ConverterParameter='*2',IsAsync=True}"></Setter>
                                                </DataTrigger>
                                                <MultiDataTrigger>
                                                    <MultiDataTrigger.Conditions>
                                                        <Condition Binding="{Binding Converter={StaticResource IsSegmentGradientConverter},IsAsync=True}" Value="True"></Condition>
                                                        <Condition Binding="{Binding ElementName=toggle_large_list,Path=IsChecked,IsAsync=True}" Value="True"></Condition>
                                                    </MultiDataTrigger.Conditions>
                                                    <Setter Property="CornerRadius" Value="8 0 0 0"></Setter>
                                                </MultiDataTrigger>
                                            </Style.Triggers>
                                        </Style>
                                    </Border.Style>
                                    <Border Background="{Binding SegmentBrush}">
                                        <Border.Style>
                                            <Style TargetType="Border">
                                                <Setter Property="CornerRadius" Value="8 0 0 8"></Setter>
                                                <Setter Property="Width" Value="{Binding RelativeSource={RelativeSource Self},Path=ActualHeight,IsAsync=True}"></Setter>
                                                <Style.Triggers>
                                                    <DataTrigger Binding="{Binding ElementName=toggle_small_list,Path=IsChecked,IsAsync=True}" Value="True">
                                                        <Setter Property="Width" Value="{Binding RelativeSource={RelativeSource Self},Path=ActualHeight,Converter={StaticResource MathOperatorConverter},ConverterParameter='*2',IsAsync=True}"></Setter>
                                                    </DataTrigger>
                                                    <MultiDataTrigger>
                                                        <MultiDataTrigger.Conditions>
                                                            <Condition Binding="{Binding Converter={StaticResource IsSegmentGradientConverter},IsAsync=True}" Value="True"></Condition>
                                                            <Condition Binding="{Binding ElementName=toggle_large_list,Path=IsChecked,IsAsync=True}" Value="True"></Condition>
                                                        </MultiDataTrigger.Conditions>
                                                        <Setter Property="CornerRadius" Value="8 0 0 0"></Setter>
                                                    </MultiDataTrigger>
                                                </Style.Triggers>
                                            </Style>
                                        </Border.Style>
                                    </Border>
                                </Border>

                                <Grid>
                                    <DockPanel Margin="30 0" VerticalAlignment="Center">
                                        <StackPanel DockPanel.Dock="Top" Orientation="Horizontal">
                                            <Canvas Visibility="{Binding HasOutOfGamutBrushStop,Converter={StaticResource BooleanToVisibilityConverter},IsAsync=True}">
                                                <Image Canvas.Left="-25" Canvas.Top="1" Source="{StaticResource Image_Out_Of_Gamut}"  Width="19" Height="19" />
                                            </Canvas>
                                            <TextBlock FontSize="{StaticResource TangoTitleFontSize}">
                                                                    <Run>Segment #</Run>
                                                                    <Run Text="{Binding SegmentIndex,Mode=OneWay,IsAsync=True}"></Run>
                                            </TextBlock>
                                        </StackPanel>

                                        <Grid>
                                            <StackPanel Margin="0 30 0 0" VerticalAlignment="Bottom" HorizontalAlignment="Left" Width="300" Visibility="{Binding ElementName=toggle_large_list,Path=IsChecked,Converter={StaticResource BooleanToVisibilityConverter},IsAsync=True}">
                                                <DockPanel LastChildFill="False">
                                                    <DockPanel.Style>
                                                        <Style TargetType="DockPanel">
                                                            <Setter Property="Visibility" Value="Visible"></Setter>
                                                            <Style.Triggers>
                                                                <DataTrigger Binding="{Binding Converter={StaticResource IsSegmentGradientConverter},IsAsync=True}" Value="True">
                                                                    <Setter Property="Visibility" Value="Collapsed"></Setter>
                                                                </DataTrigger>
                                                            </Style.Triggers>
                                                        </Style>
                                                    </DockPanel.Style>
                                                    <TextBlock VerticalAlignment="Bottom" DockPanel.Dock="Left" Text="Color code:"></TextBlock>

                                                    <Grid DockPanel.Dock="Right" DataContext="{Binding BrushStops[0],IsAsync=True}">
                                                        <StackPanel>
                                                            <ContentControl Focusable="False" FocusVisualStyle="{x:Null}" d:DataContext="{d:DesignInstance Type=entities:BrushStop, IsDesignTimeCreatable=False}" Content="{Binding}" Width="180">
                                                                <ContentControl.Style>
                                                                    <Style TargetType="ContentControl">
                                                                        <Setter Property="ContentTemplate">
                                                                            <Setter.Value>
                                                                                <DataTemplate>

                                                                                </DataTemplate>
                                                                            </Setter.Value>
                                                                        </Setter>
                                                                        <Style.Triggers>
                                                                            <DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="RGB">
                                                                                <Setter Property="ContentTemplate" Value="{StaticResource RGB_Template}" />
                                                                            </DataTrigger>
                                                                            <DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="CMYK">
                                                                                <Setter Property="ContentTemplate" Value="{StaticResource CMYK_Template}" />
                                                                            </DataTrigger>
                                                                            <DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="LAB">
                                                                                <Setter Property="ContentTemplate" Value="{StaticResource LAB_Template}" />
                                                                            </DataTrigger>
                                                                            <DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="Catalog">
                                                                                <Setter Property="ContentTemplate" Value="{StaticResource CATALOG_Template}" />
                                                                            </DataTrigger>
                                                                            <DataTrigger Binding="{Binding ElementName=view,Path=DataContext.Job.ColorSpace.Name,IsAsync=True}" Value="Volume">
                                                                                <Setter Property="ContentTemplate" Value="{StaticResource Volume_Template}" />
                                                                            </DataTrigger>
                                                                            <DataTrigger Binding="{Binding IsTransparent,IsAsync=True}" Value="True">
                                                                                <Setter Property="ContentTemplate">
                                                                                    <Setter.Value>
                                                                                        <DataTemplate>
                                                                                            <Grid Height="40">
                                                                                                <TextBlock VerticalAlignment="Bottom" Foreground="{StaticResource TangoGrayBrush}">Transparent</TextBlock>
                                                                                            </Grid>
                                                                                        </DataTemplate>
                                                                                    </Setter.Value>
                                                                                </Setter>
                                                                            </DataTrigger>
                                                                        </Style.Triggers>
                                                                    </Style>
                                                                </ContentControl.Style>
                                                            </ContentControl>
                                                        </StackPanel>
                                                    </Grid>
                                                </DockPanel>
                                                <Canvas>
                                                    <Canvas.Style>
                                                        <Style TargetType="Canvas">
                                                            <Setter Property="Visibility" Value="Collapsed"></Setter>
                                                            <Style.Triggers>
                                                                <MultiDataTrigger>
                                                                    <MultiDataTrigger.Conditions>
                                                                        <Condition Binding="{Binding Converter={StaticResource IsSegmentGradientConverter},IsAsync=True}" Value="False" />
                                                                        <Condition Binding="{Binding BrushStops[0].IsOutOfGamut,IsAsync=True}" Value="True" />
                                                                    </MultiDataTrigger.Conditions>
                                                                    <Setter Property="Visibility" Value="Visible"></Setter>
                                                                </MultiDataTrigger>
                                                            </Style.Triggers>
                                                        </Style>
                                                    </Canvas.Style>
                                                    <TextBlock Canvas.Top="2" Foreground="{StaticResource TangoErrorBrush}" FontSize="{StaticResource TangoSmallFontSize}" Text="Color is out of gamut. Modify color or select an alternative."></TextBlock>
                                                </Canvas>
                                                <DockPanel LastChildFill="False" Margin="0 20 0 0">
                                                    <TextBlock VerticalAlignment="Bottom" DockPanel.Dock="Left" Text="Length (m):"></TextBlock>
                                                    <touch:TouchNumericTextBox Width="180" DockPanel.Dock="Right" Value="{Binding Length}" StringFormat="0.0" AutoCalculateJogStep="False" HasDecimalPoint="True" Minimum="1" Maximum="100000" KeyboardContainer="{Binding ElementName=Container}" />
                                                </DockPanel>
                                            </StackPanel>
                                        </Grid>
                                    </DockPanel>

                                    <StackPanel Orientation="Horizontal" HorizontalAlignment="Right" VerticalAlignment="Top" Margin="0 10 10 0">
                                        <TextBlock Visibility="{Binding ElementName=toggle_small_list,Path=IsChecked,Converter={StaticResource BooleanToVisibilityConverter},IsAsync=True}" HorizontalAlignment="Right" VerticalAlignment="Center" Text="{Binding Length,StringFormat={}{0:N1} m}">
                                            <TextBlock.Style>
                                                <Style TargetType="TextBlock">
                                                    <Setter Property="Margin" Value="0 16 20 0"></Setter>
                                                    <Style.Triggers>
                                                        <DataTrigger Binding="{Binding ElementName=toggleEdit,Path=IsChecked}" Value="True">
                                                            <Setter Property="Margin" Value="0 5 20 0"></Setter>
                                                        </DataTrigger>
                                                    </Style.Triggers>
                                                </Style>
                                            </TextBlock.Style>
                                        </TextBlock>

                                        <StackPanel Orientation="Horizontal">
                                            <StackPanel.Style>
                                                <Style TargetType="StackPanel">
                                                    <Setter Property="Visibility" Value="Collapsed"></Setter>
                                                    <Style.Triggers>
                                                        <MultiDataTrigger>
                                                            <MultiDataTrigger.Conditions>
                                                                <Condition Binding="{Binding ElementName=toggleEdit,Path=IsChecked,IsAsync=True}" Value="False" />
                                                                <Condition Binding="{Binding ElementName=toggle_large_list,Path=IsChecked,IsAsync=True}" Value="True" />
                                                                <Condition Binding="{Binding Converter={StaticResource IsSegmentGradientConverter},IsAsync=True}" Value="False" />
                                                            </MultiDataTrigger.Conditions>
                                                            <Setter Property="Visibility" Value="Visible"></Setter>
                                                        </MultiDataTrigger>
                                                    </Style.Triggers>
                                                </Style>
                                            </StackPanel.Style>

                                            <!--<touch:TouchToggleIconButton Padding="15" Width="60" Height="60" CornerRadius="30" Icon="EyeOutline" CheckedIcon="EyeOffOutline" Foreground="{StaticResource TangoGrayBrush}" CheckedForeground="{StaticResource TangoGrayBrush}" IsChecked="{Binding BrushStops[0].IsTransparent,IsAsync=True}"></touch:TouchToggleIconButton>-->

                                            <touch:TouchImageButton Visibility="{Binding BrushStops[0].ColorSpace,Converter={StaticResource ColorSpaceToVisibilityConverter},IsAsync=True}" Command="{Binding ElementName=view,Path=DataContext.ReplaceBrushStopCommand}" CommandParameter="{Binding BrushStops[0]}" Width="50" Height="50" Padding="10" Image="{StaticResource Image_Replace_Color}" CornerRadius="30"></touch:TouchImageButton>
                                        </StackPanel>

                                        <StackPanel Visibility="{Binding ElementName=toggleEdit,Path=IsChecked,Converter={StaticResource BooleanToVisibilityConverter},IsAsync=True}" Orientation="Horizontal">

                                            <touch:TouchIconButton Command="{Binding ElementName=view,Path=DataContext.RemoveSegmentCommand}" CommandParameter="{Binding}" EnableDropShadow="False" Icon="TrashAltRegular" Padding="12" Foreground="{StaticResource TangoPrimaryAccentBrush}" Width="50" Height="50" RippleBrush="{StaticResource TangoRippleDarkBrush}" CornerRadius="30" />

                                            <dragAndDrop:DragThumb Background="Transparent" IsHitTestVisible="True">
                                                <touch:TouchIconButton IsHitTestVisible="False" EnableDropShadow="False" Icon="BarsSolid" Padding="15" Foreground="{StaticResource TangoPrimaryAccentBrush}" Width="50" Height="50" RippleBrush="{StaticResource TangoRippleDarkBrush}" CornerRadius="30" />
                                            </dragAndDrop:DragThumb>
                                        </StackPanel>
                                    </StackPanel>
                                </Grid>
                            </DockPanel>
                        </Grid>

                        <Border Grid.Row="1" BorderBrush="{StaticResource TangoGrayBrush}" BorderThickness="0 1 0 0">
                            <Border.Style>
                                <Style TargetType="Border">
                                    <Setter Property="Visibility" Value="Collapsed"></Setter>
                                    <Style.Triggers>
                                        <MultiDataTrigger>
                                            <MultiDataTrigger.Conditions>
                                                <Condition Binding="{Binding Converter={StaticResource IsSegmentGradientConverter},IsAsync=True}" Value="True"></Condition>
                                                <Condition Binding="{Binding ElementName=toggle_large_list,Path=IsChecked,IsAsync=True}" Value="True"></Condition>
                                            </MultiDataTrigger.Conditions>

                                            <Setter Property="Visibility" Value="Visible"></Setter>
                                        </MultiDataTrigger>
                                    </Style.Triggers>
                                </Style>
                            </Border.Style>

                            <StackPanel>
                                <ItemsControl ItemsSource="{Binding BrushStops}" ItemTemplate="{StaticResource BrushStop_Template}">

                                </ItemsControl>

                                <touch:TouchButton Command="{Binding ElementName=view,Path=DataContext.AddBrushStopCommand}" CommandParameter="{Binding}" Background="Transparent" RippleBrush="{StaticResource TangoRippleDarkBrush}" FontWeight="Normal" Foreground="{StaticResource TangoPrimaryAccentBrush}" HorizontalAlignment="Left" EnableDropShadow="False" Margin="50 30 0 60">
                                    <StackPanel Orientation="Horizontal">
                                        <Grid Width="49" Height="49">
                                            <Rectangle Stroke="{StaticResource TangoPrimaryAccentBrush}" StrokeThickness="1" StrokeDashArray="5 5 5 5" RadiusX="5" RadiusY="5"></Rectangle>
                                            <fa:ImageAwesome Icon="Plus" Width="16" Height="16" Foreground="{StaticResource TangoPrimaryAccentBrush}" />
                                        </Grid>

                                        <TextBlock VerticalAlignment="Center" Margin="20 0 0 0">ADD COLOR</TextBlock>
                                    </StackPanel>
                                </touch:TouchButton>
                            </StackPanel>
                        </Border>
                    </Grid>
                </Border>
            </touch:TouchVirtualizedContentControl>
        </DataTemplate>
    </UserControl.Resources>

    <Grid Background="{StaticResource TangoMidBackgroundBrush}" SnapsToDevicePixels="False">
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto"/>
            <RowDefinition Height="1*"/>
        </Grid.RowDefinitions>

        <touch:TouchLoadingPanel Grid.Row="1" IsLoading="{Binding IsBusy}">
            <Grid>

                <Grid.CacheMode>
                    <BitmapCache RenderAtScale="1" SnapsToDevicePixels="False" />
                </Grid.CacheMode>

                <Grid.RowDefinitions>
                    <RowDefinition Height="1*"/>
                    <RowDefinition Height="Auto"/>
                </Grid.RowDefinitions>
                <Grid>
                    <Grid x:Name="Container" keyboard:KeyboardView.ContainerOffset="40" Grid.RowSpan="2">
                        <touch:LightTouchScrollViewer x:Name="scrollViewer" Scrolling="scrollViewer_Scrolling">
                            <StackPanel Margin="10 60 10 0">
                                <StackPanel>
                                    <touch:TouchVirtualizedContentControl>
                                        <touch:TouchExpander Padding="20 15" IsExpanded="{Binding IsJobDetailsExpanded}">
                                            <touch:TouchExpander.Header>
                                                <StackPanel Orientation="Horizontal" VerticalAlignment="Center" Margin="0 0 20 0">
                                                    <Image Source="../Images/JobView/job-details.png" Width="39" />
                                                    <TextBlock FontWeight="Medium" Margin="20 0 0 0" VerticalAlignment="Center" FontSize="{StaticResource TangoExpanderHeaderFontSize}">Job Details</TextBlock>

                                                    <TextBlock FontWeight="Medium" Margin="50 0 0 0" VerticalAlignment="Center">
                                                <Run Text="{Binding Job.Rml.Name}"></Run><Run>,</Run>
                                                <Run Text="{Binding Job.ColorSpace.Name}"></Run>
                                                    </TextBlock>
                                                </StackPanel>
                                            </touch:TouchExpander.Header>

                                            <StackPanel Margin="60 30 60 20" TextElement.FontWeight="Medium">
                                                <controls:TableGrid RowHeight="50">

                                                    <TextBlock>Job name:</TextBlock>
                                                    <touch:TouchTextBox Text="{Binding Job.Name,UpdateSourceTrigger=PropertyChanged,ValidatesOnDataErrors=True,ValidatesOnNotifyDataErrors=True}" KeyboardMode="AlphaNumeric"  FocusSelectionMode="SelectAll" KeyboardAction="Next" KeyboardContainer="{Binding ElementName=Container}" />

                                                    <TextBlock>Customer:</TextBlock>
                                                    <touch:TouchAutoComplete ForceItemSelection="False" Text="{Binding CustomersFilter}" ItemsSource="{Binding Customers}" SelectedItem="{Binding Job.Customer}" DisplayMemberPath="Name" AutoCompleteProvider="{Binding CustomersAutoCompleteProvider}" KeyboardMode="AlphaNumeric" KeyboardAction="Next" KeyboardContainer="{Binding ElementName=Container}" />

                                                    <TextBlock>Thread type:</TextBlock>
                                                    <touch:TouchComboBox ItemsSource="{Binding Rmls}" SelectedItem="{Binding Job.Rml}" DisplayMemberPath="Name" Title="Select Thread" />

                                                    <TextBlock>Comment:</TextBlock>
                                                    <touch:TouchMultiLineTextBox Margin="20 0 0 -42" Text="{Binding Job.Description}" Height="60" keyboard:KeyboardView.Container="{Binding ElementName=Container}">

                                                    </touch:TouchMultiLineTextBox>
                                                </controls:TableGrid>

                                                <Grid HorizontalAlignment="Center" Margin="0 20 0 0" TextElement.Foreground="{StaticResource TangoGrayTextBrush}">
                                                    <Grid.ColumnDefinitions>
                                                        <ColumnDefinition Width="Auto" />
                                                        <ColumnDefinition Width="Auto" />
                                                        <ColumnDefinition Width="Auto" />
                                                        <ColumnDefinition Width="Auto" />
                                                        <ColumnDefinition Width="Auto" />
                                                    </Grid.ColumnDefinitions>

                                                    <TextBlock HorizontalAlignment="Left">
                                    <Run Text="Job status:"></Run>
                                    <Run Text="{Binding Job.JobStatus}"></Run>
                                                    </TextBlock>

                                                    <Rectangle Margin="20 0" Grid.Column="1" HorizontalAlignment="Center" StrokeThickness="1" Stroke="{StaticResource TangoGrayTextBrush}" />

                                                    <TextBlock Grid.Column="2" HorizontalAlignment="Center">
                                    <Run Text="Last updated:"></Run>
                                    <Run Text="{Binding Job.LastUpdated,Converter={StaticResource DateTimeUTCToShortDateConverter},TargetNullValue=Never}"></Run>
                                                    </TextBlock>

                                                    <Rectangle Margin="20 0" Grid.Column="3" HorizontalAlignment="Center" StrokeThickness="1" Stroke="{StaticResource TangoGrayTextBrush}" />

                                                    <TextBlock Grid.Column="4" HorizontalAlignment="Right">
                                    <Run Text="Last dye:"></Run>
                                    <Run Text="{Binding Job.LastRun,Converter={StaticResource DateTimeUTCToShortDateConverter},TargetNullValue=Never}"></Run>
                                                    </TextBlock>
                                                </Grid>
                                            </StackPanel>
                                        </touch:TouchExpander>
                                    </touch:TouchVirtualizedContentControl>

                                    <touch:TouchDropShadowBorder Margin="0 12 0 0" Padding="0 0 0 40">
                                        <Grid>
                                            <StackPanel>
                                                <StackPanel Orientation="Horizontal" VerticalAlignment="Center"  Style="{StaticResource Level1Container}">
                                                    <Image Source="../Images/JobView/color-length.png" Width="39" />
                                                    <TextBlock FontWeight="Medium" Margin="20 0 0 0" VerticalAlignment="Center" FontSize="{StaticResource TangoExpanderHeaderFontSize}">Color &amp; Length</TextBlock>
                                                </StackPanel>

                                                <StackPanel>
                                                    <StackPanel.Style>
                                                        <Style TargetType="StackPanel" BasedOn="{StaticResource Level2Container}">
                                                            <Setter Property="Visibility" Value="Collapsed"></Setter>
                                                            <Style.Triggers>
                                                                <DataTrigger Binding="{Binding Job.JobType}" Value="{x:Static enumerations:JobTypes.Embroidery}">
                                                                    <Setter Property="Visibility" Value="Visible"></Setter>
                                                                </DataTrigger>
                                                            </Style.Triggers>
                                                        </Style>
                                                    </StackPanel.Style>
                                                    <UniformGrid Columns="2" Rows="1">
                                                        <DockPanel Margin="0 0 10 0">
                                                            <TextBlock Text="Number of units:" VerticalAlignment="Bottom"></TextBlock>
                                                            <touch:TouchNumericTextBox Margin="20 0 0 0" Value="{Binding Job.NumberOfUnits}" Minimum="1" Maximum="10000" JoggingFactor="0.01" />
                                                        </DockPanel>

                                                        <DockPanel Margin="10 0 0 0">
                                                            <TextBlock Text="Number of heads:" VerticalAlignment="Bottom"></TextBlock>
                                                            <touch:TouchNumericTextBox Margin="20 0 0 0" Value="{Binding Job.NumberOfHeads}" Minimum="1" Maximum="1000" JoggingFactor="0.1" />
                                                        </DockPanel>
                                                    </UniformGrid>
                                                </StackPanel>

                                                <StackPanel>
                                                    <StackPanel.Style>
                                                        <Style TargetType="StackPanel" BasedOn="{StaticResource Level2Container}">
                                                            <Setter Property="Visibility" Value="Visible"></Setter>
                                                            <Style.Triggers>
                                                                <DataTrigger Binding="{Binding Job.JobType}" Value="{x:Static enumerations:JobTypes.Embroidery}">
                                                                    <Setter Property="Visibility" Value="Collapsed"></Setter>
                                                                </DataTrigger>
                                                            </Style.Triggers>
                                                        </Style>
                                                    </StackPanel.Style>
                                                    <DockPanel Margin="0 0 10 0">
                                                        <TextBlock Text="Repetitions:" VerticalAlignment="Bottom"></TextBlock>
                                                        <touch:TouchNumericTextBox Width="200" HorizontalAlignment="Left" Margin="20 0 0 0" Value="{Binding Job.NumberOfUnits}" Minimum="1" Maximum="10000" JoggingFactor="0.01" />
                                                    </DockPanel>
                                                </StackPanel>

                                                <!--<DockPanel Style="{StaticResource Level2Container}">
                                                <TextBlock Text="Color Catalog/Space:" VerticalAlignment="Center"></TextBlock>
                                                <touch:TouchComboBox Margin="20 0 0 0" ItemsSource="{Binding ColorSpaces}" SelectedItem="{Binding Job.ColorSpace}" DisplayMemberPath="Name" Title="Select Color Catalog/Space" />
                                            </DockPanel>-->

                                                <Border x:Name="borderDockFloat" Height="80">
                                                    <DockPanel x:Name="dockEdit" LastChildFill="False" Style="{StaticResource Level2ContainerExtraMargin}" Height="40" Width="640">
                                                        <StackPanel DockPanel.Dock="Left" Orientation="Horizontal">
                                                            <touch:TouchToggleImageButton x:Name="toggle_small_list" UncheckedImage="../Images/small-cards-view.png"  CheckedImage="../Images/small-cards-view - blue.png" 
                                                                                     IsChecked="{Binding ElementName=toggle_large_list,Path=IsChecked,Mode=OneWay,Converter={StaticResource BooleanInverseConverter}}" DockPanel.Dock="Right" 
                                                                                      Padding="8" CornerRadius="30" Width="44" />
                                                            <Rectangle HorizontalAlignment="Left" Stroke="{StaticResource TangoDividerBrush}" Margin="10 8" />
                                                            <touch:TouchToggleImageButton x:Name="toggle_large_list" UncheckedImage="../Images/large-cards-view.png"  CheckedImage="../Images/large-cards-view - blue.png" 
                                                                                     IsChecked="{Binding ElementName=toggle_small_list,Path=IsChecked,Mode=OneWay,Converter={StaticResource BooleanInverseConverter}}" DockPanel.Dock="Right"
                                                                                      Padding="8" CornerRadius="30" Width="44" />
                                                        </StackPanel>
                                                        <touch:TouchToggleImageButton x:Name="toggleEdit" UncheckedImage="../Images/pencil-gray.png" 
                                                                                      CheckedImage="../Images/pencil-blue.png" 
                                                                                      DockPanel.Dock="Right" 
                                                                                      Padding="8" CornerRadius="30" Width="40" Height="40">
                                                        </touch:TouchToggleImageButton>
                                                        <!--<touch:TouchToggleIconButton x:Name="toggleEdit" DockPanel.Dock="Right" Icon="Pencil" CheckedIcon="Pencil" Padding="8" CornerRadius="20" />-->
                                                    </DockPanel>
                                                </Border>

                                                <ItemsControl x:Name="listSegments" Style="{StaticResource Level2Container}" ItemsSource="{Binding SegmentsCollectionView}" ItemTemplate="{StaticResource Segment_Template}"></ItemsControl>

                                                <StackPanel HorizontalAlignment="Right" Style="{StaticResource Level2Container}" Orientation="Horizontal">
                                                    <touch:TouchButton Command="{Binding AddSolidSegmentCommand}" FontWeight="Normal" RippleBrush="{StaticResource TangoRippleDarkBrush}" FontSize="{StaticResource TangoDefaultFontSize}" EnableDropShadow="False" Foreground="{StaticResource TangoPrimaryAccentBrush}" Width="170" CornerRadius="20" Padding="0 10" Background="Transparent" BorderThickness="2" BorderBrush="{StaticResource TangoPrimaryAccentBrush}">
                                                        <StackPanel Orientation="Horizontal">
                                                            <Image VerticalAlignment="Center" Margin="0 1 0 0" Source="../Images/plus.png" Width="12"/>
                                                            <TextBlock Margin="10 2 0 0">SOLID SEGMENT</TextBlock>
                                                        </StackPanel>
                                                    </touch:TouchButton>
                                                    <touch:TouchButton Command="{Binding AddGradientSegmentCommand}" FontWeight="Normal" RippleBrush="{StaticResource TangoRippleDarkBrush}" FontSize="{StaticResource TangoDefaultFontSize}" Margin="30 0 0 0" EnableDropShadow="False" Foreground="{StaticResource TangoPrimaryAccentBrush}" Padding="0 10" Width="200" CornerRadius="20" Background="Transparent" BorderThickness="2">
                                                        <touch:TouchButton.BorderBrush>
                                                            <LinearGradientBrush>
                                                                <GradientStop Offset="0" Color="{StaticResource TangoPrimaryAccentColor}" />
                                                                <GradientStop Offset="1" Color="#57F157" />
                                                            </LinearGradientBrush>
                                                        </touch:TouchButton.BorderBrush>

                                                        <StackPanel Orientation="Horizontal">
                                                            <Image VerticalAlignment="Center" Margin="0 1 0 0" Source="../Images/plus.png" Width="12"/>
                                                            <TextBlock Margin="10 2 0 0">GRADIENT SEGMENT</TextBlock>
                                                        </StackPanel>
                                                    </touch:TouchButton>
                                                </StackPanel>

                                                <StackPanel Style="{StaticResource Level2ContainerExtraMargin}">
                                                    <DockPanel LastChildFill="False">
                                                        <touch:TouchCheckBox DockPanel.Dock="Left" HorizontalAlignment="Left" IsChecked="{Binding Job.EnableInterSegment}">Include white gap between segments</touch:TouchCheckBox>
                                                        <StackPanel DockPanel.Dock="Right" Orientation="Horizontal" HorizontalAlignment="Right" VerticalAlignment="Center" Margin="0 -20 5 0">
                                                            <TextBlock Margin="0 3 0 0" Foreground="{StaticResource TangoGrayTextBrush}" VerticalAlignment="Bottom">
                                                    <Run Text="Length (m):"></Run>
                                                            </TextBlock>

                                                            <touch:TouchNumericTextBox Foreground="{StaticResource TangoGrayTextBrush}" Margin="5 0 0 0" Width="50" HorizontalContentAlignment="Center" Minimum="1" Maximum="1000" Value="{Binding Job.InterSegmentLength}" KeyboardContainer="{Binding ElementName=Container}" StringFormat="0" FocusSelectionMode="SelectAll" />

                                                            <Image Margin="10 0 0 0" Source="../Images/JobView/settings.png" VerticalAlignment="Bottom" />
                                                        </StackPanel>
                                                    </DockPanel>
                                                </StackPanel>

                                                <Rectangle Stroke="{StaticResource TangoDividerBrush}" Margin="0 30 0 0" />

                                                <StackPanel x:Name="stackOutput" Orientation="Horizontal" VerticalAlignment="Center"  Style="{StaticResource Level1Container}">
                                                    <Image Source="../Images/JobView/output.png" Width="39" />
                                                    <TextBlock FontWeight="Medium" Margin="20 0 0 0" VerticalAlignment="Center" FontSize="{StaticResource TangoExpanderHeaderFontSize}">Output</TextBlock>
                                                </StackPanel>

                                                <DockPanel Style="{StaticResource Level2Container}">
                                                    <TextBlock Text="Spool Type:" VerticalAlignment="Center"></TextBlock>
                                                    <touch:TouchComboBox ItemsSource="{Binding SpoolTypes}" SelectedItem="{Binding Job.SpoolType}" Margin="40 -15 0 0" DisplayMemberPath="Name" Title="Select Spool Type" />
                                                </DockPanel>

                                                <!--<DockPanel Style="{StaticResource Level2Container}">
                                                    <TextBlock Text="Segments per spool:" VerticalAlignment="Center"></TextBlock>
                                                    <touch:TouchToggleSlider Margin="30 0 0 0" BorderThickness="2" Height="38" Width="83" HorizontalAlignment="Left" UncheckedContent="One" CheckedContent="All" IsChecked="{Binding Job.IsAllSegmentsPerSpool}" />
                                                </DockPanel>-->
                                            </StackPanel>
                                        </Grid>
                                    </touch:TouchDropShadowBorder>

                                    <touch:TouchVirtualizedContentControl Margin="0 20 0 0">
                                        <touch:TouchDropShadowBorder Padding="0 0 0 50" Visibility="{Binding Job.EmbroideryFileData,Converter={StaticResource IsNullToVisibilityConverter}}">
                                            <StackPanel>
                                                <StackPanel Orientation="Horizontal" VerticalAlignment="Center"  Style="{StaticResource Level1Container}">
                                                    <Image Source="../Images/embroidery.png" RenderOptions.BitmapScalingMode="Fant" Width="39" />
                                                    <TextBlock FontWeight="Medium" Margin="20 0 0 0" VerticalAlignment="Center" FontSize="{StaticResource TangoExpanderHeaderFontSize}">Embroidery File</TextBlock>
                                                </StackPanel>

                                                <StackPanel Style="{StaticResource Level2ContainerExtraMargin}">
                                                    <DockPanel>
                                                        <Image Source="{Binding Job,Converter={StaticResource JobToEmbroideryImageConverter}}" Width="230" Stretch="Uniform" HorizontalAlignment="Left"></Image>

                                                        <StackPanel VerticalAlignment="Center" HorizontalAlignment="Right">
                                                            <TextBlock TextWrapping="Wrap" TextAlignment="Right">Export the attached embroidery file to storage.</TextBlock>
                                                            <touch:TouchButton Command="{Binding ExportEmbroideryCommand}" Style="{StaticResource TangoHollowButton}" Width="240" Height="60" Margin="0 30 0 0" HorizontalAlignment="Right">EXPORT FILE</touch:TouchButton>
                                                        </StackPanel>
                                                    </DockPanel>
                                                </StackPanel>
                                            </StackPanel>
                                        </touch:TouchDropShadowBorder>
                                    </touch:TouchVirtualizedContentControl>

                                    <touch:TouchVirtualizedContentControl Margin="0 20 0 0" >
                                        <touch:TouchDropShadowBorder Padding="0 0 0 50">
                                            <StackPanel>
                                                <StackPanel Orientation="Horizontal" VerticalAlignment="Center"  Style="{StaticResource Level1Container}">
                                                    <Image Source="../Images/JobView/job-summary.png" Width="39" />
                                                    <TextBlock FontWeight="Medium" Margin="20 0 0 0" VerticalAlignment="Center" FontSize="{StaticResource TangoExpanderHeaderFontSize}">Job Summary</TextBlock>
                                                </StackPanel>

                                                <StackPanel Style="{StaticResource Level2ContainerExtraMargin}">
                                                    <Grid>
                                                        <localControls:JobSummeryViewer DataContext="{Binding Job,IsAsync=True}" Height="40"/>
                                                    </Grid>

                                                    <DockPanel Margin="0 30 0 0" LastChildFill="False">

                                                        <StackPanel Orientation="Horizontal" DockPanel.Dock="Left" VerticalAlignment="Center">
                                                            <TextBlock>
                                                    <Run Text="Job length (m):"></Run>
                                                    <Run Text="{Binding Job.Length,Mode=OneWay}"></Run>
                                                            </TextBlock>
                                                            <TextBlock Foreground="{StaticResource TangoGrayTextBrush}">
                                                                <TextBlock.Style>
                                                                    <Style TargetType="TextBlock">
                                                                        <Setter Property="Visibility" Value="Collapsed"></Setter>
                                                                        <Style.Triggers>
                                                                            <DataTrigger Binding="{Binding Job.LengthPercentageFactor,Converter={StaticResource GreaterThanToBooleanConverter},ConverterParameter=0}" Value="True">
                                                                                <Setter Property="Visibility" Value="Visible"></Setter>
                                                                            </DataTrigger>
                                                                        </Style.Triggers>
                                                                    </Style>
                                                                </TextBlock.Style>
                                                    <Run>(</Run><Run Text="{Binding Job.Length,Mode=OneWay}"></Run><Run>+</Run><Run Text="{Binding Job.LengthPercentageFactor,Mode=OneWay}"></Run><Run>%</Run><Run>)</Run>
                                                            </TextBlock>
                                                        </StackPanel>

                                                        <StackPanel DockPanel.Dock="Right" Orientation="Horizontal" HorizontalAlignment="Right" VerticalAlignment="Center" Margin="0 -20 5 0">
                                                            <TextBlock Margin="0 3 0 0" Foreground="{StaticResource TangoGrayTextBrush}" VerticalAlignment="Bottom">
                                                    <Run Text="Factor: +"></Run>
                                                            </TextBlock>

                                                            <touch:TouchNumericTextBox Foreground="{StaticResource TangoGrayTextBrush}" Margin="5 0 0 0" Width="50" HorizontalContentAlignment="Center" Maximum="100" Minimum="0" Value="{Binding Job.LengthPercentageFactor}" KeyboardContainer="{Binding ElementName=Container}" StringFormat="0" FocusSelectionMode="SelectAll" />

                                                            <TextBlock VerticalAlignment="Bottom" Foreground="{StaticResource TangoGrayTextBrush}">%</TextBlock>

                                                            <Image Margin="10 0 0 0" Source="../Images/JobView/settings.png" VerticalAlignment="Bottom" />
                                                        </StackPanel>
                                                    </DockPanel>
                                                </StackPanel>
                                            </StackPanel>
                                        </touch:TouchDropShadowBorder>
                                    </touch:TouchVirtualizedContentControl>

                                    <StackPanel HorizontalAlignment="Center" Margin="20 40 0 40" Orientation="Horizontal" VerticalAlignment="Center" Style="{StaticResource Level1Container}">
                                        <TextBlock FontWeight="Medium" Margin="20 0 0 0" VerticalAlignment="Center" FontSize="{StaticResource TangoTitleFontSize}">Additional Tools</TextBlock>
                                    </StackPanel>

                                    <touch:TouchVirtualizedContentControl>
                                        <touch:TouchExpander x:Name="expander_sample_dye" Margin="0 0 0 0" Padding="20 15">
                                            <touch:TouchExpander.Header>
                                                <StackPanel Orientation="Horizontal" VerticalAlignment="Center" Margin="0 0 20 0">
                                                    <Image Source="../Images/JobView/sample-dye.png" Width="39" />
                                                    <TextBlock FontWeight="Medium" Margin="20 0 0 0" VerticalAlignment="Center" FontSize="{StaticResource TangoExpanderHeaderFontSize}">Sample Dye</TextBlock>
                                                </StackPanel>
                                            </touch:TouchExpander.Header>

                                            <StackPanel>
                                                <StackPanel Margin="60 20 0 0">
                                                    <ContentControl>
                                                        <ContentControl.Style>
                                                            <Style TargetType="ContentControl">
                                                                <Setter Property="Content">
                                                                    <Setter.Value>
                                                                        <StackPanel>
                                                                            <ContentControl Content="{Binding RelativeSource={RelativeSource AncestorType=UserControl},Path=DataContext}">
                                                                                <ContentControl.Style>
                                                                                    <Style TargetType="ContentControl">
                                                                                        <Setter Property="ContentTemplate">
                                                                                            <Setter.Value>
                                                                                                <DataTemplate>
                                                                                                    <StackPanel>
                                                                                                        <TextBlock>
                                                                    <Run>Dye 1 or more units in order to get approval.</Run>
                                                                    <LineBreak/>
                                                                    <Run>Once approved, you can dye the entire job.</Run>
                                                                                                        </TextBlock>

                                                                                                        <DockPanel Margin="0 50 0 0" LastChildFill="True" Width="450" HorizontalAlignment="Left">
                                                                                                            <TextBlock DockPanel.Dock="Left" VerticalAlignment="Center">How many sample units?</TextBlock>

                                                                                                            <DockPanel Margin="50 0 0 0">
                                                                                                                <touch:TouchIconButton Command="{Binding IncreaseDecreaseSamplesToDyeCommand}" CommandParameter="-" DockPanel.Dock="Left" Icon="Minus" Padding="15" Style="{StaticResource TangoHollowButton}" BorderThickness="2" Width="51" Height="51" />
                                                                                                                <touch:TouchIconButton Command="{Binding IncreaseDecreaseSamplesToDyeCommand}" CommandParameter="+" DockPanel.Dock="Right" Icon="Plus" Padding="15" Style="{StaticResource TangoHollowButton}" BorderThickness="2" Width="51" Height="51" />
                                                                                                                <touch:TouchNumericTextBox Value="{Binding Job.SampleUnitsOrMeters}" Minimum="1" Maximum="100" HorizontalContentAlignment="Center" VerticalAlignment="Center" Margin="10 0" Foreground="{StaticResource TangoPrimaryAccentBrush}" FontSize="{StaticResource TangoTitleFontSize}" DockPanel.Dock="Right" KeyboardContainer="{Binding ElementName=Container}" />
                                                                                                            </DockPanel>
                                                                                                        </DockPanel>
                                                                                                    </StackPanel>
                                                                                                </DataTemplate>
                                                                                            </Setter.Value>
                                                                                        </Setter>
                                                                                        <Style.Triggers>
                                                                                            <DataTrigger Binding="{Binding Job.JobType}" Value="{x:Static enumerations:JobTypes.Sewing}">
                                                                                                <Setter Property="ContentTemplate">
                                                                                                    <Setter.Value>
                                                                                                        <DataTemplate>
                                                                                                            <StackPanel>
                                                                                                                <TextBlock>
                                                                    <Run>Dye several meters per segment in order to get approval.</Run>
                                                                    <LineBreak/>
                                                                    <Run>Once approved, you can dye the entire job.</Run>
                                                                                                                </TextBlock>

                                                                                                                <DockPanel Margin="0 50 0 0" LastChildFill="True" Width="450" HorizontalAlignment="Left">
                                                                                                                    <TextBlock DockPanel.Dock="Left" VerticalAlignment="Center">Meters per segment</TextBlock>

                                                                                                                    <DockPanel Margin="50 0 0 0">
                                                                                                                        <touch:TouchIconButton Command="{Binding IncreaseDecreaseSamplesToDyeCommand}" CommandParameter="-" DockPanel.Dock="Left" Icon="Minus" Padding="15" Style="{StaticResource TangoHollowButton}" BorderThickness="2" Width="51" Height="51" />
                                                                                                                        <touch:TouchIconButton Command="{Binding IncreaseDecreaseSamplesToDyeCommand}" CommandParameter="+" DockPanel.Dock="Right" Icon="Plus" Padding="15" Style="{StaticResource TangoHollowButton}" BorderThickness="2" Width="51" Height="51" />
                                                                                                                        <touch:TouchNumericTextBox Value="{Binding Job.SampleUnitsOrMeters}" Minimum="1" Maximum="100" HorizontalContentAlignment="Center" VerticalAlignment="Center" Margin="10 0" Foreground="{StaticResource TangoPrimaryAccentBrush}" FontSize="{StaticResource TangoTitleFontSize}" DockPanel.Dock="Right" KeyboardContainer="{Binding ElementName=Container}" />
                                                                                                                    </DockPanel>
                                                                                                                </DockPanel>
                                                                                                            </StackPanel>
                                                                                                        </DataTemplate>
                                                                                                    </Setter.Value>
                                                                                                </Setter>
                                                                                            </DataTrigger>
                                                                                        </Style.Triggers>
                                                                                    </Style>
                                                                                </ContentControl.Style>
                                                                            </ContentControl>

                                                                            <touch:TouchButton Margin="0 50 0 15" DockPanel.Dock="Right" Height="54" Padding="0" Width="184" CornerRadius="30" BlurRadius="20" HorizontalAlignment="Right" Command="{Binding StartSampleDyeCommand}" IsEnabled="{Binding MachineProvider.MachineOperator.CanPrint}">
                                                                                START
                                                                            </touch:TouchButton>
                                                                        </StackPanel>
                                                                    </Setter.Value>
                                                                </Setter>

                                                                <Style.Triggers>
                                                                    <DataTrigger Binding="{Binding Job.JobSampleDyeStatus}" Value="{x:Static enumerations:SampleDyeStatuses.PendingApproval}">
                                                                        <Setter Property="Content">
                                                                            <Setter.Value>
                                                                                <StackPanel>
                                                                                    <TextBlock>How to continue?</TextBlock>

                                                                                    <UniformGrid Columns="2" Width="420" HorizontalAlignment="Left" Margin="0 40 0 20">
                                                                                        <StackPanel HorizontalAlignment="Left">
                                                                                            <touch:TouchButton Style="{StaticResource TangoHollowButton}" Width="180" Height="50" Command="{Binding ApproveSampleCommand}">
                                                                                                <StackPanel Orientation="Horizontal">
                                                                                                    <touch:TouchIcon Icon="Check"></touch:TouchIcon>
                                                                                                    <TextBlock Margin="10 0 0 0">DONE</TextBlock>
                                                                                                </StackPanel>
                                                                                            </touch:TouchButton>

                                                                                            <TextBlock Margin="0 15 0 0" TextAlignment="Center">The sample is approved</TextBlock>
                                                                                        </StackPanel>

                                                                                        <StackPanel HorizontalAlignment="Right">
                                                                                            <touch:TouchButton Style="{StaticResource TangoHollowButton}" Width="180" Height="50" Command="{Binding RepeatSampleDyeCommand}">
                                                                                                <StackPanel Orientation="Horizontal">
                                                                                                    <touch:TouchIcon Icon="Repeat"></touch:TouchIcon>
                                                                                                    <TextBlock Margin="10 0 0 0">REPEAT</TextBlock>
                                                                                                </StackPanel>
                                                                                            </touch:TouchButton>

                                                                                            <TextBlock Margin="0 15 0 0" TextAlignment="Center">Dye more samples</TextBlock>
                                                                                        </StackPanel>
                                                                                    </UniformGrid>

                                                                                </StackPanel>
                                                                            </Setter.Value>
                                                                        </Setter>
                                                                    </DataTrigger>

                                                                    <DataTrigger Binding="{Binding Job.JobSampleDyeStatus}" Value="{x:Static enumerations:SampleDyeStatuses.Approved}">
                                                                        <Setter Property="Content">
                                                                            <Setter.Value>
                                                                                <StackPanel Margin="0 40 80 40">
                                                                                    <DockPanel LastChildFill="False">
                                                                                        <TextBlock DockPanel.Dock="Left" VerticalAlignment="Center">
                                                                            <Run>Sample Approved:</Run>
                                                                            <Run Text="{Binding Job.SampleDyeApproveDate,Converter={StaticResource DateTimeUTCToShortDateConverter},TargetNullValue=''}"></Run>
                                                                                        </TextBlock>
                                                                                        <touch:TouchButton DockPanel.Dock="Right" HorizontalAlignment="Right" Style="{StaticResource TangoHollowButton}" Width="220" Height="50" Command="{Binding AnotherSampleCommand}">
                                                                                            <StackPanel Orientation="Horizontal">
                                                                                                <touch:TouchIcon Icon="Plus"></touch:TouchIcon>
                                                                                                <TextBlock Margin="10 0 0 0">ANOTHER SAMPLE</TextBlock>
                                                                                            </StackPanel>
                                                                                        </touch:TouchButton>
                                                                                    </DockPanel>
                                                                                </StackPanel>
                                                                            </Setter.Value>
                                                                        </Setter>
                                                                    </DataTrigger>
                                                                </Style.Triggers>
                                                            </Style>
                                                        </ContentControl.Style>
                                                    </ContentControl>
                                                </StackPanel>

                                                <StackPanel Margin="0 0 0 15">
                                                    <StackPanel.Style>
                                                        <Style TargetType="StackPanel">
                                                            <Setter Property="Visibility" Value="Collapsed"></Setter>
                                                            <Style.Triggers>
                                                                <DataTrigger Binding="{Binding Job.JobSampleDyeStatus}" Value="{x:Static enumerations:SampleDyeStatuses.PendingApproval}">
                                                                    <Setter Property="Visibility" Value="Visible"></Setter>
                                                                </DataTrigger>
                                                            </Style.Triggers>
                                                        </Style>
                                                    </StackPanel.Style>
                                                    <Rectangle HorizontalAlignment="Stretch" StrokeThickness="1" Stroke="{StaticResource TangoDividerBrush}" Margin="-20 30"></Rectangle>

                                                    <StackPanel Orientation="Horizontal" Margin="60 0 0 0">
                                                        <touch:TouchIcon Icon="AlertCircleOutline" Width="32" Height="32" StrokeThickness="0.1" Foreground="{StaticResource TangoGrayBrush}" />
                                                        <TextBlock Margin="10 0 0 0" VerticalAlignment="Center">
                                            You can use the color fine tuning tool to adjust the colors.
                                                        </TextBlock>
                                                    </StackPanel>
                                                </StackPanel>
                                            </StackPanel>
                                        </touch:TouchExpander>
                                    </touch:TouchVirtualizedContentControl>

                                    <touch:TouchVirtualizedContentControl>
                                        <touch:TouchExpander x:Name="expander_fine_tuning" Margin="0 20 0 120" Padding="20 15" IsExpanded="{Binding IsFineTuneExpanded,Mode=TwoWay}" Visibility="{Binding Job.ColorSpace,Converter={StaticResource ColorSpaceToVisibilityConverter}}">
                                            <touch:TouchExpander.Header>
                                                <StackPanel Orientation="Horizontal" VerticalAlignment="Center" Margin="0 0 20 0">
                                                    <Image Source="../Images/JobView/color-fine-tuning.png" Width="39" />
                                                    <TextBlock FontWeight="Medium" Margin="20 0 0 0" VerticalAlignment="Center" FontSize="{StaticResource TangoExpanderHeaderFontSize}">Color Fine Tuning</TextBlock>
                                                </StackPanel>
                                            </touch:TouchExpander.Header>

                                            <StackPanel Margin="60 20 0 0">

                                                <ContentControl>
                                                    <ContentControl.Style>
                                                        <Style TargetType="ContentControl">
                                                            <Setter Property="Content">
                                                                <Setter.Value>
                                                                    <StackPanel>
                                                                        <TextBlock>Select the colors you want to fine tune.</TextBlock>

                                                                        <StackPanel HorizontalAlignment="Center" Margin="0 40 0 0">
                                                                            <TextBlock Foreground="{StaticResource TangoGrayTextBrush}" HorizontalAlignment="Center" FontSize="{StaticResource TangoTitleFontSize}">Defined Colors</TextBlock>

                                                                            <ItemsControl Margin="0 40 0 0" ItemsSource="{Binding FineTuneItems}">
                                                                                <ItemsControl.ItemTemplate>
                                                                                    <DataTemplate>
                                                                                        <DockPanel>
                                                                                            <touch:TouchCheckBox DockPanel.Dock="Left" IsChecked="{Binding IsSelected}" Margin="0 0 20 0" />
                                                                                            <touch:TouchImageButton DockPanel.Dock="Right" Image="{StaticResource Image_Color_Picker}" Width="80" Height="80" Padding="15" CornerRadius="100" Command="{Binding RelativeSource={RelativeSource AncestorType=UserControl},Path=DataContext.InvokeFineTuningPaletteCommand}" CommandParameter="{Binding}"></touch:TouchImageButton>
                                                                                            <touch:TouchFlatListBox ItemsSource="{Binding Suggestions}" SelectedItem="{Binding SelectedSuggestion}" IsEnabled="False">
                                                                                                <touch:TouchFlatListBox.ItemsPanel>
                                                                                                    <ItemsPanelTemplate>
                                                                                                        <UniformGrid Columns="{Binding Suggestions.Count}" Margin="0 20"></UniformGrid>
                                                                                                    </ItemsPanelTemplate>
                                                                                                </touch:TouchFlatListBox.ItemsPanel>
                                                                                                <touch:TouchFlatListBox.ItemTemplate>
                                                                                                    <DataTemplate>
                                                                                                        <Ellipse Width="70" Height="70" Fill="{Binding Brush}" Margin="30 0">
                                                                                                            <Ellipse.Style>
                                                                                                                <Style TargetType="Ellipse">
                                                                                                                    <Setter Property="RenderTransformOrigin" Value="0.5,0.5"></Setter>
                                                                                                                    <Setter Property="RenderTransform">
                                                                                                                        <Setter.Value>
                                                                                                                            <ScaleTransform ScaleX="1" ScaleY="1" />
                                                                                                                        </Setter.Value>
                                                                                                                    </Setter>
                                                                                                                    <Setter Property="Effect">
                                                                                                                        <Setter.Value>
                                                                                                                            <DropShadowEffect Color="{StaticResource TangoDropShadowColor}" ShadowDepth="10" Direction="10" BlurRadius="15" Opacity="0" />
                                                                                                                        </Setter.Value>
                                                                                                                    </Setter>
                                                                                                                    <Style.Triggers>
                                                                                                                        <DataTrigger Binding="{Binding RelativeSource={RelativeSource AncestorType=ListBoxItem},Path=IsSelected}" Value="True">
                                                                                                                            <DataTrigger.EnterActions>
                                                                                                                                <BeginStoryboard>
                                                                                                                                    <Storyboard>
                                                                                                                                        <DoubleAnimation Storyboard.TargetProperty="RenderTransform.ScaleX" To="1.2" Duration="00:00:0.2" />
                                                                                                                                        <DoubleAnimation Storyboard.TargetProperty="RenderTransform.ScaleY" To="1.2" Duration="00:00:0.2" />
                                                                                                                                        <DoubleAnimation Storyboard.TargetProperty="Effect.Opacity" To="1" Duration="00:00:0.2" />
                                                                                                                                    </Storyboard>
                                                                                                                                </BeginStoryboard>
                                                                                                                            </DataTrigger.EnterActions>
                                                                                                                            <DataTrigger.ExitActions>
                                                                                                                                <BeginStoryboard>
                                                                                                                                    <Storyboard>
                                                                                                                                        <DoubleAnimation Storyboard.TargetProperty="RenderTransform.ScaleX" To="1" Duration="00:00:0.2" />
                                                                                                                                        <DoubleAnimation Storyboard.TargetProperty="RenderTransform.ScaleY" To="1" Duration="00:00:0.2" />
                                                                                                                                        <DoubleAnimation Storyboard.TargetProperty="Effect.Opacity" To="0" Duration="00:00:0.2" />
                                                                                                                                    </Storyboard>
                                                                                                                                </BeginStoryboard>
                                                                                                                            </DataTrigger.ExitActions>
                                                                                                                        </DataTrigger>
                                                                                                                    </Style.Triggers>
                                                                                                                </Style>
                                                                                                            </Ellipse.Style>
                                                                                                        </Ellipse>
                                                                                                    </DataTemplate>
                                                                                                </touch:TouchFlatListBox.ItemTemplate>
                                                                                            </touch:TouchFlatListBox>
                                                                                        </DockPanel>
                                                                                    </DataTemplate>
                                                                                </ItemsControl.ItemTemplate>
                                                                            </ItemsControl>
                                                                        </StackPanel>

                                                                        <DockPanel LastChildFill="False" Margin="0 80 0 0">
                                                                            <touch:TouchButton Command="{Binding ResetFineTuningCommand}" DockPanel.Dock="Left" Padding="40 10" Margin="-30 0 0 0" Style="{StaticResource TangoFlatButton}" Foreground="{StaticResource TangoPrimaryAccentBrush}">Reset</touch:TouchButton>

                                                                            <touch:TouchButton Margin="0 0 0 15" DockPanel.Dock="Right" Height="54" Padding="0" Width="184" CornerRadius="30" BlurRadius="20" HorizontalAlignment="Right" Command="{Binding StartFineTuningCommand}" IsEnabled="{Binding MachineProvider.MachineOperator.CanPrint}">
                                                                                START
                                                                            </touch:TouchButton>
                                                                        </DockPanel>
                                                                    </StackPanel>
                                                                </Setter.Value>
                                                            </Setter>
                                                            <Style.Triggers>
                                                                <DataTrigger Binding="{Binding Job.JobFineTuningStatus}" Value="{x:Static enumerations:FineTuningStatuses.PendingApproval}">
                                                                    <Setter Property="Content">
                                                                        <Setter.Value>
                                                                            <StackPanel Margin="0 20 0 0">
                                                                                <StackPanel Orientation="Horizontal">
                                                                                    <Grid>
                                                                                        <Ellipse Stroke="{StaticResource TangoDarkForegroundBrush}" StrokeThickness="2" Width="42" Height="42"></Ellipse>
                                                                                        <TextBlock HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="20" FontWeight="Bold">1</TextBlock>
                                                                                    </Grid>
                                                                                    <TextBlock Margin="20 0 0 0" VerticalAlignment="Center">Select the best variation for each color:</TextBlock>
                                                                                </StackPanel>

                                                                                <ItemsControl Margin="65 40 120 0" ItemsSource="{Binding ApprovalFineTuneItems}" AlternationCount="1000">
                                                                                    <ItemsControl.ItemTemplate>
                                                                                        <DataTemplate>
                                                                                            <DockPanel>
                                                                                                <TextBlock Margin="0 0 20 0" VerticalAlignment="Center">
                                                                                        <Run>Color</Run>
                                                                                        <Run>#</Run><Run Text="{Binding RelativeSource={RelativeSource Mode=TemplatedParent}, Path=(ItemsControl.AlternationIndex),Mode=OneWay,Converter={StaticResource MathOperatorConverter},ConverterParameter='+1'}"></Run>
                                                                                                </TextBlock>
                                                                                                <touch:TouchFlatListBox ItemsSource="{Binding Suggestions}" SelectedItem="{Binding SelectedSuggestion}">
                                                                                                    <touch:TouchFlatListBox.ItemsPanel>
                                                                                                        <ItemsPanelTemplate>
                                                                                                            <UniformGrid Columns="{Binding Suggestions.Count}" Margin="0 20"></UniformGrid>
                                                                                                        </ItemsPanelTemplate>
                                                                                                    </touch:TouchFlatListBox.ItemsPanel>
                                                                                                    <touch:TouchFlatListBox.ItemTemplate>
                                                                                                        <DataTemplate>
                                                                                                            <Ellipse Width="70" Height="70" Fill="{Binding Brush}" Margin="30 0">
                                                                                                                <Ellipse.Style>
                                                                                                                    <Style TargetType="Ellipse">
                                                                                                                        <Setter Property="RenderTransformOrigin" Value="0.5,0.5"></Setter>
                                                                                                                        <Setter Property="RenderTransform">
                                                                                                                            <Setter.Value>
                                                                                                                                <ScaleTransform ScaleX="1" ScaleY="1" />
                                                                                                                            </Setter.Value>
                                                                                                                        </Setter>
                                                                                                                        <Setter Property="Effect">
                                                                                                                            <Setter.Value>
                                                                                                                                <DropShadowEffect Color="{StaticResource TangoDropShadowColor}" ShadowDepth="10" Direction="10" BlurRadius="15" Opacity="0" />
                                                                                                                            </Setter.Value>
                                                                                                                        </Setter>
                                                                                                                        <Style.Triggers>
                                                                                                                            <DataTrigger Binding="{Binding RelativeSource={RelativeSource AncestorType=ListBoxItem},Path=IsSelected}" Value="True">
                                                                                                                                <DataTrigger.EnterActions>
                                                                                                                                    <BeginStoryboard>
                                                                                                                                        <Storyboard>
                                                                                                                                            <DoubleAnimation Storyboard.TargetProperty="RenderTransform.ScaleX" To="1.2" Duration="00:00:0.2" />
                                                                                                                                            <DoubleAnimation Storyboard.TargetProperty="RenderTransform.ScaleY" To="1.2" Duration="00:00:0.2" />
                                                                                                                                            <DoubleAnimation Storyboard.TargetProperty="Effect.Opacity" To="1" Duration="00:00:0.2" />
                                                                                                                                        </Storyboard>
                                                                                                                                    </BeginStoryboard>
                                                                                                                                </DataTrigger.EnterActions>
                                                                                                                                <DataTrigger.ExitActions>
                                                                                                                                    <BeginStoryboard>
                                                                                                                                        <Storyboard>
                                                                                                                                            <DoubleAnimation Storyboard.TargetProperty="RenderTransform.ScaleX" To="1" Duration="00:00:0.2" />
                                                                                                                                            <DoubleAnimation Storyboard.TargetProperty="RenderTransform.ScaleY" To="1" Duration="00:00:0.2" />
                                                                                                                                            <DoubleAnimation Storyboard.TargetProperty="Effect.Opacity" To="0" Duration="00:00:0.2" />
                                                                                                                                        </Storyboard>
                                                                                                                                    </BeginStoryboard>
                                                                                                                                </DataTrigger.ExitActions>
                                                                                                                            </DataTrigger>
                                                                                                                        </Style.Triggers>
                                                                                                                    </Style>
                                                                                                                </Ellipse.Style>
                                                                                                            </Ellipse>
                                                                                                        </DataTemplate>
                                                                                                    </touch:TouchFlatListBox.ItemTemplate>
                                                                                                </touch:TouchFlatListBox>
                                                                                            </DockPanel>
                                                                                        </DataTemplate>
                                                                                    </ItemsControl.ItemTemplate>
                                                                                </ItemsControl>

                                                                                <StackPanel Orientation="Horizontal" Margin="0 40 0 0">
                                                                                    <Grid>
                                                                                        <Ellipse Stroke="{StaticResource TangoDarkForegroundBrush}" StrokeThickness="2" Width="42" Height="42"></Ellipse>
                                                                                        <TextBlock HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="20" FontWeight="Bold">2</TextBlock>
                                                                                    </Grid>
                                                                                    <TextBlock Margin="20 0 0 0" VerticalAlignment="Center">How to continue</TextBlock>
                                                                                </StackPanel>

                                                                                <UniformGrid Columns="2" Width="530" HorizontalAlignment="Left" Margin="0 40 0 20">
                                                                                    <StackPanel HorizontalAlignment="Left">
                                                                                        <touch:TouchButton Style="{StaticResource TangoHollowButton}" Width="180" Height="50" Command="{Binding ApproveFineTuningCommand}">
                                                                                            <StackPanel Orientation="Horizontal">
                                                                                                <touch:TouchIcon Icon="Check"></touch:TouchIcon>
                                                                                                <TextBlock Margin="10 0 0 0">DONE</TextBlock>
                                                                                            </StackPanel>
                                                                                        </touch:TouchButton>

                                                                                        <TextBlock Margin="0 15 0 0" TextAlignment="Center">All colors are approved</TextBlock>
                                                                                    </StackPanel>

                                                                                    <StackPanel HorizontalAlignment="Right">
                                                                                        <touch:TouchButton Style="{StaticResource TangoHollowButton}" Width="180" Height="50" Command="{Binding RepeatFineTuningCommand}">
                                                                                            <StackPanel Orientation="Horizontal">
                                                                                                <touch:TouchIcon Icon="Repeat"></touch:TouchIcon>
                                                                                                <TextBlock Margin="10 0 0 0">REPEAT</TextBlock>
                                                                                            </StackPanel>
                                                                                        </touch:TouchButton>

                                                                                        <TextBlock Margin="0 15 0 0" TextAlignment="Left" TextWrapping="Wrap" Width="170">Some color need more fine tuning</TextBlock>
                                                                                    </StackPanel>
                                                                                </UniformGrid>
                                                                            </StackPanel>
                                                                        </Setter.Value>
                                                                    </Setter>
                                                                </DataTrigger>

                                                                <DataTrigger Binding="{Binding Job.JobFineTuningStatus}" Value="{x:Static enumerations:FineTuningStatuses.Approved}">
                                                                    <Setter Property="Content">
                                                                        <Setter.Value>
                                                                            <StackPanel Margin="0 40 80 40">
                                                                                <DockPanel LastChildFill="False">
                                                                                    <TextBlock DockPanel.Dock="Left" VerticalAlignment="Center">
                                                                            <Run>Colors Approved:</Run>
                                                                            <Run Text="{Binding Job.FineTuningApproveDate,Converter={StaticResource DateTimeUTCToShortDateConverter},TargetNullValue=''}"></Run>
                                                                                    </TextBlock>
                                                                                    <touch:TouchButton DockPanel.Dock="Right" HorizontalAlignment="Right" Style="{StaticResource TangoHollowButton}" Width="220" Height="50" Command="{Binding RepeatFineTuningCommand}">
                                                                                        <StackPanel Orientation="Horizontal">
                                                                                            <touch:TouchIcon Icon="Plus"></touch:TouchIcon>
                                                                                            <TextBlock Margin="10 0 0 0">REPEAT FINE TUNING</TextBlock>
                                                                                        </StackPanel>
                                                                                    </touch:TouchButton>
                                                                                </DockPanel>
                                                                            </StackPanel>
                                                                        </Setter.Value>
                                                                    </Setter>
                                                                </DataTrigger>
                                                            </Style.Triggers>
                                                        </Style>
                                                    </ContentControl.Style>
                                                </ContentControl>
                                            </StackPanel>
                                        </touch:TouchExpander>
                                    </touch:TouchVirtualizedContentControl>
                                </StackPanel>
                            </StackPanel>
                        </touch:LightTouchScrollViewer>
                    </Grid>

                    <Border VerticalAlignment="Top" x:Name="borderEditDock" Background="{StaticResource TangoPrimaryBackgroundBrush}" BorderThickness="0 0 0 1" BorderBrush="{StaticResource TangoDividerBrush}" Padding="0 0 0 10">
                        <!--<Border.Effect>
                            <DropShadowEffect Color="{StaticResource TangoDropShadowColor}" BlurRadius="20" />
                        </Border.Effect>-->
                    </Border>
                </Grid>

                <Grid Grid.Row="1">
                    <Grid IsHitTestVisible="False">
                        <Grid.Background>
                            <LinearGradientBrush StartPoint="0.5,0" EndPoint="0.5,1">
                                <GradientStop Offset="0" Color="#AEFFFFFF" />
                                <GradientStop Offset="1" Color="{StaticResource TangoPrimaryBackgroundColor}" />
                            </LinearGradientBrush>
                        </Grid.Background>
                        <Rectangle Stroke="{StaticResource TangoDividerBrush}" StrokeThickness="1" VerticalAlignment="Top" />
                    </Grid>
                    <!--<Border Padding="20 20">
                    <Grid>
                        <DockPanel>
                            <touch:TouchButton IsEnabled="{Binding MachineProvider.MachineOperator.CanPrint}" DockPanel.Dock="Right" Height="54" Padding="0" Width="184" CornerRadius="30" BlurRadius="20" HorizontalAlignment="Right" DelayCommand="{Binding DyeCommand}" DelayCommandDuration="00:00:0.3">
                                DYE
                            </touch:TouchButton>

                            -->
                    <!--Add this in case you want to display job summery on bottom panel-->
                    <!--<localControls:JobSummeryViewer DataContext="{Binding Job}" Height="35" Margin="0 -20 30 0" />-->
                    <!--
                        </DockPanel>
                    </Grid>
                </Border>-->
                </Grid>

                <dragAndDrop:DraggingSurface x:Name="DraggingSurface" />
            </Grid>
        </touch:TouchLoadingPanel>

        <Border Padding="20" Background="{StaticResource TangoPrimaryBackgroundBrush}" BorderThickness="0 0 0 1" BorderBrush="{StaticResource TangoDividerBrush}">
            <Border.Effect>
                <DropShadowEffect Color="Silver" ShadowDepth="0" BlurRadius="20" Opacity="1" />
            </Border.Effect>

            <Grid>
                <StackPanel Orientation="Horizontal" Width="450" HorizontalAlignment="Left">
                    <TextBlock MaxWidth="360" TextTrimming="CharacterEllipsis" VerticalAlignment="Center" FontSize="{StaticResource TangoHeaderFontSize}" FontWeight="SemiBold" Text="{Binding Job.Name,FallbackValue='Job Name'}"/>
                    <TextBlock Margin="20 0 0 5" VerticalAlignment="Bottom" Foreground="{StaticResource TangoGrayTextBrush}">
                        <Run>(</Run><Run Text="{Binding Job.JobType,FallbackValue=Embroidery}"></Run><Run>)</Run>
                    </TextBlock>
                </StackPanel>
                <StackPanel Orientation="Horizontal" HorizontalAlignment="Right" VerticalAlignment="Bottom" Height="57" Margin="0 0 30 -45">
                    <touch:TouchIconButton Margin="0 0 30 0" Padding="17" Style="{StaticResource TangoRoundTouchIconButton}" Icon="EllipsisVSolid" />
                    <touch:TouchIconButton Command="{Binding RemoveJobCommand}" Margin="0 0 30 0" Padding="17" Style="{StaticResource TangoRoundTouchIconButton}" Icon="TrashAltRegular" />
                    <touch:TouchIconButton Command="{Binding SaveJobCommand}" Padding="18" Style="{StaticResource TangoRoundTouchIconButton}" Icon="SaveRegular" />
                </StackPanel>
            </Grid>
        </Border>
    </Grid>
</UserControl>