Professional redesign: native window, settings, calmer UI
- WindowChrome: resizable, snap layouts, native shadow, DWM rounded corners; size/position remembered; fade-in after load (no theme flash) - Menu bar replaced by a settings window (theme system/light/dark, language, sound, autostart, categories, data, shortcuts, about) - Shared styles in Themes/Controls.xaml; neutral palette with one accent applied to Application.Resources (context menus/tooltips themed) - Rows: To-Do style check left, title + details, relative date right, actions on hover, visible selection (Enter edits, Del deletes) - No glow/scale effects; subtle animations (dialogs, snackbar, chevrons) - Checking a recurring task moves it to the next date (with undo) - Themed combo box, date picker, check box; neutral dialog headers - New flat app icon (tools/make_icon.py) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
33
Core/DialogAnimation.cs
Normal file
33
Core/DialogAnimation.cs
Normal file
@@ -0,0 +1,33 @@
|
||||
#nullable enable
|
||||
using System;
|
||||
using System.Windows;
|
||||
using System.Windows.Media;
|
||||
using System.Windows.Media.Animation;
|
||||
|
||||
namespace ReminderOrganizer
|
||||
{
|
||||
/// <summary>Subtle open animation for dialogs: fade in + 2 % scale, 140 ms, ease-out.</summary>
|
||||
public static class DialogAnimation
|
||||
{
|
||||
public static void Attach(Window window)
|
||||
{
|
||||
window.Opacity = 0;
|
||||
window.Loaded += (_, _) =>
|
||||
{
|
||||
var ease = new CubicEase { EasingMode = EasingMode.EaseOut };
|
||||
var duration = TimeSpan.FromMilliseconds(140);
|
||||
window.BeginAnimation(UIElement.OpacityProperty, new DoubleAnimation(0, 1, duration) { EasingFunction = ease });
|
||||
|
||||
if (window.Content is FrameworkElement root)
|
||||
{
|
||||
var scale = new ScaleTransform(0.98, 0.98);
|
||||
root.RenderTransformOrigin = new Point(0.5, 0.5);
|
||||
root.RenderTransform = scale;
|
||||
var anim = new DoubleAnimation(0.98, 1, duration) { EasingFunction = ease };
|
||||
scale.BeginAnimation(ScaleTransform.ScaleXProperty, anim);
|
||||
scale.BeginAnimation(ScaleTransform.ScaleYProperty, anim);
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -4,53 +4,80 @@ using System.Windows.Media;
|
||||
|
||||
namespace ReminderOrganizer.Core
|
||||
{
|
||||
/// <summary>One place for the light/dark palette – used by the main window and all dialogs.</summary>
|
||||
/// <summary>
|
||||
/// One place for the light/dark palette. Neutral greys + a single muted accent (Fluent-like).
|
||||
/// Applied to Application.Resources so context menus, tooltips and dialogs all follow the theme.
|
||||
/// </summary>
|
||||
public static class Theme
|
||||
{
|
||||
private static SolidColorBrush B(uint rgb)
|
||||
public static bool IsDark { get; private set; } = true;
|
||||
|
||||
private static SolidColorBrush B(uint rgb, byte alpha = 255)
|
||||
{
|
||||
var b = new SolidColorBrush(Color.FromRgb((byte)(rgb >> 16), (byte)(rgb >> 8), (byte)rgb));
|
||||
var b = new SolidColorBrush(Color.FromArgb(alpha, (byte)(rgb >> 16), (byte)(rgb >> 8), (byte)rgb));
|
||||
b.Freeze();
|
||||
return b;
|
||||
}
|
||||
|
||||
public static void Apply(ResourceDictionary res, bool dark)
|
||||
{
|
||||
if (ReferenceEquals(res, Application.Current?.Resources)) IsDark = dark;
|
||||
|
||||
// shared
|
||||
res["PrimaryBrush"] = B(0x5B5BD6);
|
||||
res["PrimaryHoverBrush"] = B(0x4C4CC4);
|
||||
res["DangerBrush"] = B(dark ? 0xF0706AU : 0xD93A34U);
|
||||
res["WarningBrush"] = B(0xE5A00D);
|
||||
res["SuccessBrush"] = B(dark ? 0x3DD68CU : 0x18A058U);
|
||||
res["SecondaryBrush"] = res["SuccessBrush"];
|
||||
|
||||
if (dark)
|
||||
{
|
||||
res["SidebarBrush"] = B(0x1A1A24);
|
||||
res["CardBrush"] = B(0x22222E);
|
||||
res["TextPrimaryBrush"] = B(0xF5F5F5);
|
||||
res["TextSecondaryBrush"] = B(0xA8A8BC);
|
||||
res["BorderBrush"] = B(0x3A3A4A);
|
||||
res["BackgroundBrush"] = B(0x121218);
|
||||
res["HoverBrush"] = B(0x2A2A3A);
|
||||
res["SidebarTextBrush"] = B(0xF5F5F5);
|
||||
res["SidebarSecondaryBrush"] = B(0x9999AA);
|
||||
res["MenuBackgroundBrush"] = B(0x22222E);
|
||||
res["PrimaryLightBrush"] = B(0x37345F);
|
||||
res["HeaderBrush"] = B(0x22222E);
|
||||
res["InputBackgroundBrush"] = B(0x2A2A38);
|
||||
res["BadgeBrush"] = B(0x37345F);
|
||||
res["BadgeTextBrush"] = B(0xC7C8FF);
|
||||
res["BackgroundBrush"] = B(0x16161A);
|
||||
res["SidebarBrush"] = B(0x1C1C21);
|
||||
res["HeaderBrush"] = B(0x1C1C21);
|
||||
res["CardBrush"] = B(0x202026);
|
||||
res["MenuBackgroundBrush"] = B(0x26262D);
|
||||
res["InputBackgroundBrush"] = B(0x1A1A1F);
|
||||
res["BorderBrush"] = B(0x2E2E36);
|
||||
res["DividerBrush"] = B(0x2A2A31);
|
||||
res["HoverBrush"] = B(0x2A2A31);
|
||||
res["SelectedBrush"] = B(0x2B2B45);
|
||||
res["TextPrimaryBrush"] = B(0xEDEDF2);
|
||||
res["TextSecondaryBrush"] = B(0x9C9CA8);
|
||||
res["TextTertiaryBrush"] = B(0x6E6E7A);
|
||||
res["SidebarTextBrush"] = B(0xDCDCE4);
|
||||
res["SidebarSecondaryBrush"] = B(0x80808C);
|
||||
res["AccentSubtleBrush"] = B(0x2D2D4C);
|
||||
res["AccentTextBrush"] = B(0xB9BAFF);
|
||||
res["PrimaryLightBrush"] = res["AccentSubtleBrush"];
|
||||
res["BadgeBrush"] = B(0x2D2D4C);
|
||||
res["BadgeTextBrush"] = B(0xB9BAFF);
|
||||
res["SnackbarBrush"] = B(0x33333C);
|
||||
}
|
||||
else
|
||||
{
|
||||
res["SidebarBrush"] = B(0xF8FAFC);
|
||||
res["BackgroundBrush"] = B(0xF6F7F9);
|
||||
res["SidebarBrush"] = B(0xEEF0F3);
|
||||
res["HeaderBrush"] = B(0xEEF0F3);
|
||||
res["CardBrush"] = B(0xFFFFFF);
|
||||
res["TextPrimaryBrush"] = B(0x1E293B);
|
||||
res["TextSecondaryBrush"] = B(0x64748B);
|
||||
res["BorderBrush"] = B(0xE2E8F0);
|
||||
res["BackgroundBrush"] = B(0xF1F5F9);
|
||||
res["HoverBrush"] = B(0xE2E8F0);
|
||||
res["SidebarTextBrush"] = B(0x1E293B);
|
||||
res["SidebarSecondaryBrush"] = B(0x64748B);
|
||||
res["MenuBackgroundBrush"] = B(0xFFFFFF);
|
||||
res["PrimaryLightBrush"] = B(0xEEF2FF);
|
||||
res["HeaderBrush"] = B(0xFFFFFF);
|
||||
res["InputBackgroundBrush"] = B(0xF1F5F9);
|
||||
res["BadgeBrush"] = B(0xE0E7FF);
|
||||
res["BadgeTextBrush"] = B(0x4338CA);
|
||||
res["InputBackgroundBrush"] = B(0xFFFFFF);
|
||||
res["BorderBrush"] = B(0xDDE0E6);
|
||||
res["DividerBrush"] = B(0xECEEF2);
|
||||
res["HoverBrush"] = B(0xE6E8EE);
|
||||
res["SelectedBrush"] = B(0xE9E9FB);
|
||||
res["TextPrimaryBrush"] = B(0x1B1D23);
|
||||
res["TextSecondaryBrush"] = B(0x646A78);
|
||||
res["TextTertiaryBrush"] = B(0x9AA0AC);
|
||||
res["SidebarTextBrush"] = B(0x2A2D35);
|
||||
res["SidebarSecondaryBrush"] = B(0x7A7F8C);
|
||||
res["AccentSubtleBrush"] = B(0xE4E4FA);
|
||||
res["AccentTextBrush"] = B(0x3F3FB5);
|
||||
res["PrimaryLightBrush"] = res["AccentSubtleBrush"];
|
||||
res["BadgeBrush"] = B(0xE8E8FB);
|
||||
res["BadgeTextBrush"] = B(0x4343B8);
|
||||
res["SnackbarBrush"] = B(0x2B2D35);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user