-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathColorBrewer.xaml
More file actions
55 lines (47 loc) · 2.69 KB
/
Copy pathColorBrewer.xaml
File metadata and controls
55 lines (47 loc) · 2.69 KB
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
<UserControl x:Class="CSharpCodeAnalyst.TreeMap.ColorBrewer"
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"
mc:Ignorable="d"
d:DesignHeight="150"
d:DesignWidth="400"
x:Name="_this">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="auto"/>
<ColumnDefinition Width="auto"/>
<ColumnDefinition Width="auto"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="auto"/>
<RowDefinition Height="auto"/>
<RowDefinition Height="auto"/>
<RowDefinition Height="auto"/>
</Grid.RowDefinitions>
<Label Grid.Row="0" Grid.Column="0" Content="Red"/>
<TextBox Grid.Row="0" Grid.Column="1" Width="60" Height="23"
Text="{Binding BrewedR, ElementName=_this, UpdateSourceTrigger=PropertyChanged}"
PreviewTextInput="PreviewRgbText"/>
<Slider x:Name="_red" Grid.Row="0" Grid.Column="2" Minimum="0" Maximum="255" VerticalAlignment="Center" Width="200" Margin="5"
Value="{Binding BrewedR, ElementName=_this}"/>
<Label Grid.Row="1" Grid.Column="0" Content="Green"/>
<TextBox Grid.Row="1" Grid.Column="1" Width="60" Height="23"
Text="{Binding BrewedG, ElementName=_this, UpdateSourceTrigger=PropertyChanged}"
PreviewTextInput="PreviewRgbText"/>
<Slider x:Name="_green" Grid.Row="1" Grid.Column="2" Minimum="0" Maximum="255" VerticalAlignment="Center" Width="200" Margin="5"
Value="{Binding BrewedG, ElementName=_this}"/>
<Label Grid.Row="2" Grid.Column="0" Content="Blue"/>
<TextBox Grid.Row="2" Grid.Column="1" Width="60" Height="23"
Text="{Binding BrewedB, ElementName=_this, UpdateSourceTrigger=PropertyChanged}"
PreviewTextInput="PreviewRgbText"/>
<Slider x:Name="_blue" Grid.Row="2" Grid.Column="2" Minimum="0" Maximum="255" VerticalAlignment="Center" Width="200" Margin="5"
Value="{Binding BrewedB, ElementName=_this}"/>
<Label Grid.Row="3" Grid.Column="0" Content="Color" Margin="0 5 0 0"/>
<Rectangle Grid.Row="3" Grid.Column="1" Width="60" Height="23" Margin="0 5 0 0">
<Rectangle.Fill>
<SolidColorBrush Color="{Binding ElementName=_this, Path=BrewedColor}"/>
</Rectangle.Fill>
</Rectangle>
</Grid>
</UserControl>