aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/Tango.Visuals/Knob/Knob.xaml
blob: 9c70ad3b9255a70c6a3b289bc3a5652eebcadb4f (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
<UserControl x:Class="Tango.Visuals.Knob"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             xmlns:local="clr-namespace:Tango.Visuals"
             mc:Ignorable="d" RenderOptions.BitmapScalingMode="Fant" Height="{Binding RelativeSource={RelativeSource Self},Path=ActualWidth}">
    <Grid x:Name="mainGrid">
        <Grid>
            <Grid.Background>
                <RadialGradientBrush x:Name="imgGlow"
		Center="0.5,0.5" GradientOrigin="0.5,0.5" RadiusX="0.40" RadiusY="0.40"  Opacity="0"
		SpreadMethod="Pad" ColorInterpolationMode="SRgbLinearInterpolation" >
                    <GradientStop Color="Transparent" Offset="1" />
                    <GradientStop Color="#FFFFFFFF" Offset="0.06" />
                </RadialGradientBrush>
            </Grid.Background>
        </Grid>
        <Grid>
            <Grid.RowDefinitions>
                <RowDefinition Height="28*"/>
                <RowDefinition Height="133*"/>
                <RowDefinition Height="28*"/>
            </Grid.RowDefinitions>
            <Grid.ColumnDefinitions>
                <ColumnDefinition Width="15*"/>
                <ColumnDefinition Width="69*"/>
                <ColumnDefinition Width="15*"/>
            </Grid.ColumnDefinitions> 
 
            <Grid x:Name="ellipseGrid" Grid.Column="1" Grid.Row="1" RenderTransformOrigin="0.5 0.5">
                <Image RenderOptions.BitmapScalingMode="Fant" x:Name="img" Margin="0 0 0 0" Grid.Column="1" Grid.Row="1" Stretch="Fill">
                </Image> 
                <Ellipse x:Name="maskEllipse" Margin="2">
                    <Ellipse.Fill>
                        <RadialGradientBrush
		Center="0.5,0.5" GradientOrigin="0.5,0.5" RadiusX="0.55" RadiusY="0.55"  Opacity="0"
		SpreadMethod="Pad" ColorInterpolationMode="ScRgbLinearInterpolation" >
                            <GradientStop Color="Gainsboro" Offset="1" />
                            <GradientStop Color="Transparent" Offset="0.6" />
                        </RadialGradientBrush>
                    </Ellipse.Fill>
                </Ellipse>
                <Ellipse x:Name="glowEllipse" StrokeThickness="1" Margin="2 2 2 2" Opacity="0">
                    <!--<Ellipse.Effect>
                        <DropShadowEffect x:Name="glowEffect" Color="Orange" ShadowDepth="0" BlurRadius="20" Opacity="0"/>
                    </Ellipse.Effect>-->

                </Ellipse>
                <Grid.RenderTransform>
                    <RotateTransform Angle="-140"></RotateTransform>
                </Grid.RenderTransform>
            </Grid>
            <Thumb x:Name="moveThumb" Opacity="0" Grid.Column="1" Grid.Row="1"></Thumb>

        </Grid>
    </Grid>
</UserControl>