From 102083ef188422f4a5bfd94d122873934dc5ac48 Mon Sep 17 00:00:00 2001 From: BornToBeRoot <16019165+BornToBeRoot@users.noreply.github.com> Date: Fri, 17 Oct 2025 19:00:21 +0200 Subject: [PATCH 1/3] Feature: Improve light theme readability --- .../Resources/Strings.Designer.cs | 10 +++- .../Resources/Strings.resx | 3 ++ .../Resources/Styles/TextBlockStyles.xaml | 2 +- .../ViewModels/SettingsAppearanceViewModel.cs | 13 +++-- .../Views/SettingsAppearanceView.xaml | 54 +++++++++++-------- 5 files changed, 50 insertions(+), 32 deletions(-) diff --git a/Source/NETworkManager.Localization/Resources/Strings.Designer.cs b/Source/NETworkManager.Localization/Resources/Strings.Designer.cs index 2e8f0b1750..7474254302 100644 --- a/Source/NETworkManager.Localization/Resources/Strings.Designer.cs +++ b/Source/NETworkManager.Localization/Resources/Strings.Designer.cs @@ -1,7 +1,6 @@ //------------------------------------------------------------------------------ // // This code was generated by a tool. -// Runtime Version:4.0.30319.42000 // // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. @@ -4678,6 +4677,15 @@ public static string HelpMessage_ThreadPoolAdditionalMinThreads { } } + /// + /// Looks up a localized string similar to Use custom themes to personalize the appearance of the application. You can edit or add theme in the "Program Folder > Themes" directory. For more details, refer to the documentation.. + /// + public static string HelpMessage_UseCustomThemes { + get { + return ResourceManager.GetString("HelpMessage_UseCustomThemes", resourceCulture); + } + } + /// /// Looks up a localized string similar to Hidden applications. /// diff --git a/Source/NETworkManager.Localization/Resources/Strings.resx b/Source/NETworkManager.Localization/Resources/Strings.resx index d88ec26a51..56be8078c4 100644 --- a/Source/NETworkManager.Localization/Resources/Strings.resx +++ b/Source/NETworkManager.Localization/Resources/Strings.resx @@ -3993,4 +3993,7 @@ Right-click for more options. Collapse all + + Use custom themes to personalize the appearance of the application. You can edit or add theme in the "Program Folder > Themes" directory. For more details, refer to the documentation. + \ No newline at end of file diff --git a/Source/NETworkManager/Resources/Styles/TextBlockStyles.xaml b/Source/NETworkManager/Resources/Styles/TextBlockStyles.xaml index 886e024a66..a2b2fd109d 100644 --- a/Source/NETworkManager/Resources/Styles/TextBlockStyles.xaml +++ b/Source/NETworkManager/Resources/Styles/TextBlockStyles.xaml @@ -7,7 +7,7 @@ diff --git a/Source/NETworkManager/ViewModels/SettingsAppearanceViewModel.cs b/Source/NETworkManager/ViewModels/SettingsAppearanceViewModel.cs index 35a44b5f96..cd82cf16af 100644 --- a/Source/NETworkManager/ViewModels/SettingsAppearanceViewModel.cs +++ b/Source/NETworkManager/ViewModels/SettingsAppearanceViewModel.cs @@ -1,8 +1,8 @@ -using System.ComponentModel; +using NETworkManager.Models.Appearance; +using NETworkManager.Settings; +using System.ComponentModel; using System.Linq; using System.Windows.Data; -using NETworkManager.Models.Appearance; -using NETworkManager.Settings; namespace NETworkManager.ViewModels; @@ -26,7 +26,7 @@ public ThemeColorInfo SelectedTheme if (!_isLoading && !UseCustomTheme) { - AppearanceManager.ChangeTheme(value.Name); + AppearanceManager.ChangeTheme(value.Name, SelectedAccent.Name); SettingsManager.Current.Appearance_Theme = value.Name; } @@ -35,7 +35,6 @@ public ThemeColorInfo SelectedTheme } } - public ICollectionView Accents { get; } private AccentColorInfo _selectedAccent; @@ -50,7 +49,7 @@ public AccentColorInfo SelectedAccent if (!_isLoading && !UseCustomTheme) { - AppearanceManager.ChangeAccent(value.Name); + AppearanceManager.ChangeTheme(SelectedTheme.Name, value.Name); SettingsManager.Current.Appearance_Accent = value.Name; } @@ -95,7 +94,7 @@ public ThemeInfo SelectedCustomTheme if (!_isLoading && UseCustomTheme) { - AppearanceManager.ChangeTheme(value); + AppearanceManager.ChangeTheme(value.Name); SettingsManager.Current.Appearance_CustomThemeName = value.Name; } diff --git a/Source/NETworkManager/Views/SettingsAppearanceView.xaml b/Source/NETworkManager/Views/SettingsAppearanceView.xaml index c39767c5a3..cb301b42ec 100644 --- a/Source/NETworkManager/Views/SettingsAppearanceView.xaml +++ b/Source/NETworkManager/Views/SettingsAppearanceView.xaml @@ -15,15 +15,15 @@ - - + + ToolTip="{Binding Name, Converter={StaticResource ResourceKey=ThemeToStringConverter}}" /> @@ -39,15 +39,15 @@ - - + - + @@ -63,26 +63,34 @@ - - - + + + + + +