From 9007a27fb256b865331c99badfa73f6f71570c24 Mon Sep 17 00:00:00 2001 From: MaddoScientisto Date: Sat, 21 Feb 2026 16:49:13 +0100 Subject: [PATCH] Upgrade UI to MahApps.Metro with runtime theming Modernize WPF UI using MahApps.Metro: switch MainWindow to MetroWindow, add MetroTabControl/MetroTabItem, custom tab styles, and icon-based theme toggle. Move version display to window commands. Integrate MahApps resource dictionaries and ThemeManager for runtime theme switching. Update startup logic for proper theming. WinForms fallback retained. --- imagecatalog/ImageCatalog 2.csproj | 1 + imagecatalog/MainWindow.xaml | 134 ++++++++++++++++++++--------- imagecatalog/MainWindow.xaml.cs | 83 +++++++++++++++++- imagecatalog/Program.cs | 43 +++++++-- 4 files changed, 207 insertions(+), 54 deletions(-) diff --git a/imagecatalog/ImageCatalog 2.csproj b/imagecatalog/ImageCatalog 2.csproj index e4573cc..cbd865d 100644 --- a/imagecatalog/ImageCatalog 2.csproj +++ b/imagecatalog/ImageCatalog 2.csproj @@ -42,6 +42,7 @@ + diff --git a/imagecatalog/MainWindow.xaml b/imagecatalog/MainWindow.xaml index d8fec54..b423b4c 100644 --- a/imagecatalog/MainWindow.xaml +++ b/imagecatalog/MainWindow.xaml @@ -1,15 +1,18 @@ - - + Title="Image Catalog - WPF" Height="540" Width="800" + Background="{DynamicResource WindowBackgroundBrush}" Foreground="{DynamicResource ControlForegroundBrush}" + GlowBrush="{DynamicResource AccentBrush}"> + + @@ -38,8 +41,49 @@ + + + - + + + + + + + + @@ -54,14 +98,14 @@ - - - + + + - + @@ -155,15 +199,15 @@ - + - - + + - + @@ -206,15 +250,15 @@ - + - - + + - + @@ -240,15 +284,15 @@ - + - - + + - + @@ -275,15 +319,15 @@ - + - - + + - + @@ -317,15 +361,15 @@ - + - - + + - + @@ -388,14 +432,22 @@ - - + + - - - - + + + + + + + + + +