Skip to content

Commit bb3c1c6

Browse files
committed
Applied XAML styles
1 parent 103ed36 commit bb3c1c6

File tree

2 files changed

+32
-14
lines changed

2 files changed

+32
-14
lines changed

components/ColorAnalyzer/samples/ContrastHelperSample.xaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!-- Licensed to the .NET Foundation under one or more agreements. The .NET Foundation licenses this file to you under the MIT license. See the LICENSE file in the project root for more information. -->
1+
<!-- Licensed to the .NET Foundation under one or more agreements. The .NET Foundation licenses this file to you under the MIT license. See the LICENSE file in the project root for more information. -->
22
<Page x:Class="ColorAnalyzerExperiment.Samples.ContrastHelperSample"
33
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
44
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
@@ -12,9 +12,9 @@
1212
<Page.Background>
1313
<SolidColorBrush Color="{x:Bind DesiredBackground, Mode=OneWay}" />
1414
</Page.Background>
15-
16-
<StackPanel HorizontalAlignment="Center"
17-
Padding="20"
15+
16+
<StackPanel Padding="20"
17+
HorizontalAlignment="Center"
1818
VerticalAlignment="Top"
1919
Spacing="2">
2020
<TextBlock x:Name="TextSample"
Lines changed: 28 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,41 @@
1-
<UserControl x:Class="ColorAnalyzerExperiment.Samples.ContrastOptionsPane"
1+
<UserControl x:Class="ColorAnalyzerExperiment.Samples.ContrastOptionsPane"
22
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
33
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
4+
xmlns:controls="using:CommunityToolkit.WinUI.Controls"
45
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
56
xmlns:local="using:ColorAnalyzerExperiment.Samples"
6-
xmlns:controls="using:CommunityToolkit.WinUI.Controls"
77
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
88
mc:Ignorable="d">
99

1010
<StackPanel Spacing="2">
11-
<TextBlock Text="Desired Foreground"/>
12-
<controls:ColorPicker Color="White" IsColorSliderVisible="True" IsColorChannelTextInputVisible="True" ColorChanged="Foreground_ColorChanged"/>
13-
14-
<TextBlock Text="Background"/>
15-
<controls:ColorPicker Color="Black" IsColorSliderVisible="True" IsColorChannelTextInputVisible="True" ColorChanged="Background_ColorChanged"/>
11+
<TextBlock Text="Desired Foreground" />
12+
<controls:ColorPicker ColorChanged="Foreground_ColorChanged"
13+
IsColorChannelTextInputVisible="True"
14+
IsColorSliderVisible="True"
15+
Color="White" />
1616

17-
<Slider Header="Minimum Ratio" Value="3" Minimum="1" Maximum="21" ValueChanged="Ratio_ValueChanged"/>
17+
<TextBlock Text="Background" />
18+
<controls:ColorPicker ColorChanged="Background_ColorChanged"
19+
IsColorChannelTextInputVisible="True"
20+
IsColorSliderVisible="True"
21+
Color="Black" />
1822

19-
<Slider Header="Font Size" Value="18" Minimum="8" Maximum="48" ValueChanged="FontSize_ValueChanged"/>
23+
<Slider Header="Minimum Ratio"
24+
Maximum="21"
25+
Minimum="1"
26+
ValueChanged="Ratio_ValueChanged"
27+
Value="3" />
2028

21-
<Slider Header="Stroke Thickness" Value="4" Minimum="0" Maximum="8" ValueChanged="Thickness_ValueChanged"/>
29+
<Slider Header="Font Size"
30+
Maximum="48"
31+
Minimum="8"
32+
ValueChanged="FontSize_ValueChanged"
33+
Value="18" />
34+
35+
<Slider Header="Stroke Thickness"
36+
Maximum="8"
37+
Minimum="0"
38+
ValueChanged="Thickness_ValueChanged"
39+
Value="4" />
2240
</StackPanel>
2341
</UserControl>

0 commit comments

Comments
 (0)