From 612a785d79468bf97858a67d2bfca2c0091fab75 Mon Sep 17 00:00:00 2001 From: koal44 Date: Mon, 18 Mar 2024 13:21:21 -0700 Subject: [PATCH] Improve lineargradient border for TextBox in Light/Dark theme (also effects PasswordBox and NumberBox) --- src/Wpf.Ui.Gallery/Views/Pages/Text/TextBoxPage.xaml | 7 +++++-- src/Wpf.Ui/Controls/TextBox/TextBox.xaml | 6 +++--- src/Wpf.Ui/Resources/Theme/Dark.xaml | 9 +++------ src/Wpf.Ui/Resources/Theme/Light.xaml | 9 +++------ 4 files changed, 14 insertions(+), 17 deletions(-) diff --git a/src/Wpf.Ui.Gallery/Views/Pages/Text/TextBoxPage.xaml b/src/Wpf.Ui.Gallery/Views/Pages/Text/TextBoxPage.xaml index 0ff6b51ce..0a4774c7d 100644 --- a/src/Wpf.Ui.Gallery/Views/Pages/Text/TextBoxPage.xaml +++ b/src/Wpf.Ui.Gallery/Views/Pages/Text/TextBoxPage.xaml @@ -11,7 +11,7 @@ controls:PageControlDocumentation.DocumentationType="{x:Type ui:TextBox}" d:DataContext="{d:DesignInstance local:TextBoxPage, IsDesignTimeCreatable=False}" - d:DesignHeight="450" + d:DesignHeight="750" d:DesignWidth="800" ui:Design.Background="{DynamicResource ApplicationBackgroundBrush}" ui:Design.Foreground="{DynamicResource TextFillColorPrimaryBrush}" @@ -34,7 +34,10 @@ Margin="0,36,0,0" HeaderText="A multi-line TextBox." XamlCode="<ui:TextBox PlaceholderText="Type something..."TextWrapping="Wrap" />"> - + diff --git a/src/Wpf.Ui/Controls/TextBox/TextBox.xaml b/src/Wpf.Ui/Controls/TextBox/TextBox.xaml index bbfc4cca1..3b620802b 100644 --- a/src/Wpf.Ui/Controls/TextBox/TextBox.xaml +++ b/src/Wpf.Ui/Controls/TextBox/TextBox.xaml @@ -14,7 +14,7 @@ xmlns:controls="clr-namespace:Wpf.Ui.Controls" xmlns:system="clr-namespace:System;assembly=System.Runtime"> - 1,1,1,0 + 1,1,1,1 0,0,0,1 10,0,0,0 0,0,10,0 @@ -206,8 +206,8 @@ BorderBrush="Transparent" Command="{Binding Path=TemplateButtonCommand, RelativeSource={RelativeSource TemplatedParent}}" Cursor="Arrow" - IsTabStop="False" - Foreground="{DynamicResource TextControlButtonForeground}"> + Foreground="{DynamicResource TextControlButtonForeground}" + IsTabStop="False"> diff --git a/src/Wpf.Ui/Resources/Theme/Dark.xaml b/src/Wpf.Ui/Resources/Theme/Dark.xaml index b2f609801..5a8200d85 100644 --- a/src/Wpf.Ui/Resources/Theme/Dark.xaml +++ b/src/Wpf.Ui/Resources/Theme/Dark.xaml @@ -267,13 +267,10 @@ - - - - + - - + + diff --git a/src/Wpf.Ui/Resources/Theme/Light.xaml b/src/Wpf.Ui/Resources/Theme/Light.xaml index cf93807bb..a8288560c 100644 --- a/src/Wpf.Ui/Resources/Theme/Light.xaml +++ b/src/Wpf.Ui/Resources/Theme/Light.xaml @@ -268,13 +268,10 @@ - - - - + - - + +