diff --git a/src/Avalonia.Controls/ToggleSwitch.cs b/src/Avalonia.Controls/ToggleSwitch.cs index 9af3ded18d..79638dce74 100644 --- a/src/Avalonia.Controls/ToggleSwitch.cs +++ b/src/Avalonia.Controls/ToggleSwitch.cs @@ -15,14 +15,14 @@ namespace Avalonia.Controls public class ToggleSwitch : ToggleButton { public static readonly StyledProperty OffContentProperty = - AvaloniaProperty.Register(nameof(OffContent)); + AvaloniaProperty.Register(nameof(OffContent), defaultValue:"Off"); public static readonly StyledProperty OffContentTemplateProperty = AvaloniaProperty.Register(nameof(OffContentTemplate)); public static readonly StyledProperty OnContentProperty = - AvaloniaProperty.Register(nameof(OnContent)); + AvaloniaProperty.Register(nameof(OnContent), defaultValue: "On"); public static readonly StyledProperty OnContentTemplateProperty = AvaloniaProperty.Register(nameof(OnContentTemplate)); diff --git a/src/Avalonia.Themes.Fluent/Accents/FluentControlResourcesDark.xaml b/src/Avalonia.Themes.Fluent/Accents/FluentControlResourcesDark.xaml index 923180f96d..9fa0458db3 100644 --- a/src/Avalonia.Themes.Fluent/Accents/FluentControlResourcesDark.xaml +++ b/src/Avalonia.Themes.Fluent/Accents/FluentControlResourcesDark.xaml @@ -349,7 +349,7 @@ 0 - 1.5 + 1 diff --git a/src/Avalonia.Themes.Fluent/Accents/FluentControlResourcesLight.xaml b/src/Avalonia.Themes.Fluent/Accents/FluentControlResourcesLight.xaml index fd7a17d2e3..5c23bc96ee 100644 --- a/src/Avalonia.Themes.Fluent/Accents/FluentControlResourcesLight.xaml +++ b/src/Avalonia.Themes.Fluent/Accents/FluentControlResourcesLight.xaml @@ -350,7 +350,7 @@ 0 - 1.5 + 1 diff --git a/src/Avalonia.Themes.Fluent/ToggleSwitch.xaml b/src/Avalonia.Themes.Fluent/ToggleSwitch.xaml index 2ae3b50b62..d1892d8685 100644 --- a/src/Avalonia.Themes.Fluent/ToggleSwitch.xaml +++ b/src/Avalonia.Themes.Fluent/ToggleSwitch.xaml @@ -13,11 +13,12 @@ - + VerticalAlignment="Bottom" + /> @@ -28,7 +29,7 @@ Text="The previewer Shows a preview off your code, this could slow down your system" TextWrapping="Wrap"/> @@ -100,15 +101,15 @@ 6 6 154 - 22 + 20 0