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:
2026-11-29 18:10:45 +01:00
parent 00e9990feb
commit 3e0b00f11c
28 changed files with 2100 additions and 1434 deletions

690
Themes/Controls.xaml Normal file
View File

@@ -0,0 +1,690 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<!--
Shared control styles. Colors are DynamicResources set by Core/Theme.cs on Application.Resources,
so everything (also context menus, tooltips, dialogs) follows light/dark.
Design rules: neutral greys, one accent, 4/8 px spacing, 6–10 px radii, no glow, no scaling on hover.
-->
<FontFamily x:Key="UiFont">Segoe UI Variable Text, Segoe UI</FontFamily>
<FontFamily x:Key="IconFont">Segoe Fluent Icons, Segoe MDL2 Assets</FontFamily>
<!-- defaults until Theme.Apply runs (dark) -->
<SolidColorBrush x:Key="PrimaryBrush" Color="#5B5BD6"/>
<SolidColorBrush x:Key="PrimaryHoverBrush" Color="#4C4CC4"/>
<SolidColorBrush x:Key="DangerBrush" Color="#F0706A"/>
<SolidColorBrush x:Key="WarningBrush" Color="#E5A00D"/>
<SolidColorBrush x:Key="SuccessBrush" Color="#3DD68C"/>
<SolidColorBrush x:Key="SecondaryBrush" Color="#3DD68C"/>
<SolidColorBrush x:Key="BackgroundBrush" Color="#16161A"/>
<SolidColorBrush x:Key="SidebarBrush" Color="#1C1C21"/>
<SolidColorBrush x:Key="HeaderBrush" Color="#1C1C21"/>
<SolidColorBrush x:Key="CardBrush" Color="#202026"/>
<SolidColorBrush x:Key="MenuBackgroundBrush" Color="#26262D"/>
<SolidColorBrush x:Key="InputBackgroundBrush" Color="#1A1A1F"/>
<SolidColorBrush x:Key="BorderBrush" Color="#2E2E36"/>
<SolidColorBrush x:Key="DividerBrush" Color="#2A2A31"/>
<SolidColorBrush x:Key="HoverBrush" Color="#2A2A31"/>
<SolidColorBrush x:Key="SelectedBrush" Color="#2B2B45"/>
<SolidColorBrush x:Key="TextPrimaryBrush" Color="#EDEDF2"/>
<SolidColorBrush x:Key="TextSecondaryBrush" Color="#9C9CA8"/>
<SolidColorBrush x:Key="TextTertiaryBrush" Color="#6E6E7A"/>
<SolidColorBrush x:Key="SidebarTextBrush" Color="#DCDCE4"/>
<SolidColorBrush x:Key="SidebarSecondaryBrush" Color="#80808C"/>
<SolidColorBrush x:Key="AccentSubtleBrush" Color="#2D2D4C"/>
<SolidColorBrush x:Key="AccentTextBrush" Color="#B9BAFF"/>
<SolidColorBrush x:Key="PrimaryLightBrush" Color="#2D2D4C"/>
<SolidColorBrush x:Key="BadgeBrush" Color="#2D2D4C"/>
<SolidColorBrush x:Key="BadgeTextBrush" Color="#B9BAFF"/>
<SolidColorBrush x:Key="SnackbarBrush" Color="#33333C"/>
<Geometry x:Key="FolderGeometry">M1.5,3.5 L6,3.5 L7.5,5 L14.5,5 L14.5,13.5 L1.5,13.5 Z</Geometry>
<!-- ========== scrolling ========== -->
<Style TargetType="ScrollBar">
<Setter Property="Width" Value="10"/>
<Setter Property="MinWidth" Value="10"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="ScrollBar">
<Grid Background="Transparent">
<Track x:Name="PART_Track" IsDirectionReversed="True">
<Track.Thumb>
<Thumb>
<Thumb.Template>
<ControlTemplate TargetType="Thumb">
<Border x:Name="t" Background="{DynamicResource TextTertiaryBrush}" Opacity="0.45"
CornerRadius="3" Width="6" Margin="0,2"/>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="t" Property="Opacity" Value="0.8"/>
</Trigger>
<Trigger Property="IsDragging" Value="True">
<Setter TargetName="t" Property="Opacity" Value="0.9"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Thumb.Template>
</Thumb>
</Track.Thumb>
</Track>
</Grid>
</ControlTemplate>
</Setter.Value>
</Setter>
<Style.Triggers>
<Trigger Property="Orientation" Value="Horizontal">
<Setter Property="Width" Value="Auto"/>
<Setter Property="Height" Value="10"/>
</Trigger>
</Style.Triggers>
</Style>
<!-- ========== tooltip ========== -->
<Style TargetType="ToolTip">
<Setter Property="Background" Value="{DynamicResource MenuBackgroundBrush}"/>
<Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}"/>
<Setter Property="BorderBrush" Value="{DynamicResource BorderBrush}"/>
<Setter Property="FontFamily" Value="{StaticResource UiFont}"/>
<Setter Property="FontSize" Value="12"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="ToolTip">
<Border Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="1"
CornerRadius="6" Padding="8,5" Margin="4" SnapsToDevicePixels="True">
<Border.Effect>
<DropShadowEffect BlurRadius="8" ShadowDepth="1" Opacity="0.18" Color="Black"/>
</Border.Effect>
<ContentPresenter/>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<!-- ========== menus (top menu + context menus) ========== -->
<Style TargetType="Menu">
<Setter Property="Background" Value="Transparent"/>
<Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}"/>
<Setter Property="FontFamily" Value="{StaticResource UiFont}"/>
</Style>
<Style TargetType="ContextMenu">
<Setter Property="FontFamily" Value="{StaticResource UiFont}"/>
<Setter Property="FontSize" Value="13"/>
<Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="ContextMenu">
<Border Background="{DynamicResource MenuBackgroundBrush}" BorderBrush="{DynamicResource BorderBrush}" BorderThickness="1"
CornerRadius="8" Padding="4" Margin="6">
<Border.Effect>
<DropShadowEffect BlurRadius="14" ShadowDepth="3" Opacity="0.22" Color="Black"/>
</Border.Effect>
<StackPanel IsItemsHost="True" KeyboardNavigation.DirectionalNavigation="Cycle"/>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="Separator">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Separator">
<Border Height="1" Margin="6,4" Background="{DynamicResource DividerBrush}"/>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style x:Key="{x:Static MenuItem.SeparatorStyleKey}" TargetType="Separator">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Separator">
<Border Height="1" Margin="6,4" Background="{DynamicResource DividerBrush}"/>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="MenuItem">
<Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}"/>
<Setter Property="Background" Value="Transparent"/>
<Setter Property="FontFamily" Value="{StaticResource UiFont}"/>
<Setter Property="FontSize" Value="13"/>
<Setter Property="Padding" Value="10,6"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="MenuItem">
<Border x:Name="Bd" Background="{TemplateBinding Background}" Padding="{TemplateBinding Padding}" CornerRadius="5" MinWidth="40">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition x:Name="IconCol" Width="26"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<ContentPresenter x:Name="Icon" ContentSource="Icon" VerticalAlignment="Center" HorizontalAlignment="Left"/>
<TextBlock x:Name="Check" Text="&#xE73E;" FontFamily="{StaticResource IconFont}" FontSize="12" VerticalAlignment="Center"
Foreground="{DynamicResource PrimaryBrush}" Visibility="Collapsed"/>
<ContentPresenter Grid.Column="1" ContentSource="Header" RecognizesAccessKey="True" VerticalAlignment="Center"/>
<TextBlock Grid.Column="2" Text="{TemplateBinding InputGestureText}" Margin="24,0,0,0" FontSize="12"
Foreground="{DynamicResource TextTertiaryBrush}" VerticalAlignment="Center"/>
<TextBlock x:Name="Arrow" Grid.Column="3" Text="&#xE76C;" FontFamily="{StaticResource IconFont}" FontSize="9"
Margin="12,0,0,0" VerticalAlignment="Center" Foreground="{DynamicResource TextSecondaryBrush}" Visibility="Collapsed"/>
<Popup x:Name="PART_Popup" IsOpen="{Binding IsSubmenuOpen, RelativeSource={RelativeSource TemplatedParent}}"
Placement="Right" HorizontalOffset="-2" AllowsTransparency="True" Focusable="False" PopupAnimation="Fade">
<Border Background="{DynamicResource MenuBackgroundBrush}" BorderBrush="{DynamicResource BorderBrush}" BorderThickness="1"
CornerRadius="8" Padding="4" Margin="6" MinWidth="180">
<Border.Effect>
<DropShadowEffect BlurRadius="14" ShadowDepth="3" Opacity="0.22" Color="Black"/>
</Border.Effect>
<StackPanel IsItemsHost="True" KeyboardNavigation.DirectionalNavigation="Cycle"/>
</Border>
</Popup>
</Grid>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="Role" Value="TopLevelHeader">
<Setter TargetName="PART_Popup" Property="Placement" Value="Bottom"/>
<Setter TargetName="PART_Popup" Property="HorizontalOffset" Value="-6"/>
<Setter TargetName="IconCol" Property="Width" Value="0"/>
<Setter Property="Padding" Value="10,5"/>
</Trigger>
<Trigger Property="Role" Value="SubmenuHeader">
<Setter TargetName="Arrow" Property="Visibility" Value="Visible"/>
</Trigger>
<Trigger Property="IsChecked" Value="True">
<Setter TargetName="Check" Property="Visibility" Value="Visible"/>
</Trigger>
<Trigger Property="IsHighlighted" Value="True">
<Setter TargetName="Bd" Property="Background" Value="{DynamicResource HoverBrush}"/>
</Trigger>
<Trigger Property="IsSubmenuOpen" Value="True">
<Setter TargetName="Bd" Property="Background" Value="{DynamicResource HoverBrush}"/>
</Trigger>
<Trigger Property="IsEnabled" Value="False">
<Setter Property="Foreground" Value="{DynamicResource TextTertiaryBrush}"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<!-- ========== buttons ========== -->
<Style x:Key="PrimaryButton" TargetType="Button">
<Setter Property="Foreground" Value="White"/>
<Setter Property="Background" Value="{DynamicResource PrimaryBrush}"/>
<Setter Property="FontFamily" Value="{StaticResource UiFont}"/>
<Setter Property="FontSize" Value="13"/>
<Setter Property="FontWeight" Value="SemiBold"/>
<Setter Property="Padding" Value="14,7"/>
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Button">
<Border x:Name="Bd" Background="{TemplateBinding Background}" CornerRadius="6" Padding="{TemplateBinding Padding}" SnapsToDevicePixels="True">
<ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="Bd" Property="Background" Value="{DynamicResource PrimaryHoverBrush}"/>
</Trigger>
<Trigger Property="IsPressed" Value="True">
<Setter TargetName="Bd" Property="Opacity" Value="0.85"/>
</Trigger>
<Trigger Property="IsEnabled" Value="False">
<Setter TargetName="Bd" Property="Opacity" Value="0.4"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style x:Key="SubtleButton" TargetType="Button">
<Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}"/>
<Setter Property="Background" Value="Transparent"/>
<Setter Property="BorderBrush" Value="{DynamicResource BorderBrush}"/>
<Setter Property="FontFamily" Value="{StaticResource UiFont}"/>
<Setter Property="FontSize" Value="13"/>
<Setter Property="Padding" Value="14,7"/>
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Button">
<Border x:Name="Bd" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="1"
CornerRadius="6" Padding="{TemplateBinding Padding}">
<ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="Bd" Property="Background" Value="{DynamicResource HoverBrush}"/>
</Trigger>
<Trigger Property="IsEnabled" Value="False">
<Setter TargetName="Bd" Property="Opacity" Value="0.4"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<!-- small square icon button (glyph as Content) -->
<Style x:Key="IconButton" TargetType="Button">
<Setter Property="FontFamily" Value="{StaticResource IconFont}"/>
<Setter Property="FontSize" Value="12"/>
<Setter Property="Foreground" Value="{DynamicResource TextSecondaryBrush}"/>
<Setter Property="Background" Value="Transparent"/>
<Setter Property="Width" Value="28"/>
<Setter Property="Height" Value="28"/>
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Button">
<Border x:Name="Bd" Background="{TemplateBinding Background}" CornerRadius="6">
<ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="Bd" Property="Background" Value="{DynamicResource HoverBrush}"/>
<Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}"/>
</Trigger>
<Trigger Property="IsEnabled" Value="False">
<Setter TargetName="Bd" Property="Opacity" Value="0.35"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<!-- window caption buttons (46 px wide like Windows) -->
<Style x:Key="CaptionButton" TargetType="Button">
<Setter Property="FontFamily" Value="{StaticResource IconFont}"/>
<Setter Property="FontSize" Value="10"/>
<Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}"/>
<Setter Property="Width" Value="46"/>
<Setter Property="Height" Value="40"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Button">
<Border x:Name="Bd" Background="Transparent">
<ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="Bd" Property="Background" Value="{DynamicResource HoverBrush}"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style x:Key="CloseCaptionButton" TargetType="Button" BasedOn="{StaticResource CaptionButton}">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Button">
<Border x:Name="Bd" Background="Transparent">
<ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="Bd" Property="Background" Value="#C42B1C"/>
<Setter Property="Foreground" Value="White"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<!-- ========== segmented control (radio buttons in a shared container) ========== -->
<Style x:Key="Segment" TargetType="RadioButton">
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="FontFamily" Value="{StaticResource UiFont}"/>
<Setter Property="FontSize" Value="12.5"/>
<Setter Property="Foreground" Value="{DynamicResource TextSecondaryBrush}"/>
<Setter Property="Padding" Value="12,4"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="RadioButton">
<Border x:Name="Bd" CornerRadius="5" Padding="{TemplateBinding Padding}" Background="Transparent" MinHeight="26">
<ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}"/>
</Trigger>
<Trigger Property="IsChecked" Value="True">
<Setter TargetName="Bd" Property="Background" Value="{DynamicResource CardBrush}"/>
<Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}"/>
<Setter TargetName="Bd" Property="Effect">
<Setter.Value>
<DropShadowEffect BlurRadius="4" ShadowDepth="1" Opacity="0.15" Color="Black"/>
</Setter.Value>
</Setter>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style x:Key="IconSegment" TargetType="RadioButton" BasedOn="{StaticResource Segment}">
<Setter Property="FontFamily" Value="{StaticResource IconFont}"/>
<Setter Property="FontSize" Value="13"/>
<Setter Property="Padding" Value="8,4"/>
</Style>
<Style x:Key="SegmentHost" TargetType="Border">
<Setter Property="Background" Value="{DynamicResource HoverBrush}"/>
<Setter Property="CornerRadius" Value="7"/>
<Setter Property="Padding" Value="2"/>
</Style>
<!-- toggle button with icon, same look as a segment (used for "group by month") -->
<Style x:Key="IconToggle" TargetType="ToggleButton">
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="FontFamily" Value="{StaticResource IconFont}"/>
<Setter Property="FontSize" Value="13"/>
<Setter Property="Foreground" Value="{DynamicResource TextSecondaryBrush}"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="ToggleButton">
<Border x:Name="Bd" CornerRadius="5" Padding="8,4" Background="Transparent" MinHeight="26">
<ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}"/>
</Trigger>
<Trigger Property="IsChecked" Value="True">
<Setter TargetName="Bd" Property="Background" Value="{DynamicResource CardBrush}"/>
<Setter Property="Foreground" Value="{DynamicResource PrimaryBrush}"/>
<Setter TargetName="Bd" Property="Effect">
<Setter.Value>
<DropShadowEffect BlurRadius="4" ShadowDepth="1" Opacity="0.15" Color="Black"/>
</Setter.Value>
</Setter>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<!-- ========== toggle switch ========== -->
<Style x:Key="ToggleSwitch" TargetType="CheckBox">
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="FontFamily" Value="{StaticResource UiFont}"/>
<Setter Property="FontSize" Value="12.5"/>
<Setter Property="Foreground" Value="{DynamicResource TextSecondaryBrush}"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="CheckBox">
<StackPanel Orientation="Horizontal" Background="Transparent">
<Border x:Name="Track" Width="32" Height="18" CornerRadius="9" BorderThickness="1"
BorderBrush="{DynamicResource TextTertiaryBrush}" Background="Transparent">
<Ellipse x:Name="Knob" Width="10" Height="10" Fill="{DynamicResource TextSecondaryBrush}"
HorizontalAlignment="Left" Margin="3,0">
<Ellipse.RenderTransform>
<TranslateTransform x:Name="KnobX" X="0"/>
</Ellipse.RenderTransform>
</Ellipse>
</Border>
<ContentPresenter Margin="8,0,0,0" VerticalAlignment="Center"/>
</StackPanel>
<ControlTemplate.Triggers>
<Trigger Property="IsChecked" Value="True">
<Setter TargetName="Track" Property="Background" Value="{DynamicResource PrimaryBrush}"/>
<Setter TargetName="Track" Property="BorderBrush" Value="{DynamicResource PrimaryBrush}"/>
<Setter TargetName="Knob" Property="Fill" Value="White"/>
<Trigger.EnterActions>
<BeginStoryboard>
<Storyboard>
<DoubleAnimation Storyboard.TargetName="KnobX" Storyboard.TargetProperty="X" To="14" Duration="0:0:0.12">
<DoubleAnimation.EasingFunction><CubicEase EasingMode="EaseOut"/></DoubleAnimation.EasingFunction>
</DoubleAnimation>
</Storyboard>
</BeginStoryboard>
</Trigger.EnterActions>
<Trigger.ExitActions>
<BeginStoryboard>
<Storyboard>
<DoubleAnimation Storyboard.TargetName="KnobX" Storyboard.TargetProperty="X" To="0" Duration="0:0:0.12">
<DoubleAnimation.EasingFunction><CubicEase EasingMode="EaseOut"/></DoubleAnimation.EasingFunction>
</DoubleAnimation>
</Storyboard>
</BeginStoryboard>
</Trigger.ExitActions>
</Trigger>
<Trigger Property="IsMouseOver" Value="True">
<Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<!-- ========== round "done" check (To-Do style) ========== -->
<Style x:Key="DoneCheck" TargetType="CheckBox">
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="CheckBox">
<Grid Background="Transparent" Width="22" Height="22">
<Ellipse x:Name="Ring" Width="18" Height="18" StrokeThickness="1.5" Stroke="{DynamicResource TextTertiaryBrush}" Fill="Transparent"/>
<TextBlock x:Name="Mark" Text="&#xE73E;" FontFamily="{StaticResource IconFont}" FontSize="10"
HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="{DynamicResource TextSecondaryBrush}" Opacity="0"/>
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="Ring" Property="Stroke" Value="{DynamicResource SuccessBrush}"/>
<Setter TargetName="Mark" Property="Opacity" Value="0.7"/>
<Setter TargetName="Mark" Property="Foreground" Value="{DynamicResource SuccessBrush}"/>
</Trigger>
<Trigger Property="IsChecked" Value="True">
<Setter TargetName="Ring" Property="Fill" Value="{DynamicResource SuccessBrush}"/>
<Setter TargetName="Ring" Property="Stroke" Value="{DynamicResource SuccessBrush}"/>
<Setter TargetName="Mark" Property="Opacity" Value="1"/>
<Setter TargetName="Mark" Property="Foreground" Value="White"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<!-- row action icon (edit/delete), hidden until the row is hovered or selected -->
<Style x:Key="RowIcon" TargetType="Button" BasedOn="{StaticResource IconButton}">
<Setter Property="Width" Value="26"/>
<Setter Property="Height" Value="26"/>
<Setter Property="CommandParameter" Value="{Binding}"/>
</Style>
<!-- ========== text inputs ========== -->
<Style x:Key="SearchBox" TargetType="TextBox">
<Setter Property="FontFamily" Value="{StaticResource UiFont}"/>
<Setter Property="FontSize" Value="13"/>
<Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}"/>
<Setter Property="CaretBrush" Value="{DynamicResource TextPrimaryBrush}"/>
<Setter Property="Background" Value="Transparent"/>
<Setter Property="BorderThickness" Value="0"/>
<Setter Property="VerticalContentAlignment" Value="Center"/>
</Style>
<!-- ========== combo box (all dialogs) ========== -->
<Style TargetType="ComboBoxItem">
<Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}"/>
<Setter Property="FontFamily" Value="{StaticResource UiFont}"/>
<Setter Property="FontSize" Value="13"/>
<Setter Property="Padding" Value="10,6"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="ComboBoxItem">
<Border x:Name="Bd" Background="Transparent" CornerRadius="5" Padding="{TemplateBinding Padding}" Margin="0,1">
<ContentPresenter VerticalAlignment="Center"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsHighlighted" Value="True">
<Setter TargetName="Bd" Property="Background" Value="{DynamicResource HoverBrush}"/>
</Trigger>
<Trigger Property="IsSelected" Value="True">
<Setter TargetName="Bd" Property="Background" Value="{DynamicResource AccentSubtleBrush}"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="ComboBox">
<Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}"/>
<Setter Property="Background" Value="{DynamicResource InputBackgroundBrush}"/>
<Setter Property="BorderBrush" Value="{DynamicResource BorderBrush}"/>
<Setter Property="FontFamily" Value="{StaticResource UiFont}"/>
<Setter Property="FontSize" Value="13"/>
<Setter Property="MinHeight" Value="32"/>
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="ComboBox">
<Grid>
<ToggleButton x:Name="Toggle" Focusable="False" ClickMode="Press"
IsChecked="{Binding IsDropDownOpen, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}">
<ToggleButton.Template>
<ControlTemplate TargetType="ToggleButton">
<Border x:Name="Bd" CornerRadius="6" BorderThickness="1"
Background="{Binding Background, RelativeSource={RelativeSource AncestorType=ComboBox}}"
BorderBrush="{Binding BorderBrush, RelativeSource={RelativeSource AncestorType=ComboBox}}">
<TextBlock Text="&#xE70D;" FontFamily="{StaticResource IconFont}" FontSize="10" HorizontalAlignment="Right"
VerticalAlignment="Center" Margin="0,0,10,0" Foreground="{DynamicResource TextSecondaryBrush}"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="Bd" Property="BorderBrush" Value="{DynamicResource TextTertiaryBrush}"/>
</Trigger>
<Trigger Property="IsChecked" Value="True">
<Setter TargetName="Bd" Property="BorderBrush" Value="{DynamicResource PrimaryBrush}"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</ToggleButton.Template>
</ToggleButton>
<ContentPresenter Margin="11,0,30,0" VerticalAlignment="Center" HorizontalAlignment="Left" IsHitTestVisible="False"
Content="{TemplateBinding SelectionBoxItem}"
ContentTemplate="{TemplateBinding SelectionBoxItemTemplate}"
ContentTemplateSelector="{TemplateBinding ItemTemplateSelector}"/>
<Popup x:Name="PART_Popup" IsOpen="{TemplateBinding IsDropDownOpen}" Placement="Bottom" AllowsTransparency="True"
Focusable="False" PopupAnimation="Fade" VerticalOffset="2">
<Border Background="{DynamicResource MenuBackgroundBrush}" BorderBrush="{DynamicResource BorderBrush}" BorderThickness="1"
CornerRadius="8" Padding="4" Margin="6,0,6,8"
MinWidth="{Binding ActualWidth, RelativeSource={RelativeSource TemplatedParent}}" MaxHeight="320">
<Border.Effect>
<DropShadowEffect BlurRadius="14" ShadowDepth="3" Opacity="0.22" Color="Black"/>
</Border.Effect>
<ScrollViewer VerticalScrollBarVisibility="Auto">
<StackPanel IsItemsHost="True" KeyboardNavigation.DirectionalNavigation="Contained"/>
</ScrollViewer>
</Border>
</Popup>
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="IsEnabled" Value="False">
<Setter Property="Opacity" Value="0.45"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<!-- ========== date picker (text field + calendar button) ========== -->
<Style TargetType="DatePickerTextBox">
<Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}"/>
<Setter Property="CaretBrush" Value="{DynamicResource TextPrimaryBrush}"/>
<Setter Property="Background" Value="Transparent"/>
<Setter Property="FontSize" Value="13"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="DatePickerTextBox">
<ScrollViewer x:Name="PART_ContentHost" VerticalAlignment="Center" Margin="10,0,0,0"
HorizontalScrollBarVisibility="Hidden" VerticalScrollBarVisibility="Hidden"/>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="DatePicker">
<Setter Property="FontFamily" Value="{StaticResource UiFont}"/>
<Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}"/>
<Setter Property="MinHeight" Value="32"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="DatePicker">
<Border x:Name="Bd" CornerRadius="6" BorderThickness="1"
Background="{DynamicResource InputBackgroundBrush}" BorderBrush="{DynamicResource BorderBrush}">
<Grid x:Name="PART_Root">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<DatePickerTextBox x:Name="PART_TextBox" Grid.Column="0"/>
<Button x:Name="PART_Button" Grid.Column="1" Content="&#xE787;" Style="{StaticResource IconButton}"
Width="28" Height="26" Margin="0,0,3,0" Focusable="False"/>
<Popup x:Name="PART_Popup" PlacementTarget="{Binding ElementName=PART_TextBox}" Placement="Bottom"
StaysOpen="False" AllowsTransparency="True"/>
</Grid>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="Bd" Property="BorderBrush" Value="{DynamicResource TextTertiaryBrush}"/>
</Trigger>
<Trigger Property="IsKeyboardFocusWithin" Value="True">
<Setter TargetName="Bd" Property="BorderBrush" Value="{DynamicResource PrimaryBrush}"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<!-- ========== check box (default look) ========== -->
<Style TargetType="CheckBox">
<Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}"/>
<Setter Property="FontFamily" Value="{StaticResource UiFont}"/>
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="CheckBox">
<StackPanel Orientation="Horizontal" Background="Transparent">
<Border x:Name="Box" Width="18" Height="18" CornerRadius="4" BorderThickness="1.5" VerticalAlignment="Center"
BorderBrush="{DynamicResource TextTertiaryBrush}" Background="Transparent">
<TextBlock x:Name="Mark" Text="&#xE73E;" FontFamily="{StaticResource IconFont}" FontSize="11" Foreground="White"
HorizontalAlignment="Center" VerticalAlignment="Center" Visibility="Collapsed"/>
</Border>
<ContentPresenter Margin="8,0,0,0" VerticalAlignment="Center"/>
</StackPanel>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="Box" Property="BorderBrush" Value="{DynamicResource PrimaryBrush}"/>
</Trigger>
<Trigger Property="IsChecked" Value="True">
<Setter TargetName="Box" Property="Background" Value="{DynamicResource PrimaryBrush}"/>
<Setter TargetName="Box" Property="BorderBrush" Value="{DynamicResource PrimaryBrush}"/>
<Setter TargetName="Mark" Property="Visibility" Value="Visible"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style x:Key="SectionLabel" TargetType="TextBlock">
<Setter Property="FontSize" Value="11"/>
<Setter Property="FontWeight" Value="SemiBold"/>
<Setter Property="Foreground" Value="{DynamicResource SidebarSecondaryBrush}"/>
</Style>
</ResourceDictionary>