committed by
GitHub
110 changed files with 11237 additions and 11231 deletions
@ -0,0 +1,27 @@ |
|||||
|
using Avalonia; |
||||
|
using MiniMvvm; |
||||
|
|
||||
|
namespace ControlCatalog.ViewModels |
||||
|
{ |
||||
|
public class ExpanderPageViewModel : ViewModelBase |
||||
|
{ |
||||
|
private object _cornerRadius = AvaloniaProperty.UnsetValue; |
||||
|
private bool _rounded; |
||||
|
|
||||
|
public object CornerRadius |
||||
|
{ |
||||
|
get => _cornerRadius; |
||||
|
private set => RaiseAndSetIfChanged(ref _cornerRadius, value); |
||||
|
} |
||||
|
|
||||
|
public bool Rounded |
||||
|
{ |
||||
|
get => _rounded; |
||||
|
set |
||||
|
{ |
||||
|
if (RaiseAndSetIfChanged(ref _rounded, value)) |
||||
|
CornerRadius = _rounded ? new CornerRadius(25) : AvaloniaProperty.UnsetValue; |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
} |
||||
File diff suppressed because it is too large
@ -1,121 +1,117 @@ |
|||||
<!-- |
<!-- |
||||
// (c) Copyright Microsoft Corporation. |
// (c) Copyright Microsoft Corporation. |
||||
// This source is subject to the Microsoft Public License (Ms-PL). |
// This source is subject to the Microsoft Public License (Ms-PL). |
||||
// Please see http://go.microsoft.com/fwlink/?LinkID=131993 for details. |
// Please see http://go.microsoft.com/fwlink/?LinkID=131993 for details. |
||||
// All other rights reserved. |
// All other rights reserved. |
||||
--> |
--> |
||||
|
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
||||
|
<Design.PreviewWith> |
||||
|
<Border Padding="20"> |
||||
|
<StackPanel Spacing="20"> |
||||
|
<CalendarButton/> |
||||
|
</StackPanel> |
||||
|
</Border> |
||||
|
</Design.PreviewWith> |
||||
|
|
||||
<Styles xmlns="https://github.com/avaloniaui"> |
<ControlTheme x:Key="{x:Type CalendarButton}" TargetType="CalendarButton"> |
||||
<Style Selector="CalendarButton"> |
<Setter Property="ClickMode" Value="Release" /> |
||||
<Setter Property="ClickMode" Value="Release"/> |
<Setter Property="MinWidth" Value="40" /> |
||||
<Setter Property="MinWidth" Value="40"/> |
<Setter Property="MinHeight" Value="40" /> |
||||
<Setter Property="MinHeight" Value="40"/> |
<Setter Property="Margin" Value="1" /> |
||||
<Setter Property="Margin" Value="1"/> |
<Setter Property="Padding" Value="0,0,0,0" /> |
||||
<Setter Property="Padding" Value="0,0,0,0"/> |
|
||||
<!--These are actually set on the CalendarView in WinUI--> |
<!--These are actually set on the CalendarView in WinUI--> |
||||
<Setter Property="Foreground" Value="{DynamicResource CalendarViewCalendarItemForeground}"/> |
<Setter Property="Foreground" Value="{DynamicResource CalendarViewCalendarItemForeground}" /> |
||||
<Setter Property="Background" Value="{DynamicResource CalendarViewCalendarItemRevealBackground}"/> |
<Setter Property="Background" Value="{DynamicResource CalendarViewCalendarItemRevealBackground}" /> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource CalendarViewCalendarItemRevealBorderBrush}"/> |
<Setter Property="BorderBrush" Value="{DynamicResource CalendarViewCalendarItemRevealBorderBrush}" /> |
||||
<Setter Property="BorderThickness" Value="2"/> |
<Setter Property="BorderThickness" Value="2" /> |
||||
<Setter Property="FontSize" Value="20"/> |
<Setter Property="FontSize" Value="20" /> |
||||
<Setter Property="ClipToBounds" Value="False"/> |
<Setter Property="ClipToBounds" Value="False" /> |
||||
<Setter Property="HorizontalContentAlignment" Value="Center"/> |
<Setter Property="HorizontalContentAlignment" Value="Center" /> |
||||
<Setter Property="VerticalContentAlignment" Value="Center"/> |
<Setter Property="VerticalContentAlignment" Value="Center" /> |
||||
<Setter Property="Template"> |
<Setter Property="Template"> |
||||
<ControlTemplate> |
<ControlTemplate> |
||||
<Panel> |
<Panel> |
||||
<!-- To mimic WinUI SystemFocusVisual, Focus visual is drawn outside the bounds of the item --> |
<!-- To mimic WinUI SystemFocusVisual, Focus visual is drawn outside the bounds of the item --> |
||||
<Border Name="Root" Background="{TemplateBinding Background}" |
<Border Name="Root" Background="{TemplateBinding Background}" |
||||
BorderThickness="0" ClipToBounds="True"> |
BorderThickness="0" ClipToBounds="True"> |
||||
|
|
||||
<ContentControl Name="Content" |
<ContentControl Name="Content" |
||||
ContentTemplate="{TemplateBinding ContentTemplate}" |
ContentTemplate="{TemplateBinding ContentTemplate}" |
||||
Content="{TemplateBinding Content}" |
Content="{TemplateBinding Content}" |
||||
HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" |
HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" |
||||
VerticalAlignment="{TemplateBinding VerticalContentAlignment}" |
VerticalAlignment="{TemplateBinding VerticalContentAlignment}" |
||||
FontSize="{TemplateBinding FontSize}" |
FontSize="{TemplateBinding FontSize}" |
||||
Margin="{TemplateBinding Padding}"/> |
Margin="{TemplateBinding Padding}" /> |
||||
|
|
||||
</Border> |
</Border> |
||||
|
|
||||
<!-- Drawn Border should render on top of background to preserve the 1px |
<!-- Drawn Border should render on top of background to preserve the 1px margin between items --> |
||||
margin between items--> |
|
||||
<Border Name="Border" |
<Border Name="Border" |
||||
BorderThickness="2" |
BorderThickness="2" |
||||
BorderBrush="{TemplateBinding BorderBrush}"/> |
BorderBrush="{TemplateBinding BorderBrush}" /> |
||||
|
|
||||
<!--Removed for now...WinUI doesn't have selection follow focus, and only uses |
|
||||
focus visual w/ keyboard focus |
|
||||
<Border Name="FocusVisual" BorderThickness="2" |
|
||||
BorderBrush="{DynamicResource SystemControlHighlightBaseHighBrush}" |
|
||||
IsHitTestVisible="False" |
|
||||
Margin="-2" CornerRadius="{DynamicResource ControlCornerRadius}"/>--> |
|
||||
</Panel> |
</Panel> |
||||
</ControlTemplate> |
</ControlTemplate> |
||||
</Setter> |
</Setter> |
||||
</Style> |
|
||||
<!--<Style Selector="CalendarButton /template/ Border#FocusVisual"> |
|
||||
<Setter Property="IsVisible" Value="False"/> |
|
||||
</Style>--> |
|
||||
|
|
||||
<Style Selector="CalendarButton:pointerover /template/ Border#Border"> |
<Style Selector="^:pointerover /template/ Border#Border"> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource CalendarViewHoverBorderBrush}"/> |
<Setter Property="BorderBrush" Value="{DynamicResource CalendarViewHoverBorderBrush}" /> |
||||
</Style> |
</Style> |
||||
<Style Selector="CalendarButton:pressed /template/ Border#Border"> |
|
||||
<Setter Property="BorderBrush" Value="{DynamicResource CalendarViewPressedBorderBrush}"/> |
|
||||
</Style> |
|
||||
|
|
||||
<!-- Adjusted :selected to look like :today from DayItem --> |
<Style Selector="^:pressed /template/ Border#Border"> |
||||
<Style Selector="CalendarButton:selected /template/ Border#Root"> |
<Setter Property="BorderBrush" Value="{DynamicResource SystemAccentColorDark2}" /> |
||||
<Setter Property="Background" Value="{DynamicResource SystemAccentColor}"/> |
</Style> |
||||
</Style> |
|
||||
<Style Selector="CalendarButton:selected /template/ Border#Border"> |
<!-- Adjusted :selected to look like :today from DayItem --> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource CalendarViewSelectedBorderBrush}"/> |
<Style Selector="^:selected"> |
||||
</Style> |
<Style Selector="^ /template/ Border#Root"> |
||||
<Style Selector="CalendarButton:selected:pointerover /template/ Border#Root"> |
<Setter Property="Background" Value="{DynamicResource SystemAccentColor}" /> |
||||
<Setter Property="Background"> |
</Style> |
||||
<SolidColorBrush Color="{DynamicResource SystemAccentColor}"/> |
|
||||
</Setter> |
<Style Selector="^ /template/ Border#Border"> |
||||
</Style> |
<Setter Property="BorderBrush" Value="{DynamicResource CalendarViewSelectedBorderBrush}" /> |
||||
<Style Selector="CalendarButton:selected:pointerover /template/ Border#Border"> |
</Style> |
||||
<Setter Property="BorderBrush"> |
|
||||
<SolidColorBrush Color="{DynamicResource SystemAccentColorDark1}"/> |
<Style Selector="^ /template/ ContentControl#Content"> |
||||
</Setter> |
<Setter Property="Foreground" Value="{DynamicResource CalendarViewTodayForeground}" /> |
||||
</Style> |
<Setter Property="FontWeight" Value="SemiBold" /> |
||||
<Style Selector="CalendarButton:selected:pressed /template/ Border#Root"> |
</Style> |
||||
<Setter Property="Background"> |
|
||||
<SolidColorBrush Color="{DynamicResource SystemAccentColor}"/> |
<Style Selector="^:pointerover"> |
||||
</Setter> |
<Style Selector="^ /template/ Border#Border"> |
||||
</Style> |
<Setter Property="BorderBrush" Value="{DynamicResource SystemAccentColorDark1}" /> |
||||
<Style Selector="CalendarButton:pressed /template/ Border#Border"> |
</Style> |
||||
<Setter Property="BorderBrush"> |
<Style Selector="^ /template/ Border#Root"> |
||||
<SolidColorBrush Color="{DynamicResource SystemAccentColorDark2}"/> |
<Setter Property="Background" Value="{DynamicResource SystemAccentColor}" /> |
||||
</Setter> |
</Style> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="CalendarButton:selected /template/ ContentControl#Content"> |
<Style Selector="^:pressed"> |
||||
<Setter Property="Foreground" Value="{DynamicResource CalendarViewTodayForeground}"/> |
<Style Selector="^ /template/ Border#Border"> |
||||
<Setter Property="FontWeight" Value="SemiBold"/> |
<Setter Property="BorderBrush" Value="{DynamicResource SystemAccentColorDark2}" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<!-- WinUI calls this OutOfFocus --> |
<Style Selector="^ /template/ Border#Root"> |
||||
<Style Selector="CalendarButton:inactive /template/ Border#Root"> |
<Setter Property="Background" Value="{DynamicResource SystemAccentColor}" /> |
||||
<!-- These are probably set in code, but consistent --> |
</Style> |
||||
<Setter Property="Background" Value="{DynamicResource CalendarViewOutOfScopeBackground}"/> |
</Style> |
||||
</Style> |
</Style> |
||||
<Style Selector="CalendarButton:inactive /template/ ContentControl#Content"> |
|
||||
<Setter Property="Foreground" Value="{DynamicResource CalendarViewOutOfScopeForeground}"/> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="CalendarButton:blackout /template/ ContentControl#Content"> |
<!-- WinUI calls this OutOfFocus --> |
||||
<Setter Property="Foreground" Value="{DynamicResource CalendarViewBlackoutForeground}"/> |
<Style Selector="^:inactive"> |
||||
</Style> |
<Style Selector="^ /template/ Border#Root"> |
||||
|
<!-- These are probably set in code, but consistent --> |
||||
|
<Setter Property="Background" Value="{DynamicResource CalendarViewOutOfScopeBackground}"/> |
||||
|
</Style> |
||||
|
<Style Selector="^ /template/ ContentControl#Content"> |
||||
|
<Setter Property="Foreground" Value="{DynamicResource CalendarViewOutOfScopeForeground}"/> |
||||
|
</Style> |
||||
|
</Style> |
||||
|
|
||||
<!--<Style Selector="CalendarButton:dayfocused /template/ Border#FocusVisual"> |
<Style Selector="^:blackout /template/ ContentControl#Content"> |
||||
<Setter Property="IsVisible" Value="True"/> |
<Setter Property="Foreground" Value="{DynamicResource CalendarViewBlackoutForeground}" /> |
||||
</Style>--> |
</Style> |
||||
|
|
||||
<Style Selector="CalendarDayButton:disabled /template/ ContentControl#Content"> |
<Style Selector="^:disabled /template/ ContentControl#Content"> |
||||
<Setter Property="Foreground" Value="{DynamicResource CalendarViewWeekDayForegroundDisabled}"/> |
<Setter Property="Foreground" Value="{DynamicResource CalendarViewWeekDayForegroundDisabled}" /> |
||||
</Style> |
</Style> |
||||
</Styles> |
</ControlTheme> |
||||
|
</ResourceDictionary> |
||||
|
|||||
@ -1,72 +1,97 @@ |
|||||
<Styles xmlns="https://github.com/avaloniaui" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
<Style Selector="CaptionButtons"> |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
||||
|
<Design.PreviewWith> |
||||
|
<Border Padding="20"> |
||||
|
<StackPanel Spacing="20"> |
||||
|
<CaptionButtons Height="30"/> |
||||
|
</StackPanel> |
||||
|
</Border> |
||||
|
</Design.PreviewWith> |
||||
|
|
||||
|
<ControlTheme x:Key="FluentCaptionButton" TargetType="Button"> |
||||
|
<Setter Property="Background" Value="#ffe5e5e5" /> |
||||
|
<!-- Reusing BorderBrush to define pressed background color, as it's not used otherwise --> |
||||
|
<Setter Property="BorderBrush" Value="#ffcacaca" /> |
||||
|
<Setter Property="Foreground" Value="Black"/> |
||||
|
<Setter Property="Width" Value="45"/> |
||||
|
<Setter Property="VerticalAlignment" Value="Stretch"/> |
||||
|
<Setter Property="Template"> |
||||
|
<ControlTemplate> |
||||
|
<ContentPresenter Name="PART_ContentPresenter" |
||||
|
Background="Transparent" |
||||
|
Content="{TemplateBinding Content}"/> |
||||
|
</ControlTemplate> |
||||
|
</Setter> |
||||
|
|
||||
|
<Style Selector="^:pointerover /template/ ContentPresenter"> |
||||
|
<Setter Property="Background" Value="{TemplateBinding Background}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^:pressed /template/ ContentPresenter"> |
||||
|
<Setter Property="Background" Value="{TemplateBinding BorderBrush}" /> |
||||
|
</Style> |
||||
|
</ControlTheme> |
||||
|
|
||||
|
<ControlTheme x:Key="{x:Type CaptionButtons}" TargetType="CaptionButtons"> |
||||
<Setter Property="MaxHeight" Value="30" /> |
<Setter Property="MaxHeight" Value="30" /> |
||||
<Setter Property="Template"> |
<Setter Property="Template"> |
||||
<ControlTemplate> |
<ControlTemplate> |
||||
<StackPanel Spacing="2" VerticalAlignment="Stretch" TextElement.FontSize="10" Orientation="Horizontal"> |
<StackPanel Spacing="2" VerticalAlignment="Stretch" TextElement.FontSize="10" Orientation="Horizontal"> |
||||
<StackPanel.Styles> |
<Button x:Name="PART_FullScreenButton" |
||||
<Style Selector="Panel"> |
Theme="{StaticResource FluentCaptionButton}" |
||||
<Setter Property="Width" Value="45" /> |
IsVisible="False"> |
||||
<Setter Property="Background" Value="Transparent" /> |
<Viewbox Width="11" Margin="2"> |
||||
</Style> |
<Path Name="FullScreenButtonPath" |
||||
<Style Selector="Panel:pointerover"> |
Stretch="UniformToFill" |
||||
<Setter Property="Background" Value="#7F7f7f7f" /> |
Fill="{TemplateBinding Foreground}" |
||||
</Style> |
Data="M2048 2048v-819h-205v469l-1493 -1493h469v-205h-819v819h205v-469l1493 1493h-469v205h819z" /> |
||||
<Style Selector="Panel#PART_CloseButton:pointerover"> |
|
||||
<Setter Property="Background" Value="#7FFF0000" /> |
|
||||
</Style> |
|
||||
<Style Selector="Viewbox"> |
|
||||
<Setter Property="Width" Value="11" /> |
|
||||
<Setter Property="Margin" Value="2" /> |
|
||||
</Style> |
|
||||
</StackPanel.Styles> |
|
||||
<Panel x:Name="PART_FullScreenButton"> |
|
||||
<Viewbox> |
|
||||
<Path Stretch="UniformToFill" Fill="{TemplateBinding Foreground}" /> |
|
||||
</Viewbox> |
</Viewbox> |
||||
</Panel> |
</Button> |
||||
|
<Button x:Name="PART_MinimiseButton" |
||||
<Panel x:Name="PART_MinimiseButton"> |
Theme="{StaticResource FluentCaptionButton}"> |
||||
<Viewbox> |
<Viewbox Width="11" Margin="2"> |
||||
<Path Stretch="UniformToFill" Fill="{TemplateBinding Foreground}" Data="M2048 1229v-205h-2048v205h2048z" /> |
<Path Stretch="UniformToFill" |
||||
|
Fill="{TemplateBinding Foreground}" |
||||
|
Data="M2048 1229v-205h-2048v205h2048z" /> |
||||
</Viewbox> |
</Viewbox> |
||||
</Panel> |
</Button> |
||||
|
<Button x:Name="PART_RestoreButton" |
||||
<Panel x:Name="PART_RestoreButton"> |
Theme="{StaticResource FluentCaptionButton}"> |
||||
<Viewbox> |
<Viewbox Width="11" Margin="2"> |
||||
<Viewbox.RenderTransform> |
<Viewbox.RenderTransform> |
||||
<RotateTransform Angle="-90" /> |
<RotateTransform Angle="-90" /> |
||||
</Viewbox.RenderTransform> |
</Viewbox.RenderTransform> |
||||
<Path Stretch="UniformToFill" Fill="{TemplateBinding Foreground}"/> |
<Path Name="RestoreButtonPath" |
||||
|
Stretch="UniformToFill" |
||||
|
Fill="{TemplateBinding Foreground}" |
||||
|
Data="M2048 2048v-2048h-2048v2048h2048zM1843 1843h-1638v-1638h1638v1638z"/> |
||||
</Viewbox> |
</Viewbox> |
||||
</Panel> |
</Button> |
||||
|
<Button x:Name="PART_CloseButton" |
||||
<Panel x:Name="PART_CloseButton"> |
Background="#ffe81123" |
||||
<Viewbox> |
BorderBrush="#fff1707a" |
||||
<Path Stretch="UniformToFill" Fill="{TemplateBinding Foreground}" Data="M1169 1024l879 -879l-145 -145l-879 879l-879 -879l-145 145l879 879l-879 879l145 145l879 -879l879 879l145 -145z" /> |
Theme="{StaticResource FluentCaptionButton}"> |
||||
|
<Viewbox Width="11" Margin="2"> |
||||
|
<Path Stretch="UniformToFill" |
||||
|
Fill="{TemplateBinding Foreground}" |
||||
|
Data="M1169 1024l879 -879l-145 -145l-879 879l-879 -879l-145 145l879 879l-879 879l145 145l879 -879l879 879l145 -145z" /> |
||||
</Viewbox> |
</Viewbox> |
||||
</Panel> |
</Button> |
||||
</StackPanel> |
</StackPanel> |
||||
</ControlTemplate> |
</ControlTemplate> |
||||
</Setter> |
</Setter> |
||||
</Style> |
<Style Selector="^:maximized /template/ Path#RestoreButtonPath"> |
||||
<Style Selector="CaptionButtons Panel#PART_RestoreButton Path"> |
<Setter Property="Data" Value="M2048 410h-410v-410h-1638v1638h410v410h1638v-1638zM1434 1434h-1229v-1229h1229v1229zM1843 1843h-1229v-205h1024v-1024h205v1229z" /> |
||||
<Setter Property="Data" Value="M2048 2048v-2048h-2048v2048h2048zM1843 1843h-1638v-1638h1638v1638z" /> |
</Style> |
||||
</Style> |
<Style Selector="^:fullscreen /template/ Path#PART_FullScreenButtonPath"> |
||||
<Style Selector="CaptionButtons:maximized Panel#PART_RestoreButton Path"> |
<Setter Property="IsVisible" Value="True" /> |
||||
<Setter Property="Data" Value="M2048 410h-410v-410h-1638v1638h410v410h1638v-1638zM1434 1434h-1229v-1229h1229v1229zM1843 1843h-1229v-205h1024v-1024h205v1229z" /> |
<Setter Property="Data" Value="M205 1024h819v-819h-205v469l-674 -674l-145 145l674 674h-469v205zM1374 1229h469v-205h-819v819h205v-469l674 674l145 -145z" /> |
||||
</Style> |
</Style> |
||||
<Style Selector="CaptionButtons Panel#PART_FullScreenButton"> |
<Style Selector="^:fullscreen /template/ Panel#PART_RestoreButton"> |
||||
<Setter Property="IsVisible" Value="False" /> |
<Setter Property="IsVisible" Value="False" /> |
||||
</Style> |
</Style> |
||||
<Style Selector="CaptionButtons Panel#PART_FullScreenButton Path"> |
<Style Selector="^:fullscreen /template/ Panel#PART_MinimiseButton"> |
||||
<Setter Property="Data" Value="M2048 2048v-819h-205v469l-1493 -1493h469v-205h-819v819h205v-469l1493 1493h-469v205h819z" /> |
<Setter Property="IsVisible" Value="False" /> |
||||
</Style> |
</Style> |
||||
<Style Selector="CaptionButtons:fullscreen Panel#PART_FullScreenButton Path"> |
</ControlTheme> |
||||
<Setter Property="IsVisible" Value="True" /> |
</ResourceDictionary> |
||||
<Setter Property="Data" Value="M205 1024h819v-819h-205v469l-674 -674l-145 145l674 674h-469v205zM1374 1229h469v-205h-819v819h205v-469l674 674l145 -145z" /> |
|
||||
</Style> |
|
||||
<Style Selector="CaptionButtons:fullscreen Panel#PART_RestoreButton, CaptionButtons:fullscreen Panel#PART_MinimiseButton"> |
|
||||
<Setter Property="IsVisible" Value="False" /> |
|
||||
</Style> |
|
||||
</Styles> |
|
||||
|
|||||
@ -1,17 +1,20 @@ |
|||||
<Style xmlns="https://github.com/avaloniaui" Selector="Carousel"> |
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
<Setter Property="Template"> |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
||||
<ControlTemplate> |
<ControlTheme x:Key="{x:Type Carousel}" TargetType="Carousel"> |
||||
<Border Background="{TemplateBinding Background}" |
<Setter Property="Template"> |
||||
BorderBrush="{TemplateBinding BorderBrush}" |
<ControlTemplate> |
||||
BorderThickness="{TemplateBinding BorderThickness}" |
<Border Background="{TemplateBinding Background}" |
||||
CornerRadius="{TemplateBinding CornerRadius}"> |
BorderBrush="{TemplateBinding BorderBrush}" |
||||
<CarouselPresenter IsVirtualized="{TemplateBinding IsVirtualized}" |
BorderThickness="{TemplateBinding BorderThickness}" |
||||
Items="{TemplateBinding Items}" |
CornerRadius="{TemplateBinding CornerRadius}"> |
||||
ItemsPanel="{TemplateBinding ItemsPanel}" |
<CarouselPresenter IsVirtualized="{TemplateBinding IsVirtualized}" |
||||
Margin="{TemplateBinding Padding}" |
Items="{TemplateBinding Items}" |
||||
SelectedIndex="{TemplateBinding SelectedIndex}" |
ItemsPanel="{TemplateBinding ItemsPanel}" |
||||
PageTransition="{TemplateBinding PageTransition}"/> |
Margin="{TemplateBinding Padding}" |
||||
</Border> |
SelectedIndex="{TemplateBinding SelectedIndex}" |
||||
</ControlTemplate> |
PageTransition="{TemplateBinding PageTransition}"/> |
||||
</Setter> |
</Border> |
||||
</Style> |
</ControlTemplate> |
||||
|
</Setter> |
||||
|
</ControlTheme> |
||||
|
</ResourceDictionary> |
||||
|
|||||
@ -1,297 +1,298 @@ |
|||||
<Style xmlns="https://github.com/avaloniaui" |
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
||||
Selector="CheckBox"> |
|
||||
<Design.PreviewWith> |
<Design.PreviewWith> |
||||
<Border Padding="20"> |
<Border Padding="20"> |
||||
<CheckBox IsThreeState="True" IsChecked="True" Content="Content" Foreground="Gold" /> |
<StackPanel Spacing="20"> |
||||
|
<CheckBox>Unchecked</CheckBox> |
||||
|
<CheckBox IsChecked="True">Checked</CheckBox> |
||||
|
<CheckBox IsThreeState="True" IsChecked="{x:Null}">Indeterminate</CheckBox> |
||||
|
<CheckBox Width="120">Checkbox should wrap its text</CheckBox> |
||||
|
</StackPanel> |
||||
</Border> |
</Border> |
||||
</Design.PreviewWith> |
</Design.PreviewWith> |
||||
|
|
||||
<Setter Property="Padding" Value="8,0,0,0" /> |
|
||||
<Setter Property="HorizontalAlignment" Value="Left" /> |
|
||||
<Setter Property="VerticalAlignment" Value="Center" /> |
|
||||
<Setter Property="HorizontalContentAlignment" Value="Left" /> |
|
||||
<Setter Property="VerticalContentAlignment" Value="Center" /> |
|
||||
<Setter Property="FontSize" Value="{DynamicResource ControlContentThemeFontSize}" /> |
|
||||
<Setter Property="CornerRadius" Value="{DynamicResource ControlCornerRadius}" /> |
|
||||
<Setter Property="MinHeight" Value="32" /> |
|
||||
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundUnchecked}" /> |
|
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundUnchecked}" /> |
|
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushUnchecked}" /> |
|
||||
<Setter Property="Template"> |
|
||||
<ControlTemplate> |
|
||||
<Grid x:Name="RootGrid" ColumnDefinitions="20,*"> |
|
||||
<Border x:Name="PART_Border" |
|
||||
Grid.ColumnSpan="2" |
|
||||
Background="{TemplateBinding Background}" |
|
||||
BorderBrush="{TemplateBinding BorderBrush}" |
|
||||
BorderThickness="{TemplateBinding BorderThickness}" |
|
||||
CornerRadius="{TemplateBinding CornerRadius}" /> |
|
||||
|
|
||||
<Grid VerticalAlignment="Top" Height="32"> |
|
||||
<Border x:Name="NormalRectangle" |
|
||||
BorderThickness="{DynamicResource CheckBoxBorderThemeThickness}" |
|
||||
CornerRadius="{TemplateBinding CornerRadius}" |
|
||||
UseLayoutRounding="False" |
|
||||
Height="20" |
|
||||
Width="20" /> |
|
||||
|
|
||||
<Viewbox UseLayoutRounding="False"> |
|
||||
<Panel> |
|
||||
<Panel Height="16" Width="16" /> |
|
||||
<Path x:Name="CheckGlyph" Stretch="Uniform" VerticalAlignment="Center" /> |
|
||||
</Panel> |
|
||||
</Viewbox> |
|
||||
</Grid> |
|
||||
<ContentPresenter x:Name="ContentPresenter" |
|
||||
ContentTemplate="{TemplateBinding ContentTemplate}" |
|
||||
Content="{TemplateBinding Content}" |
|
||||
Margin="{TemplateBinding Padding}" |
|
||||
RecognizesAccessKey="True" |
|
||||
HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" |
|
||||
VerticalAlignment="{TemplateBinding VerticalContentAlignment}" |
|
||||
Grid.Column="1" /> |
|
||||
<!-- TODO: TextWrapping="Wrap" on contentpresenter --> |
|
||||
</Grid> |
|
||||
</ControlTemplate> |
|
||||
</Setter> |
|
||||
|
|
||||
<!-- Unchecked Normal State --> |
|
||||
<Style Selector="^ /template/ Border#NormalRectangle"> |
|
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeUnchecked}" /> |
|
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillUnchecked}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="^ /template/ Path#CheckGlyph"> |
|
||||
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundUnchecked}" /> |
|
||||
<Setter Property="Opacity" Value="0" /> |
|
||||
</Style> |
|
||||
|
|
||||
<!-- Unchecked PointerOver State --> |
|
||||
<Style Selector="^:pointerover"> |
|
||||
<Style Selector="^ /template/ ContentPresenter#ContentPresenter"> |
|
||||
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundUncheckedPointerOver}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="^ /template/ Border#PART_Border"> |
|
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundUncheckedPointerOver}" /> |
|
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushUncheckedPointerOver}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="^ /template/ Border#NormalRectangle"> |
|
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeUncheckedPointerOver}" /> |
|
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillUncheckedPointerOver}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="^ /template/ Path#CheckGlyph"> |
|
||||
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundUncheckedPointerOver}" /> |
|
||||
</Style> |
|
||||
</Style> |
|
||||
|
|
||||
<!-- Unchecked Pressed State --> |
|
||||
<Style Selector="^:pressed"> |
|
||||
<Style Selector="^ /template/ ContentPresenter#ContentPresenter"> |
|
||||
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundUncheckedPressed}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="^ /template/ Border#PART_Border"> |
|
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundUncheckedPressed}" /> |
|
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushUncheckedPressed}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="^ /template/ Border#NormalRectangle"> |
|
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeUncheckedPressed}" /> |
|
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillUncheckedPressed}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="^ /template/ Path#CheckGlyph"> |
|
||||
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundUncheckedPressed}" /> |
|
||||
</Style> |
|
||||
</Style> |
|
||||
|
|
||||
<!-- Unchecked Disabled state --> |
|
||||
<Style Selector="^:disabled"> |
|
||||
<Style Selector="^ /template/ ContentPresenter#ContentPresenter"> |
|
||||
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundUncheckedDisabled}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="^ /template/ Border#PART_Border"> |
|
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundUncheckedDisabled}" /> |
|
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushUncheckedDisabled}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="^ /template/ Border#NormalRectangle"> |
|
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeUncheckedDisabled}" /> |
|
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillUncheckedDisabled}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="^ /template/ Path#CheckGlyph"> |
|
||||
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundUncheckedDisabled}" /> |
|
||||
</Style> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="^:checked"> |
|
||||
<!-- Checked Normal State --> |
|
||||
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundChecked}" /> |
|
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundChecked}" /> |
|
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushChecked}" /> |
|
||||
|
|
||||
<Style Selector="^ /template/ Border#NormalRectangle"> |
|
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundFillChecked}" /> |
|
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillChecked}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="^ /template/ Path#CheckGlyph"> |
<ControlTheme x:Key="{x:Type CheckBox}" TargetType="CheckBox"> |
||||
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundChecked}" /> |
<Setter Property="Padding" Value="8,0,0,0" /> |
||||
<Setter Property="Data" Value="M1507 31L438 1101L-119 543L-29 453L438 919L1417 -59L1507 31Z" /> |
<Setter Property="HorizontalAlignment" Value="Left" /> |
||||
<Setter Property="Width" Value="9" /> |
<Setter Property="VerticalAlignment" Value="Center" /> |
||||
<Setter Property="Opacity" Value="1" /> |
<Setter Property="HorizontalContentAlignment" Value="Left" /> |
||||
<Setter Property="FlowDirection" Value="LeftToRight" /> |
<Setter Property="VerticalContentAlignment" Value="Center" /> |
||||
</Style> |
<Setter Property="FontSize" Value="{DynamicResource ControlContentThemeFontSize}" /> |
||||
|
<Setter Property="CornerRadius" Value="{DynamicResource ControlCornerRadius}" /> |
||||
|
<Setter Property="MinHeight" Value="32" /> |
||||
|
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundUnchecked}" /> |
||||
|
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundUnchecked}" /> |
||||
|
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushUnchecked}" /> |
||||
|
<Setter Property="Template"> |
||||
|
<ControlTemplate> |
||||
|
<Grid x:Name="RootGrid" ColumnDefinitions="20,*"> |
||||
|
<Border x:Name="PART_Border" |
||||
|
Grid.ColumnSpan="2" |
||||
|
Background="{TemplateBinding Background}" |
||||
|
BorderBrush="{TemplateBinding BorderBrush}" |
||||
|
BorderThickness="{TemplateBinding BorderThickness}" |
||||
|
CornerRadius="{TemplateBinding CornerRadius}" /> |
||||
|
|
||||
|
<Grid VerticalAlignment="Top" Height="32"> |
||||
|
<Border x:Name="NormalRectangle" |
||||
|
BorderBrush="{DynamicResource CheckBoxCheckBackgroundStrokeUnchecked}" |
||||
|
Background="{DynamicResource CheckBoxCheckBackgroundFillUnchecked}" |
||||
|
BorderThickness="{DynamicResource CheckBoxBorderThemeThickness}" |
||||
|
CornerRadius="{TemplateBinding CornerRadius}" |
||||
|
UseLayoutRounding="False" |
||||
|
Height="20" |
||||
|
Width="20" /> |
||||
|
|
||||
|
<Viewbox UseLayoutRounding="False"> |
||||
|
<Panel> |
||||
|
<Panel Height="16" Width="16" /> |
||||
|
<Path x:Name="CheckGlyph" |
||||
|
Opacity="0" |
||||
|
Fill="{DynamicResource CheckBoxCheckGlyphForegroundUnchecked}" |
||||
|
Stretch="Uniform" |
||||
|
VerticalAlignment="Center" /> |
||||
|
</Panel> |
||||
|
</Viewbox> |
||||
|
</Grid> |
||||
|
<ContentPresenter x:Name="ContentPresenter" |
||||
|
ContentTemplate="{TemplateBinding ContentTemplate}" |
||||
|
Content="{TemplateBinding Content}" |
||||
|
Margin="{TemplateBinding Padding}" |
||||
|
RecognizesAccessKey="True" |
||||
|
HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" |
||||
|
VerticalAlignment="{TemplateBinding VerticalContentAlignment}" |
||||
|
TextWrapping="Wrap" |
||||
|
Grid.Column="1" /> |
||||
|
</Grid> |
||||
|
</ControlTemplate> |
||||
|
</Setter> |
||||
|
|
||||
<!-- Checked PointerOver State --> |
<!-- Unchecked PointerOver State --> |
||||
<Style Selector="^:pointerover"> |
<Style Selector="^:pointerover"> |
||||
<Style Selector="^ /template/ ContentPresenter#ContentPresenter"> |
<Style Selector="^ /template/ ContentPresenter#ContentPresenter"> |
||||
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundCheckedPointerOver}" /> |
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundUncheckedPointerOver}" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="^ /template/ Border#PART_Border"> |
<Style Selector="^ /template/ Border#PART_Border"> |
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundCheckedPointerOver}" /> |
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundUncheckedPointerOver}" /> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushCheckedPointerOver}" /> |
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushUncheckedPointerOver}" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="^ /template/ Border#NormalRectangle"> |
<Style Selector="^ /template/ Border#NormalRectangle"> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeCheckedPointerOver}" /> |
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeUncheckedPointerOver}" /> |
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillCheckedPointerOver}" /> |
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillUncheckedPointerOver}" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="^ /template/ Path#CheckGlyph"> |
<Style Selector="^ /template/ Path#CheckGlyph"> |
||||
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundCheckedPointerOver}" /> |
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundUncheckedPointerOver}" /> |
||||
</Style> |
</Style> |
||||
</Style> |
</Style> |
||||
|
|
||||
<!-- Checked Pressed State --> |
<!-- Unchecked Pressed State --> |
||||
<Style Selector="^:pressed"> |
<Style Selector="^:pressed"> |
||||
<Style Selector="^ /template/ ContentPresenter#ContentPresenter"> |
<Style Selector="^ /template/ ContentPresenter#ContentPresenter"> |
||||
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundCheckedPressed}" /> |
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundUncheckedPressed}" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="^ /template/ Border#PART_Border"> |
<Style Selector="^ /template/ Border#PART_Border"> |
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundCheckedPressed}" /> |
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundUncheckedPressed}" /> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushCheckedPressed}" /> |
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushUncheckedPressed}" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="^ /template/ Border#NormalRectangle"> |
<Style Selector="^ /template/ Border#NormalRectangle"> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeCheckedPressed}" /> |
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeUncheckedPressed}" /> |
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillCheckedPressed}" /> |
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillUncheckedPressed}" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="^ /template/ Path#CheckGlyph"> |
<Style Selector="^ /template/ Path#CheckGlyph"> |
||||
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundCheckedPressed}" /> |
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundUncheckedPressed}" /> |
||||
</Style> |
</Style> |
||||
</Style> |
</Style> |
||||
|
|
||||
<!-- Checked Disabled State --> |
<!-- Unchecked Disabled state --> |
||||
<Style Selector="^:disabled"> |
<Style Selector="^:disabled"> |
||||
<Style Selector="^ /template/ ContentPresenter#ContentPresenter"> |
<Style Selector="^ /template/ ContentPresenter#ContentPresenter"> |
||||
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundCheckedDisabled}" /> |
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundUncheckedDisabled}" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="^ /template/ Border#PART_Border"> |
<Style Selector="^ /template/ Border#PART_Border"> |
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundCheckedDisabled}" /> |
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundUncheckedDisabled}" /> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushCheckedDisabled}" /> |
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushUncheckedDisabled}" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="^ /template/ Border#NormalRectangle"> |
<Style Selector="^ /template/ Border#NormalRectangle"> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeCheckedDisabled}" /> |
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeUncheckedDisabled}" /> |
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillCheckedDisabled}" /> |
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillUncheckedDisabled}" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="^ /template/ Path#CheckGlyph"> |
<Style Selector="^ /template/ Path#CheckGlyph"> |
||||
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundCheckedDisabled}" /> |
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundUncheckedDisabled}" /> |
||||
</Style> |
</Style> |
||||
</Style> |
</Style> |
||||
</Style> |
|
||||
|
|
||||
<Style Selector="^:indeterminate"> |
<Style Selector="^:checked"> |
||||
<!-- Indeterminate Normal State --> |
<!-- Checked Normal State --> |
||||
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundIndeterminate}" /> |
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundChecked}" /> |
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundIndeterminate}" /> |
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundChecked}" /> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushIndeterminate}" /> |
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushChecked}" /> |
||||
|
|
||||
<Style Selector="^ /template/ Border#NormalRectangle"> |
|
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeIndeterminate}" /> |
|
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillIndeterminate}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="^ /template/ Path#CheckGlyph"> |
<Style Selector="^ /template/ Border#NormalRectangle"> |
||||
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundIndeterminate}" /> |
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundFillChecked}" /> |
||||
<Setter Property="Data" Value="M1536 1536v-1024h-1024v1024h1024z" /> |
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillChecked}" /> |
||||
<Setter Property="Width" Value="7" /> |
|
||||
<Setter Property="Opacity" Value="1" /> |
|
||||
</Style> |
|
||||
|
|
||||
<!-- Indeterminate PointerOver State --> |
|
||||
<Style Selector="^:pointerover"> |
|
||||
<Style Selector="^ /template/ ContentPresenter#ContentPresenter"> |
|
||||
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundIndeterminatePointerOver}" /> |
|
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="^ /template/ Border#PART_Border"> |
<Style Selector="^ /template/ Path#CheckGlyph"> |
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundIndeterminatePointerOver}" /> |
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundChecked}" /> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushIndeterminatePointerOver}" /> |
<Setter Property="Data" Value="M1507 31L438 1101L-119 543L-29 453L438 919L1417 -59L1507 31Z" /> |
||||
|
<Setter Property="Width" Value="9" /> |
||||
|
<Setter Property="Opacity" Value="1" /> |
||||
|
<Setter Property="FlowDirection" Value="LeftToRight" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="^ /template/ Border#NormalRectangle"> |
<!-- Checked PointerOver State --> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeIndeterminatePointerOver}" /> |
<Style Selector="^:pointerover"> |
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillIndeterminatePointerOver}" /> |
<Style Selector="^ /template/ ContentPresenter#ContentPresenter"> |
||||
|
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundCheckedPointerOver}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ Border#PART_Border"> |
||||
|
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundCheckedPointerOver}" /> |
||||
|
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushCheckedPointerOver}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ Border#NormalRectangle"> |
||||
|
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeCheckedPointerOver}" /> |
||||
|
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillCheckedPointerOver}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ Path#CheckGlyph"> |
||||
|
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundCheckedPointerOver}" /> |
||||
|
</Style> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="^ /template/ Path#CheckGlyph"> |
<!-- Checked Pressed State --> |
||||
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundIndeterminatePointerOver}" /> |
<Style Selector="^:pressed"> |
||||
|
<Style Selector="^ /template/ ContentPresenter#ContentPresenter"> |
||||
|
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundCheckedPressed}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ Border#PART_Border"> |
||||
|
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundCheckedPressed}" /> |
||||
|
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushCheckedPressed}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ Border#NormalRectangle"> |
||||
|
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeCheckedPressed}" /> |
||||
|
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillCheckedPressed}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ Path#CheckGlyph"> |
||||
|
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundCheckedPressed}" /> |
||||
|
</Style> |
||||
</Style> |
</Style> |
||||
</Style> |
|
||||
|
|
||||
<!-- Indeterminate Pressed State --> |
<!-- Checked Disabled State --> |
||||
<Style Selector="^:pressed"> |
<Style Selector="^:disabled"> |
||||
<Style Selector="^ /template/ ContentPresenter#ContentPresenter"> |
<Style Selector="^ ContentPresenter#ContentPresenter"> |
||||
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundIndeterminatePressed}" /> |
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundCheckedDisabled}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ Border#PART_Border"> |
||||
|
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundCheckedDisabled}" /> |
||||
|
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushCheckedDisabled}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ Border#NormalRectangle"> |
||||
|
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeCheckedDisabled}" /> |
||||
|
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillCheckedDisabled}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ Path#CheckGlyph"> |
||||
|
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundCheckedDisabled}" /> |
||||
|
</Style> |
||||
</Style> |
</Style> |
||||
|
</Style> |
||||
|
|
||||
<Style Selector="^ /template/ Border#PART_Border"> |
<Style Selector="^:indeterminate"> |
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundIndeterminatePressed}" /> |
<!-- Indeterminate Normal State --> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushIndeterminatePressed}" /> |
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundIndeterminate}" /> |
||||
</Style> |
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundIndeterminate}" /> |
||||
|
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushIndeterminate}" /> |
||||
|
|
||||
<Style Selector="^ /template/ Border#NormalRectangle"> |
<Style Selector="^ /template/ Border#NormalRectangle"> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeIndeterminatePressed}" /> |
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeIndeterminate}" /> |
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillIndeterminatePressed}" /> |
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillIndeterminate}" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="^ /template/ Path#CheckGlyph"> |
<Style Selector="^ /template/ Path#CheckGlyph"> |
||||
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundIndeterminatePressed}" /> |
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundIndeterminate}" /> |
||||
|
<Setter Property="Data" Value="M1536 1536v-1024h-1024v1024h1024z" /> |
||||
|
<Setter Property="Width" Value="7" /> |
||||
|
<Setter Property="Opacity" Value="1" /> |
||||
</Style> |
</Style> |
||||
</Style> |
|
||||
|
|
||||
<!-- Indeterminate Disabled State --> |
<!-- Indeterminate PointerOver State --> |
||||
<Style Selector="^:disabled"> |
<Style Selector="^:pointerover"> |
||||
<Style Selector="^ /template/ ContentPresenter#ContentPresenter"> |
<Style Selector="^ /template/ ContentPresenter#ContentPresenter"> |
||||
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundIndeterminateDisabled}" /> |
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundIndeterminatePointerOver}" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="^ /template/ Border#PART_Border"> |
<Style Selector="^ /template/ Border#PART_Border"> |
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundIndeterminateDisabled}" /> |
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundIndeterminatePointerOver}" /> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushIndeterminateDisabled}" /> |
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushIndeterminatePointerOver}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ Border#NormalRectangle"> |
||||
|
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeIndeterminatePointerOver}" /> |
||||
|
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillIndeterminatePointerOver}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ Path#CheckGlyph"> |
||||
|
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundIndeterminatePointerOver}" /> |
||||
|
</Style> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="^ /template/ Border#NormalRectangle"> |
<!-- Indeterminate Pressed State --> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeIndeterminateDisabled}" /> |
<Style Selector="^:pressed"> |
||||
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillIndeterminateDisabled}" /> |
<Style Selector="^ /template/ ContentPresenter#ContentPresenter"> |
||||
|
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundIndeterminatePressed}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ Border#PART_Border"> |
||||
|
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundIndeterminatePressed}" /> |
||||
|
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushIndeterminatePressed}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ Border#NormalRectangle"> |
||||
|
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeIndeterminatePressed}" /> |
||||
|
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillIndeterminatePressed}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ Path#CheckGlyph"> |
||||
|
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundIndeterminatePressed}" /> |
||||
|
</Style> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="^ /template/ Path#CheckGlyph"> |
<!-- Indeterminate Disabled State --> |
||||
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundIndeterminateDisabled}" /> |
<Style Selector="^:disabled"> |
||||
|
<Style Selector="^ /template/ ContentPresenter#ContentPresenter"> |
||||
|
<Setter Property="Foreground" Value="{DynamicResource CheckBoxForegroundIndeterminateDisabled}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ Border#PART_Border"> |
||||
|
<Setter Property="Background" Value="{DynamicResource CheckBoxBackgroundIndeterminateDisabled}" /> |
||||
|
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxBorderBrushIndeterminateDisabled}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ Border#NormalRectangle"> |
||||
|
<Setter Property="BorderBrush" Value="{DynamicResource CheckBoxCheckBackgroundStrokeIndeterminateDisabled}" /> |
||||
|
<Setter Property="Background" Value="{DynamicResource CheckBoxCheckBackgroundFillIndeterminateDisabled}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ Path#CheckGlyph"> |
||||
|
<Setter Property="Fill" Value="{DynamicResource CheckBoxCheckGlyphForegroundIndeterminateDisabled}" /> |
||||
|
</Style> |
||||
</Style> |
</Style> |
||||
</Style> |
</Style> |
||||
</Style> |
</ControlTheme> |
||||
</Style> |
</ResourceDictionary> |
||||
|
|||||
@ -1,6 +0,0 @@ |
|||||
<Styles xmlns="https://github.com/avaloniaui" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
|
||||
<Style Selector="TextBlock.CaptionTextBlockStyle"> |
|
||||
<Setter Property="FontSize" Value="12" /> |
|
||||
<Setter Property="FontWeight" Value="Normal" /> |
|
||||
</Style> |
|
||||
</Styles> |
|
||||
@ -1,16 +1,19 @@ |
|||||
<Style xmlns="https://github.com/avaloniaui" Selector="ContentControl"> |
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
<Setter Property="Template"> |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
||||
<ControlTemplate> |
<ControlTheme x:Key="{x:Type ContentControl}" TargetType="ContentControl"> |
||||
<ContentPresenter Name="PART_ContentPresenter" |
<Setter Property="Template"> |
||||
Background="{TemplateBinding Background}" |
<ControlTemplate> |
||||
BorderBrush="{TemplateBinding BorderBrush}" |
<ContentPresenter Name="PART_ContentPresenter" |
||||
BorderThickness="{TemplateBinding BorderThickness}" |
Background="{TemplateBinding Background}" |
||||
CornerRadius="{TemplateBinding CornerRadius}" |
BorderBrush="{TemplateBinding BorderBrush}" |
||||
ContentTemplate="{TemplateBinding ContentTemplate}" |
BorderThickness="{TemplateBinding BorderThickness}" |
||||
Content="{TemplateBinding Content}" |
CornerRadius="{TemplateBinding CornerRadius}" |
||||
Padding="{TemplateBinding Padding}" |
ContentTemplate="{TemplateBinding ContentTemplate}" |
||||
VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" |
Content="{TemplateBinding Content}" |
||||
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"/> |
Padding="{TemplateBinding Padding}" |
||||
</ControlTemplate> |
VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" |
||||
</Setter> |
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"/> |
||||
</Style> |
</ControlTemplate> |
||||
|
</Setter> |
||||
|
</ControlTheme> |
||||
|
</ResourceDictionary> |
||||
|
|||||
@ -0,0 +1,118 @@ |
|||||
|
<!-- |
||||
|
// (c) Copyright Microsoft Corporation. |
||||
|
// This source is subject to the Microsoft Public License (Ms-PL). |
||||
|
// Please see http://go.microsoft.com/fwlink/?LinkID=131993 for details. |
||||
|
// All other rights reserved. |
||||
|
--> |
||||
|
|
||||
|
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
||||
|
xmlns:sys="clr-namespace:System;assembly=netstandard" |
||||
|
x:CompileBindings="True"> |
||||
|
<Design.PreviewWith> |
||||
|
<Border Padding="20" Width="200"> |
||||
|
<StackPanel Spacing="20"> |
||||
|
<ListBoxItem Theme="{DynamicResource FluentDateTimePickerItem}">Standard Item</ListBoxItem> |
||||
|
<ListBoxItem Theme="{DynamicResource FluentDateTimePickerItem}" Classes="MonthItem">Month Item</ListBoxItem> |
||||
|
<RepeatButton Theme="{DynamicResource FluentDateTimePickerButton}">Button</RepeatButton> |
||||
|
<RepeatButton Theme="{DynamicResource FluentDateTimePickerUpButton}" IsVisible="True"/> |
||||
|
<RepeatButton Theme="{DynamicResource FluentDateTimePickerDownButton}" IsVisible="True"/> |
||||
|
</StackPanel> |
||||
|
</Border> |
||||
|
</Design.PreviewWith> |
||||
|
|
||||
|
<!-- Theme for the items displayed in the selectors --> |
||||
|
<ControlTheme x:Key="FluentDateTimePickerItem" TargetType="ListBoxItem" BasedOn="{StaticResource {x:Type ListBoxItem}}"> |
||||
|
<Setter Property="Padding" Value="{DynamicResource DatePickerFlyoutPresenterItemPadding}"/> |
||||
|
<Setter Property="VerticalContentAlignment" Value="Center" /> |
||||
|
<Setter Property="HorizontalContentAlignment" Value="Center" /> |
||||
|
|
||||
|
<Style Selector="^:selected"> |
||||
|
<Setter Property="IsHitTestVisible" Value="False"/> |
||||
|
<Style Selector="^/template/ Rectangle#PressedBackground"> |
||||
|
<Setter Property="Fill" Value="Transparent"/> |
||||
|
</Style> |
||||
|
<Style Selector="^/template/ ContentPresenter"> |
||||
|
<Setter Property="Background" Value="Transparent" /> |
||||
|
<Setter Property="Foreground" Value="{DynamicResource SystemControlForegroundBaseHighBrush}"/> |
||||
|
</Style> |
||||
|
</Style> |
||||
|
<Style Selector="^.MonthItem"> |
||||
|
<Setter Property="Padding" Value="{DynamicResource DatePickerFlyoutPresenterMonthPadding}"/> |
||||
|
<Setter Property="HorizontalContentAlignment" Value="Left" /> |
||||
|
</Style> |
||||
|
</ControlTheme> |
||||
|
|
||||
|
<!-- This is used for both the accept/dismiss & repeatbuttons in the presenter--> |
||||
|
<ControlTheme x:Key="FluentDateTimePickerButton" TargetType="Button"> |
||||
|
<Setter Property="Background" Value="{DynamicResource DateTimePickerFlyoutButtonBackground}" /> |
||||
|
<Setter Property="Height" Value="22" /> |
||||
|
<Setter Property="HorizontalContentAlignment" Value="Center"/> |
||||
|
<Setter Property="VerticalContentAlignment" Value="Center"/> |
||||
|
<Setter Property="Template"> |
||||
|
<ControlTemplate> |
||||
|
<!-- |
||||
|
The background is doubled here for the loopingselector up/down repeat buttons |
||||
|
that appear opaque. Not sure how MS does it though I suspect this is it |
||||
|
but source isn't MIT yet, so this is my solution --> |
||||
|
<Border Background="{TemplateBinding Background}"> |
||||
|
<ContentPresenter x:Name="ContentPresenter" |
||||
|
Background="{TemplateBinding Background}" |
||||
|
BorderBrush="{DynamicResource DateTimePickerFlyoutButtonBorderBrush}" |
||||
|
BorderThickness="{DynamicResource DateTimeFlyoutButtonBorderThickness}" |
||||
|
Content="{TemplateBinding Content}" |
||||
|
Foreground="{DynamicResource SystemControlHighlightAltBaseHighBrush}" |
||||
|
ContentTemplate="{TemplateBinding ContentTemplate}" |
||||
|
Padding="{TemplateBinding Padding}" |
||||
|
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" |
||||
|
VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" |
||||
|
CornerRadius="{TemplateBinding CornerRadius}"/> |
||||
|
</Border> |
||||
|
</ControlTemplate> |
||||
|
</Setter> |
||||
|
|
||||
|
<Style Selector="^:pointerover /template/ ContentPresenter"> |
||||
|
<Setter Property="Background" Value="{DynamicResource DateTimePickerFlyoutButtonBackgroundPointerOver}"/> |
||||
|
<Setter Property="BorderBrush" Value="{DynamicResource DateTimePickerFlyoutButtonBorderBrushPointerOver}"/> |
||||
|
<Setter Property="Foreground" Value="{DynamicResource DateTimePickerFlyoutButtonForegroundPointerOver}"/> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^:pressed /template/ ContentPresenter"> |
||||
|
<Setter Property="Background" Value="{DynamicResource DateTimePickerFlyoutButtonBackgroundPressed}"/> |
||||
|
<Setter Property="BorderBrush" Value="{DynamicResource DateTimePickerFlyoutButtonBorderBrushPressed}"/> |
||||
|
<Setter Property="Foreground" Value="{DynamicResource DateTimePickerFlyoutButtonForegroundPressed}"/> |
||||
|
</Style> |
||||
|
</ControlTheme> |
||||
|
|
||||
|
<ControlTheme x:Key="FluentDateTimePickerUpButton" TargetType="RepeatButton" BasedOn="{StaticResource FluentDateTimePickerButton}"> |
||||
|
<Setter Property="VerticalAlignment" Value="Top"/> |
||||
|
<Setter Property="Height" Value="22" /> |
||||
|
<Setter Property="HorizontalAlignment" Value="Stretch" /> |
||||
|
<Setter Property="Focusable" Value="False" /> |
||||
|
<Setter Property="Background" Value="{DynamicResource SystemControlBackgroundChromeMediumLowBrush}" /> |
||||
|
<Setter Property="IsVisible" Value="False"/> |
||||
|
<Setter Property="Content"> |
||||
|
<Template> |
||||
|
<Viewbox Height="10" Width="10" HorizontalAlignment="Center" VerticalAlignment="Center"> |
||||
|
<Path Stroke="{Binding $parent[RepeatButton].Foreground}" StrokeThickness="1" Data="M 0,9 L 9,0 L 18,9"/> |
||||
|
</Viewbox> |
||||
|
</Template> |
||||
|
</Setter> |
||||
|
</ControlTheme> |
||||
|
|
||||
|
<ControlTheme x:Key="FluentDateTimePickerDownButton" TargetType="RepeatButton" BasedOn="{StaticResource FluentDateTimePickerButton}"> |
||||
|
<Setter Property="VerticalAlignment" Value="Bottom"/> |
||||
|
<Setter Property="Height" Value="22" /> |
||||
|
<Setter Property="HorizontalAlignment" Value="Stretch" /> |
||||
|
<Setter Property="Focusable" Value="False" /> |
||||
|
<Setter Property="Background" Value="{DynamicResource SystemControlBackgroundChromeMediumLowBrush}" /> |
||||
|
<Setter Property="IsVisible" Value="False"/> |
||||
|
<Setter Property="Content"> |
||||
|
<Template> |
||||
|
<Viewbox Height="10" Width="10" HorizontalAlignment="Center" VerticalAlignment="Center"> |
||||
|
<Path Stroke="{Binding $parent[RepeatButton].Foreground}" StrokeThickness="1" Data="M 0,0 L 9,9 L 18,0"/> |
||||
|
</Viewbox> |
||||
|
</Template> |
||||
|
</Setter> |
||||
|
</ControlTheme> |
||||
|
</ResourceDictionary> |
||||
@ -1,103 +1,97 @@ |
|||||
<Styles xmlns="https://github.com/avaloniaui" |
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
||||
x:CompileBindings="True"> |
x:CompileBindings="True"> |
||||
|
<Design.PreviewWith> |
||||
<Design.PreviewWith> |
<Border Padding="20"> |
||||
<Border Padding="20"> |
<StackPanel Spacing="20"> |
||||
<StackPanel Spacing="20"> |
<DropDownButton Content="Click Me!" /> |
||||
<DropDownButton Content="Click Me!" /> |
<DropDownButton Content="Disabled" IsEnabled="False" /> |
||||
<DropDownButton Content="Disabled" IsEnabled="False" /> |
</StackPanel> |
||||
</StackPanel> |
</Border> |
||||
</Border> |
</Design.PreviewWith> |
||||
</Design.PreviewWith> |
|
||||
|
|
||||
<Styles.Resources> |
|
||||
<x:Double x:Key="DropDownButtonMinHeight">32</x:Double> |
|
||||
</Styles.Resources> |
|
||||
|
|
||||
<Style Selector="DropDownButton"> |
<x:Double x:Key="DropDownButtonMinHeight">32</x:Double> |
||||
<Setter Property="Background" Value="{DynamicResource ButtonBackground}" /> |
|
||||
<Setter Property="Foreground" Value="{DynamicResource ButtonForeground}" /> |
<ControlTheme x:Key="{x:Type DropDownButton}" TargetType="DropDownButton"> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource ButtonBorderBrush}" /> |
<Setter Property="Background" Value="{DynamicResource ButtonBackground}" /> |
||||
<Setter Property="BorderThickness" Value="{DynamicResource ButtonBorderThemeThickness}" /> |
<Setter Property="Foreground" Value="{DynamicResource ButtonForeground}" /> |
||||
<Setter Property="Padding" Value="{DynamicResource ButtonPadding}" /> |
<Setter Property="BorderBrush" Value="{DynamicResource ButtonBorderBrush}" /> |
||||
<Setter Property="MinHeight" Value="{DynamicResource DropDownButtonMinHeight}" /> |
<Setter Property="BorderThickness" Value="{DynamicResource ButtonBorderThemeThickness}" /> |
||||
<Setter Property="HorizontalAlignment" Value="Left" /> |
<Setter Property="Padding" Value="{DynamicResource ButtonPadding}" /> |
||||
<Setter Property="VerticalAlignment" Value="Center" /> |
<Setter Property="MinHeight" Value="{DynamicResource DropDownButtonMinHeight}" /> |
||||
<Setter Property="HorizontalContentAlignment" Value="Stretch" /> |
<Setter Property="HorizontalAlignment" Value="Left" /> |
||||
<Setter Property="VerticalContentAlignment" Value="Center" /> |
<Setter Property="VerticalAlignment" Value="Center" /> |
||||
<!--<Setter Property="UseSystemFocusVisuals" Value="{StaticResource UseSystemFocusVisuals}" /> |
<Setter Property="HorizontalContentAlignment" Value="Stretch" /> |
||||
<Setter Property="FocusVisualMargin" Value="-3" />--> |
<Setter Property="VerticalContentAlignment" Value="Center" /> |
||||
<Setter Property="CornerRadius" Value="{DynamicResource ControlCornerRadius}" /> |
<Setter Property="CornerRadius" Value="{DynamicResource ControlCornerRadius}" /> |
||||
<Setter Property="Template"> |
<Setter Property="Template"> |
||||
<Setter.Value> |
<Setter.Value> |
||||
<ControlTemplate> |
<ControlTemplate> |
||||
<Border x:Name="RootBorder" |
<Border x:Name="RootBorder" |
||||
Background="{TemplateBinding Background}" |
Background="{TemplateBinding Background}" |
||||
BorderBrush="{TemplateBinding BorderBrush}" |
BorderBrush="{TemplateBinding BorderBrush}" |
||||
BorderThickness="{TemplateBinding BorderThickness}" |
BorderThickness="{TemplateBinding BorderThickness}" |
||||
CornerRadius="{TemplateBinding CornerRadius}" |
CornerRadius="{TemplateBinding CornerRadius}" |
||||
ClipToBounds="True"> |
ClipToBounds="True"> |
||||
<Grid x:Name="InnerGrid"> |
<Grid x:Name="InnerGrid"> |
||||
<Grid.ColumnDefinitions> |
<Grid.ColumnDefinitions> |
||||
<ColumnDefinition Width="*" /> |
<ColumnDefinition Width="*" /> |
||||
<ColumnDefinition Width="Auto" /> |
<ColumnDefinition Width="Auto" /> |
||||
</Grid.ColumnDefinitions> |
</Grid.ColumnDefinitions> |
||||
|
|
||||
<ContentPresenter x:Name="PART_ContentPresenter" |
<ContentPresenter x:Name="PART_ContentPresenter" |
||||
Grid.Column="0" |
Grid.Column="0" |
||||
Content="{TemplateBinding Content}" |
Content="{TemplateBinding Content}" |
||||
ContentTemplate="{TemplateBinding ContentTemplate}" |
ContentTemplate="{TemplateBinding ContentTemplate}" |
||||
Padding="{TemplateBinding Padding}" |
Padding="{TemplateBinding Padding}" |
||||
RecognizesAccessKey="True" |
RecognizesAccessKey="True" |
||||
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" |
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" |
||||
VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" /> |
VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" /> |
||||
|
|
||||
<PathIcon x:Name="DropDownGlyph" |
<PathIcon x:Name="DropDownGlyph" |
||||
Grid.Column="1" |
Grid.Column="1" |
||||
UseLayoutRounding="False" |
UseLayoutRounding="False" |
||||
IsHitTestVisible="False" |
IsHitTestVisible="False" |
||||
Height="12" |
Height="12" |
||||
Width="12" |
Width="12" |
||||
Margin="0,0,10,0" |
Margin="0,0,10,0" |
||||
HorizontalAlignment="Right" |
Data="M1939 486L2029 576L1024 1581L19 576L109 486L1024 1401L1939 486Z" |
||||
VerticalAlignment="Center" /> |
HorizontalAlignment="Right" |
||||
|
VerticalAlignment="Center" |
||||
</Grid> |
Foreground="{DynamicResource ComboBoxDropDownGlyphForeground}"/> |
||||
</Border> |
</Grid> |
||||
</ControlTemplate> |
</Border> |
||||
</Setter.Value> |
</ControlTemplate> |
||||
</Setter> |
</Setter.Value> |
||||
</Style> |
</Setter> |
||||
|
|
||||
<!-- Normal State --> |
<!-- PointerOver State --> |
||||
<Style Selector="DropDownButton /template/ PathIcon#DropDownGlyph"> |
<Style Selector="^:pointerover /template/ Border#RootBorder"> |
||||
<Setter Property="Foreground" Value="{DynamicResource ComboBoxDropDownGlyphForeground}" /> |
<Setter Property="Background" Value="{DynamicResource ButtonBackgroundPointerOver}" /> |
||||
<Setter Property="Data" Value="M1939 486L2029 576L1024 1581L19 576L109 486L1024 1401L1939 486Z" /> |
<Setter Property="BorderBrush" Value="{DynamicResource ButtonBorderBrushPointerOver}" /> |
||||
</Style> |
<Setter Property="TextElement.Foreground" Value="{DynamicResource ButtonForegroundPointerOver}" /> |
||||
|
</Style> |
||||
<!-- PointerOver State --> |
|
||||
<Style Selector="DropDownButton:pointerover /template/ Border#RootBorder"> |
|
||||
<Setter Property="Background" Value="{DynamicResource ButtonBackgroundPointerOver}" /> |
|
||||
<Setter Property="BorderBrush" Value="{DynamicResource ButtonBorderBrushPointerOver}" /> |
|
||||
<Setter Property="TextElement.Foreground" Value="{DynamicResource ButtonForegroundPointerOver}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<!-- Pressed State --> |
<!-- Pressed State --> |
||||
<Style Selector="DropDownButton:pressed /template/ Border#RootBorder"> |
<Style Selector="^:pressed"> |
||||
<Setter Property="Background" Value="{DynamicResource ButtonBackgroundPressed}" /> |
<Setter Property="RenderTransform" Value="scale(0.98)" /> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource ButtonBorderBrushPressed}" /> |
</Style> |
||||
<Setter Property="TextElement.Foreground" Value="{DynamicResource ButtonForegroundPressed}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<!-- Disabled State --> |
<Style Selector="^:pressed /template/ Border#RootBorder"> |
||||
<Style Selector="DropDownButton:disabled /template/ Border#RootBorder"> |
<Setter Property="Background" Value="{DynamicResource ButtonBackgroundPressed}" /> |
||||
<Setter Property="Background" Value="{DynamicResource ButtonBackgroundDisabled}" /> |
<Setter Property="BorderBrush" Value="{DynamicResource ButtonBorderBrushPressed}" /> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource ButtonBorderBrushDisabled}" /> |
<Setter Property="TextElement.Foreground" Value="{DynamicResource ButtonForegroundPressed}" /> |
||||
<Setter Property="TextElement.Foreground" Value="{DynamicResource ButtonForegroundDisabled}" /> |
</Style> |
||||
</Style> |
|
||||
<Style Selector="DropDownButton:disabled /template/ PathIcon#DropDownGlyph"> |
|
||||
<Setter Property="Foreground" Value="{DynamicResource ButtonForegroundDisabled}" /> |
|
||||
</Style> |
|
||||
|
|
||||
</Styles> |
<!-- Disabled State --> |
||||
|
<Style Selector="^:disabled /template/ Border#RootBorder"> |
||||
|
<Setter Property="Background" Value="{DynamicResource ButtonBackgroundDisabled}" /> |
||||
|
<Setter Property="BorderBrush" Value="{DynamicResource ButtonBorderBrushDisabled}" /> |
||||
|
<Setter Property="TextElement.Foreground" Value="{DynamicResource ButtonForegroundDisabled}" /> |
||||
|
</Style> |
||||
|
<Style Selector="^:disabled /template/ PathIcon#DropDownGlyph"> |
||||
|
<Setter Property="Foreground" Value="{DynamicResource ButtonForegroundDisabled}" /> |
||||
|
</Style> |
||||
|
</ControlTheme> |
||||
|
|
||||
|
</ResourceDictionary> |
||||
|
|||||
@ -1,19 +1,22 @@ |
|||||
<Style xmlns="https://github.com/avaloniaui" Selector="EmbeddableControlRoot"> |
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
<Setter Property="Background" Value="{DynamicResource SystemControlBackgroundAltHighBrush}"/> |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
||||
<Setter Property="FontSize" Value="{DynamicResource ControlContentThemeFontSize}"/> |
<ControlTheme x:Key="{x:Type EmbeddableControlRoot}" TargetType="EmbeddableControlRoot"> |
||||
<Setter Property="Template"> |
<Setter Property="Background" Value="{DynamicResource SystemControlBackgroundAltHighBrush}"/> |
||||
<ControlTemplate> |
<Setter Property="FontSize" Value="{DynamicResource ControlContentThemeFontSize}"/> |
||||
<Panel> |
<Setter Property="Template"> |
||||
<Border Name="PART_TransparencyFallback" IsHitTestVisible="False" /> |
<ControlTemplate> |
||||
<Border Background="{TemplateBinding Background}"> |
<Panel> |
||||
<VisualLayerManager> |
<Border Name="PART_TransparencyFallback" IsHitTestVisible="False" /> |
||||
<ContentPresenter Name="PART_ContentPresenter" |
<Border Background="{TemplateBinding Background}"> |
||||
ContentTemplate="{TemplateBinding ContentTemplate}" |
<VisualLayerManager> |
||||
Content="{TemplateBinding Content}" |
<ContentPresenter Name="PART_ContentPresenter" |
||||
Margin="{TemplateBinding Padding}"/> |
ContentTemplate="{TemplateBinding ContentTemplate}" |
||||
</VisualLayerManager> |
Content="{TemplateBinding Content}" |
||||
</Border> |
Margin="{TemplateBinding Padding}"/> |
||||
</Panel> |
</VisualLayerManager> |
||||
</ControlTemplate> |
</Border> |
||||
</Setter> |
</Panel> |
||||
</Style> |
</ControlTemplate> |
||||
|
</Setter> |
||||
|
</ControlTheme> |
||||
|
</ResourceDictionary> |
||||
|
|||||
@ -1,70 +1,78 @@ |
|||||
<Styles xmlns="https://github.com/avaloniaui" |
<Styles |
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
x:Class="Avalonia.Themes.Fluent.Controls.FluentControls" |
||||
x:Class="Avalonia.Themes.Fluent.Controls.FluentControls"> |
xmlns="https://github.com/avaloniaui" |
||||
<!-- Define ToolTip first so its styles can be overriden by other controls (e.g. TextBox) --> |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/ToolTip.xaml"/> |
<Styles.Resources> |
||||
<!-- PathIcon also needs to be defined early so it can be overriden by other styles (e.g. ComboBox) --> |
<ResourceDictionary> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/PathIcon.xaml" /> |
<ResourceDictionary.MergedDictionaries> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/DataValidationErrors.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/Button.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/FocusAdorner.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/RadioButton.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/Button.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/Expander.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/CaptionButtons.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/ProgressBar.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/Carousel.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/AutoCompleteBox.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/CheckBox.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/ButtonSpinner.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/ComboBox.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/Calendar.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/ComboBoxItem.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/CalendarButton.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/ContentControl.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/CalendarDatePicker.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/DropDownButton.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/CalendarDayButton.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/Label.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/CalendarItem.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/GridSplitter.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/CaptionButtons.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/ItemsControl.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/Carousel.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/ListBox.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/CheckBox.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/ListBoxItem.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/FlyoutPresenter.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/Menu.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/GridSplitter.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/ContextMenu.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/ItemsControl.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/MenuItem.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/Label.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/OverlayPopupHost.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/ListBox.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/PopupRoot.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/ListBoxItem.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/ProgressBar.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/MenuScrollViewer.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/RadioButton.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/Menu.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/RepeatButton.xaml" /> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/MenuItem.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/Separator.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/MenuFlyoutPresenter.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/Slider.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/NativeMenuBar.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/ScrollBar.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/NotificationCard.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/ScrollViewer.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/NumericUpDown.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/TabStrip.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/OverlayPopupHost.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/TabStripItem.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/PopupRoot.xaml" /> |
||||
<!-- TabControl needs to come after TabStrip as it redefines the inner TabStrip.ItemsPanel--> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/PathIcon.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/TabControl.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/RepeatButton.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/TabItem.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/ScrollBar.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/TextBox.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/ScrollViewer.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/ToggleButton.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/Separator.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/TransitioningContentControl.xaml" /> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/SplitButton.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/Expander.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/SplitView.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/TitleBar.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/TabControl.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/TreeView.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/TabItem.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/TreeViewItem.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/TabStrip.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/UserControl.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/TabStripItem.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/Window.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/TextBox.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/EmbeddableControlRoot.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/ToggleButton.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/CalendarButton.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/ToggleSwitch.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/CalendarDayButton.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/ToolTip.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/CalendarItem.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/TitleBar.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/Calendar.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/TransitioningContentControl.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/CalendarDatePicker.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/TreeView.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/ButtonSpinner.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/TreeViewItem.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/NumericUpDown.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/WindowNotificationManager.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/AutoCompleteBox.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/Window.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/WindowNotificationManager.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/ComboBox.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/NotificationCard.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/ComboBoxItem.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/NativeMenuBar.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/ContentControl.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/ToggleSwitch.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/ContextMenu.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/SplitButton.xaml" /> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/DataValidationErrors.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/SplitView.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/DateTimePickerShared.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/DatePicker.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/DatePicker.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/TimePicker.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/TimePicker.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/FlyoutPresenter.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/DropDownButton.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/MenuFlyoutPresenter.xaml"/> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/EmbeddableControlRoot.xaml" /> |
||||
<!-- ManagedFileChooser comes last because it uses (and overrides) styles for a multitude of other controls...the dialogs were originally UserControls, after all--> |
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/Slider.xaml" /> |
||||
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/ManagedFileChooser.xaml"/> |
<!-- ManagedFileChooser comes last because it uses (and overrides) styles for a multitude of other controls...the dialogs were originally UserControls, after all --> |
||||
|
<ResourceInclude Source="avares://Avalonia.Themes.Fluent/Controls/ManagedFileChooser.xaml" /> |
||||
|
</ResourceDictionary.MergedDictionaries> |
||||
|
</ResourceDictionary> |
||||
|
</Styles.Resources> |
||||
|
|
||||
|
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/FocusAdorner.xaml" /> |
||||
|
<StyleInclude Source="avares://Avalonia.Themes.Fluent/Controls/UserControl.xaml" /> |
||||
|
<Styles.Resources /> |
||||
</Styles> |
</Styles> |
||||
|
|||||
@ -1,24 +1,22 @@ |
|||||
<Styles xmlns="https://github.com/avaloniaui"> |
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
||||
<Style Selector="GridSplitter"> |
<ControlTheme x:Key="{x:Type GridSplitter}" TargetType="GridSplitter"> |
||||
<Setter Property="Focusable" Value="True" /> |
<Setter Property="Focusable" Value="True" /> |
||||
<Setter Property="MinWidth" Value="6" /> |
<Setter Property="MinWidth" Value="6" /> |
||||
<Setter Property="MinHeight" Value="6" /> |
<Setter Property="MinHeight" Value="6" /> |
||||
<Setter Property="Background" Value="{DynamicResource SystemAltMediumLowColor}" /> |
<Setter Property="Background" Value="{DynamicResource SystemAltMediumLowColor}" /> |
||||
<Setter Property="PreviewContent"> |
<Setter Property="PreviewContent"> |
||||
<Template> |
<Template> |
||||
<Rectangle Fill="{DynamicResource SystemAccentColor}" /> |
<Rectangle Fill="{DynamicResource SystemAccentColor}" /> |
||||
</Template> |
</Template> |
||||
</Setter> |
</Setter> |
||||
<Setter Property="Template"> |
<Setter Property="Template"> |
||||
<ControlTemplate> |
<ControlTemplate> |
||||
<Border |
<Border BorderBrush="{TemplateBinding BorderBrush}" |
||||
BorderBrush="{TemplateBinding BorderBrush}" |
BorderThickness="{TemplateBinding BorderThickness}" |
||||
BorderThickness="{TemplateBinding BorderThickness}" |
CornerRadius="{TemplateBinding CornerRadius}" |
||||
CornerRadius="{TemplateBinding CornerRadius}" |
Background="{TemplateBinding Background}" /> |
||||
Background="{TemplateBinding Background}"/> |
</ControlTemplate> |
||||
</ControlTemplate> |
</Setter> |
||||
</Setter> |
</ControlTheme> |
||||
</Style> |
</ResourceDictionary> |
||||
|
|
||||
</Styles> |
|
||||
|
|||||
@ -1,16 +1,19 @@ |
|||||
<Style xmlns="https://github.com/avaloniaui" Selector="ItemsControl"> |
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
<Setter Property="Template"> |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
||||
<ControlTemplate> |
<ControlTheme x:Key="{x:Type ItemsControl}" TargetType="ItemsControl"> |
||||
<Border Background="{TemplateBinding Background}" |
<Setter Property="Template"> |
||||
BorderBrush="{TemplateBinding BorderBrush}" |
<ControlTemplate> |
||||
BorderThickness="{TemplateBinding BorderThickness}" |
<Border Background="{TemplateBinding Background}" |
||||
CornerRadius="{TemplateBinding CornerRadius}" |
BorderBrush="{TemplateBinding BorderBrush}" |
||||
Padding="{TemplateBinding Padding}"> |
BorderThickness="{TemplateBinding BorderThickness}" |
||||
<ItemsPresenter Name="PART_ItemsPresenter" |
CornerRadius="{TemplateBinding CornerRadius}" |
||||
Items="{TemplateBinding Items}" |
Padding="{TemplateBinding Padding}"> |
||||
ItemsPanel="{TemplateBinding ItemsPanel}" |
<ItemsPresenter Name="PART_ItemsPresenter" |
||||
ItemTemplate="{TemplateBinding ItemTemplate}"/> |
Items="{TemplateBinding Items}" |
||||
</Border> |
ItemsPanel="{TemplateBinding ItemsPanel}" |
||||
</ControlTemplate> |
ItemTemplate="{TemplateBinding ItemTemplate}"/> |
||||
</Setter> |
</Border> |
||||
</Style> |
</ControlTemplate> |
||||
|
</Setter> |
||||
|
</ControlTheme> |
||||
|
</ResourceDictionary> |
||||
|
|||||
@ -1,18 +1,22 @@ |
|||||
<Style xmlns="https://github.com/avaloniaui" Selector="Label"> |
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
<Setter Property="Padding" Value="3"/> |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
||||
<Setter Property="Template"> |
|
||||
<ControlTemplate> |
<ControlTheme x:Key="{x:Type Label}" TargetType="Label"> |
||||
<ContentPresenter Name="PART_ContentPresenter" |
<Setter Property="Padding" Value="3"/> |
||||
Background="{TemplateBinding Background}" |
<Setter Property="Template"> |
||||
BorderBrush="{TemplateBinding BorderBrush}" |
<ControlTemplate> |
||||
BorderThickness="{TemplateBinding BorderThickness}" |
<ContentPresenter Name="PART_ContentPresenter" |
||||
CornerRadius="{TemplateBinding CornerRadius}" |
Background="{TemplateBinding Background}" |
||||
ContentTemplate="{TemplateBinding ContentTemplate}" |
BorderBrush="{TemplateBinding BorderBrush}" |
||||
Content="{TemplateBinding Content}" |
BorderThickness="{TemplateBinding BorderThickness}" |
||||
Padding="{TemplateBinding Padding}" |
CornerRadius="{TemplateBinding CornerRadius}" |
||||
RecognizesAccessKey="True" |
ContentTemplate="{TemplateBinding ContentTemplate}" |
||||
VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" |
Content="{TemplateBinding Content}" |
||||
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"/> |
Padding="{TemplateBinding Padding}" |
||||
</ControlTemplate> |
RecognizesAccessKey="True" |
||||
</Setter> |
VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" |
||||
</Style> |
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"/> |
||||
|
</ControlTemplate> |
||||
|
</Setter> |
||||
|
</ControlTheme> |
||||
|
</ResourceDictionary> |
||||
|
|||||
@ -1,324 +1,328 @@ |
|||||
<Styles xmlns="https://github.com/avaloniaui" |
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
||||
xmlns:dialogs="clr-namespace:Avalonia.Dialogs;assembly=Avalonia.Dialogs"> |
xmlns:dialogs="clr-namespace:Avalonia.Dialogs;assembly=Avalonia.Dialogs"> |
||||
<Style Selector="dialogs|ManagedFileChooser"> |
<Design.PreviewWith> |
||||
<Style.Resources> |
<Border Padding="20" Width="800" Height="500"> |
||||
<ResourceDictionary> |
<dialogs:ManagedFileChooser/> |
||||
<GradientStops x:Key="IconRes.FolderBackGradientStops"> |
</Border> |
||||
</GradientStops> |
</Design.PreviewWith> |
||||
<GradientStops x:Key="IconRes.FolderFrontGradientStops"> |
|
||||
<GradientStop Offset="0" Color="#FFFFDA6F"/> |
<ControlTheme x:Key="{x:Type dialogs:ManagedFileChooser}" TargetType="dialogs:ManagedFileChooser"> |
||||
<GradientStop Offset="1" Color="#FFFEC326"/> |
<ControlTheme.Resources> |
||||
</GradientStops> |
<ResourceDictionary> |
||||
<DrawingGroup x:Key="LevelUp"> |
<GradientStops x:Key="IconRes.FolderBackGradientStops"> |
||||
<GeometryDrawing Brush="#00FFFFFF" Geometry="F1M16,16L0,16 0,0 16,0z" /> |
</GradientStops> |
||||
<GeometryDrawing Brush="#FFF6F6F6" Geometry="F1M14.5,0L6.39,0 5.39,2 2.504,2C1.677,2,1,2.673,1,3.5L1,10.582 1,10.586 1,15.414 3,13.414 3,16 7,16 7,13.414 9,15.414 9,13 14.5,13C15.327,13,16,12.327,16,11.5L16,1.5C16,0.673,15.327,0,14.5,0" /> |
<GradientStops x:Key="IconRes.FolderFrontGradientStops"> |
||||
<GeometryDrawing Brush="#FFDCB679" Geometry="F1M14,3L7.508,3 8.008,2 8.012,2 14,2z M14.5,1L7.008,1 6.008,3 2.504,3C2.227,3,2,3.224,2,3.5L2,9.582 4.998,6.586 9,10.586 9,12 14.5,12C14.775,12,15,11.776,15,11.5L15,1.5C15,1.224,14.775,1,14.5,1" /> |
<GradientStop Offset="0" Color="#FFFFDA6F"/> |
||||
<GeometryDrawing Brush="#FF00529C" Geometry="F1M8,11L5,8 2,11 2,13 4,11 4,15 6,15 6,11 8,13z" /> |
<GradientStop Offset="1" Color="#FFFEC326"/> |
||||
<GeometryDrawing Brush="#FFF0EFF1" Geometry="F1M8.0001,1.9996L7.5001,3.0006 14.0001,3.0006 14.0001,1.9996z" /> |
</GradientStops> |
||||
</DrawingGroup> |
<DrawingGroup x:Key="LevelUp"> |
||||
<dialogs:ResourceSelectorConverter x:Key="Icons"> |
<GeometryDrawing Brush="#00FFFFFF" Geometry="F1M16,16L0,16 0,0 16,0z" /> |
||||
<DrawingGroup x:Key="Icon_Folder"> |
<GeometryDrawing Brush="#FFF6F6F6" Geometry="F1M14.5,0L6.39,0 5.39,2 2.504,2C1.677,2,1,2.673,1,3.5L1,10.582 1,10.586 1,15.414 3,13.414 3,16 7,16 7,13.414 9,15.414 9,13 14.5,13C15.327,13,16,12.327,16,11.5L16,1.5C16,0.673,15.327,0,14.5,0" /> |
||||
<GeometryDrawing Geometry="M 0 0 L 16 16"/> |
<GeometryDrawing Brush="#FFDCB679" Geometry="F1M14,3L7.508,3 8.008,2 8.012,2 14,2z M14.5,1L7.008,1 6.008,3 2.504,3C2.227,3,2,3.224,2,3.5L2,9.582 4.998,6.586 9,10.586 9,12 14.5,12C14.775,12,15,11.776,15,11.5L15,1.5C15,1.224,14.775,1,14.5,1" /> |
||||
<GeometryDrawing Geometry="M 0 3 C 0,1 0,1 2,1 L 5 1 C 5.5,1 6,1 6.5,1.5 L 8 3 L 14 3 C 16,3 16,3 16,5 |
<GeometryDrawing Brush="#FF00529C" Geometry="F1M8,11L5,8 2,11 2,13 4,11 4,15 6,15 6,11 8,13z" /> |
||||
|
<GeometryDrawing Brush="#FFF0EFF1" Geometry="F1M8.0001,1.9996L7.5001,3.0006 14.0001,3.0006 14.0001,1.9996z" /> |
||||
|
</DrawingGroup> |
||||
|
<dialogs:ResourceSelectorConverter x:Key="Icons"> |
||||
|
<DrawingGroup x:Key="Icon_Folder"> |
||||
|
<GeometryDrawing Geometry="M 0 0 L 16 16"/> |
||||
|
<GeometryDrawing Geometry="M 0 3 C 0,1 0,1 2,1 L 5 1 C 5.5,1 6,1 6.5,1.5 L 8 3 L 14 3 C 16,3 16,3 16,5 |
||||
L 16,12 C 16,14 16,14 14,14 |
L 16,12 C 16,14 16,14 14,14 |
||||
L 2,14 C 0,14 0,14 0,12 Z"> |
L 2,14 C 0,14 0,14 0,12 Z"> |
||||
<GeometryDrawing.Brush> |
<GeometryDrawing.Brush> |
||||
<LinearGradientBrush StartPoint="1,4" EndPoint="23,20"> |
<LinearGradientBrush StartPoint="1,4" EndPoint="23,20"> |
||||
<GradientStop Offset="0" Color="#FFFFC018"/> |
<GradientStop Offset="0" Color="#FFFFC018"/> |
||||
<GradientStop Offset="1" Color="#FFDFA32D"/> |
<GradientStop Offset="1" Color="#FFDFA32D"/> |
||||
</LinearGradientBrush> |
</LinearGradientBrush> |
||||
</GeometryDrawing.Brush> |
</GeometryDrawing.Brush> |
||||
</GeometryDrawing> |
</GeometryDrawing> |
||||
<GeometryDrawing Geometry="M 0 4.5 L 8 4.5 L 8 9 L 0 9 Z"> |
<GeometryDrawing Geometry="M 0 4.5 L 8 4.5 L 8 9 L 0 9 Z"> |
||||
<GeometryDrawing.Brush> |
<GeometryDrawing.Brush> |
||||
<LinearGradientBrush StartPoint="0,4.5" EndPoint="0,5"> |
<LinearGradientBrush StartPoint="0,4.5" EndPoint="0,5"> |
||||
<GradientStop Offset="0" Color="#00D7A018"/> |
<GradientStop Offset="0" Color="#00D7A018"/> |
||||
<GradientStop Offset="1" Color="#7FD7A018"/> |
<GradientStop Offset="1" Color="#7FD7A018"/> |
||||
</LinearGradientBrush> |
</LinearGradientBrush> |
||||
</GeometryDrawing.Brush> |
</GeometryDrawing.Brush> |
||||
</GeometryDrawing> |
</GeometryDrawing> |
||||
<GeometryDrawing Geometry="M 0 9 C 0,5 0,5 2,5 L 5 5 C 5.5,5 6,5 6.5,4.75 L 8 4 L 14 4 C 16,4 16,4 16,6 |
<GeometryDrawing Geometry="M 0 9 C 0,5 0,5 2,5 L 5 5 C 5.5,5 6,5 6.5,4.75 L 8 4 L 14 4 C 16,4 16,4 16,6 |
||||
L 16,11 C 16,13 16,13 14,13 |
L 16,11 C 16,13 16,13 14,13 |
||||
L 2,13 C 0,13 0,13 0,11 Z"> |
L 2,13 C 0,13 0,13 0,11 Z"> |
||||
<GeometryDrawing.Brush> |
<GeometryDrawing.Brush> |
||||
<LinearGradientBrush StartPoint="1,6" EndPoint="23,19"> |
<LinearGradientBrush StartPoint="1,6" EndPoint="23,19"> |
||||
<GradientStop Offset="0" Color="#FFFFE69D"/> |
<GradientStop Offset="0" Color="#FFFFE69D"/> |
||||
<GradientStop Offset="1" Color="#FFFFC937"/> |
<GradientStop Offset="1" Color="#FFFFC937"/> |
||||
</LinearGradientBrush> |
</LinearGradientBrush> |
||||
</GeometryDrawing.Brush> |
</GeometryDrawing.Brush> |
||||
</GeometryDrawing> |
</GeometryDrawing> |
||||
<GeometryDrawing Geometry="M 0 9 C 0,5 0,5 2,5 L 5 5 C 5.5,5 6,5 6.5,4.75 L 8 4 L 14 4 |
<GeometryDrawing Geometry="M 0 9 C 0,5 0,5 2,5 L 5 5 C 5.5,5 6,5 6.5,4.75 L 8 4 L 14 4 |
||||
L 8 4.25 C 6,5.25 5.5,5.25 5.125,5.25 L 2 5.25 C 0,5.25 0,5.25 0,9.25 z" Brush="#7FFFFFFF"/> |
L 8 4.25 C 6,5.25 5.5,5.25 5.125,5.25 L 2 5.25 C 0,5.25 0,5.25 0,9.25 z" Brush="#7FFFFFFF"/> |
||||
</DrawingGroup> |
</DrawingGroup> |
||||
<DrawingGroup x:Key="Icon_File"> |
<DrawingGroup x:Key="Icon_File"> |
||||
<GeometryDrawing Geometry="M 0 0 L 16 16"/> |
<GeometryDrawing Geometry="M 0 0 L 16 16"/> |
||||
<GeometryDrawing Geometry="M 2 0 L 10 0 L 14 4 L 14 16 L 2 16 Z" Brush="#FF797774"/> |
<GeometryDrawing Geometry="M 2 0 L 10 0 L 14 4 L 14 16 L 2 16 Z" Brush="#FF797774"/> |
||||
<GeometryDrawing Geometry="M 3 1 L 9.7 1 L 13 4.3 L 13 15 L 3 15 Z" Brush="#FFFAFAFA"/> |
<GeometryDrawing Geometry="M 3 1 L 9.7 1 L 13 4.3 L 13 15 L 3 15 Z" Brush="#FFFAFAFA"/> |
||||
<GeometryDrawing Geometry="L 9 1 L 9 5 L 14 5 L 14 4 L 10 4 L 10 1 Z" Brush="#FF797774"/> |
<GeometryDrawing Geometry="L 9 1 L 9 5 L 14 5 L 14 4 L 10 4 L 10 1 Z" Brush="#FF797774"/> |
||||
</DrawingGroup> |
</DrawingGroup> |
||||
<DrawingGroup x:Key="Icon_Volume"> |
<DrawingGroup x:Key="Icon_Volume"> |
||||
<GeometryDrawing Geometry="M 0 0 L 16 16"/> |
<GeometryDrawing Geometry="M 0 0 L 16 16"/> |
||||
<GeometryDrawing Geometry="M 4 5 L 12 5 L 14.5 7.5 C 15,8 15,8 15,9 L 1 9 C 1,8 1,8 1.5 7.5 Z" Brush="#FFE1E3E6"/> |
<GeometryDrawing Geometry="M 4 5 L 12 5 L 14.5 7.5 C 15,8 15,8 15,9 L 1 9 C 1,8 1,8 1.5 7.5 Z" Brush="#FFE1E3E6"/> |
||||
<GeometryDrawing Geometry="M 12 5 L 14.5 7.5 C 15,8 15,8 15,9 L 10 9 L 10 5 Z"> |
<GeometryDrawing Geometry="M 12 5 L 14.5 7.5 C 15,8 15,8 15,9 L 10 9 L 10 5 Z"> |
||||
<GeometryDrawing.Brush> |
<GeometryDrawing.Brush> |
||||
<LinearGradientBrush StartPoint="12,5" EndPoint="11.5,5.5"> |
<LinearGradientBrush StartPoint="12,5" EndPoint="11.5,5.5"> |
||||
<GradientStop Offset="0" Color="#FFCDCFD1"/> |
<GradientStop Offset="0" Color="#FFCDCFD1"/> |
||||
<GradientStop Offset="1" Color="#00CDCFD1"/> |
<GradientStop Offset="1" Color="#00CDCFD1"/> |
||||
</LinearGradientBrush> |
</LinearGradientBrush> |
||||
</GeometryDrawing.Brush> |
</GeometryDrawing.Brush> |
||||
</GeometryDrawing> |
</GeometryDrawing> |
||||
<GeometryDrawing Geometry="M 4 5 L 1.5 7.5 C 1,8 1,8 1,9 L 4 9 L 6 9 L 6 5 Z"> |
<GeometryDrawing Geometry="M 4 5 L 1.5 7.5 C 1,8 1,8 1,9 L 4 9 L 6 9 L 6 5 Z"> |
||||
<GeometryDrawing.Brush> |
<GeometryDrawing.Brush> |
||||
<LinearGradientBrush StartPoint="4,5" EndPoint="4.5,5.5"> |
<LinearGradientBrush StartPoint="4,5" EndPoint="4.5,5.5"> |
||||
<GradientStop Offset="0" Color="#FFCDCFD1"/> |
<GradientStop Offset="0" Color="#FFCDCFD1"/> |
||||
<GradientStop Offset="1" Color="#00CDCFD1"/> |
<GradientStop Offset="1" Color="#00CDCFD1"/> |
||||
</LinearGradientBrush> |
</LinearGradientBrush> |
||||
</GeometryDrawing.Brush> |
</GeometryDrawing.Brush> |
||||
</GeometryDrawing> |
</GeometryDrawing> |
||||
<GeometryDrawing Geometry="M 1 9 C 1,8 1,8 2,8 L 14 8 |
<GeometryDrawing Geometry="M 1 9 C 1,8 1,8 2,8 L 14 8 |
||||
C 15,8 15,8 15,9 L 15 11 |
C 15,8 15,8 15,9 L 15 11 |
||||
C 15,12 15,12 14,12 L 2 12 |
C 15,12 15,12 14,12 L 2 12 |
||||
C 1,12 1,12 1,11 Z"> |
C 1,12 1,12 1,11 Z"> |
||||
<GeometryDrawing.Brush> |
<GeometryDrawing.Brush> |
||||
<LinearGradientBrush StartPoint="0,8" EndPoint="0,12"> |
<LinearGradientBrush StartPoint="0,8" EndPoint="0,12"> |
||||
<GradientStop Offset="0" Color="#FF737374"/> |
<GradientStop Offset="0" Color="#FF737374"/> |
||||
<GradientStop Offset="1" Color="#FFA8A8A8"/> |
<GradientStop Offset="1" Color="#FFA8A8A8"/> |
||||
</LinearGradientBrush> |
</LinearGradientBrush> |
||||
</GeometryDrawing.Brush> |
</GeometryDrawing.Brush> |
||||
</GeometryDrawing> |
</GeometryDrawing> |
||||
<GeometryDrawing Geometry="M 2 9 C 2,8 2,8 3,8 L 13 8 |
<GeometryDrawing Geometry="M 2 9 C 2,8 2,8 3,8 L 13 8 |
||||
C 14,8 14,8 14,9 L 14 10 |
C 14,8 14,8 14,9 L 14 10 |
||||
C 14,11 14,11 13,11 L 3 11 |
C 14,11 14,11 13,11 L 3 11 |
||||
C 2,11 2,11 2,10 Z"> |
C 2,11 2,11 2,10 Z"> |
||||
<GeometryDrawing.Brush> |
<GeometryDrawing.Brush> |
||||
<LinearGradientBrush StartPoint="0,8" EndPoint="0,11"> |
<LinearGradientBrush StartPoint="0,8" EndPoint="0,11"> |
||||
<GradientStop Offset="0" Color="#FF333333"/> |
<GradientStop Offset="0" Color="#FF333333"/> |
||||
<GradientStop Offset="1" Color="#FF5A5A5A"/> |
<GradientStop Offset="1" Color="#FF5A5A5A"/> |
||||
</LinearGradientBrush> |
</LinearGradientBrush> |
||||
</GeometryDrawing.Brush> |
</GeometryDrawing.Brush> |
||||
</GeometryDrawing> |
</GeometryDrawing> |
||||
<GeometryDrawing> |
<GeometryDrawing> |
||||
<GeometryDrawing.Geometry> |
<GeometryDrawing.Geometry> |
||||
<EllipseGeometry Rect="2.5,8.5,2,2"/> |
<EllipseGeometry Rect="2.5,8.5,2,2"/> |
||||
</GeometryDrawing.Geometry> |
</GeometryDrawing.Geometry> |
||||
<GeometryDrawing.Brush> |
<GeometryDrawing.Brush> |
||||
<RadialGradientBrush GradientOrigin="3.5,9.5" Center="3.5,9.5"> |
<RadialGradientBrush GradientOrigin="3.5,9.5" Center="3.5,9.5"> |
||||
<GradientStop Offset="0.8" Color="#4001FF01"/> |
<GradientStop Offset="0.8" Color="#4001FF01"/> |
||||
<GradientStop Offset="1" Color="#0001FF01"/> |
<GradientStop Offset="1" Color="#0001FF01"/> |
||||
</RadialGradientBrush> |
</RadialGradientBrush> |
||||
</GeometryDrawing.Brush> |
</GeometryDrawing.Brush> |
||||
</GeometryDrawing> |
</GeometryDrawing> |
||||
<GeometryDrawing> |
<GeometryDrawing> |
||||
<GeometryDrawing.Geometry> |
<GeometryDrawing.Geometry> |
||||
<EllipseGeometry Rect="3,9,1,1"/> |
<EllipseGeometry Rect="3,9,1,1"/> |
||||
</GeometryDrawing.Geometry> |
</GeometryDrawing.Geometry> |
||||
<GeometryDrawing.Brush> |
<GeometryDrawing.Brush> |
||||
<RadialGradientBrush GradientOrigin="3.5,9.5" Center="3.25,9.75"> |
<RadialGradientBrush GradientOrigin="3.5,9.5" Center="3.25,9.75"> |
||||
<GradientStop Offset="0" Color="#FFB6FFB6"/> |
<GradientStop Offset="0" Color="#FFB6FFB6"/> |
||||
<GradientStop Offset="1" Color="#FF01FF01"/> |
<GradientStop Offset="1" Color="#FF01FF01"/> |
||||
</RadialGradientBrush> |
</RadialGradientBrush> |
||||
</GeometryDrawing.Brush> |
</GeometryDrawing.Brush> |
||||
</GeometryDrawing> |
</GeometryDrawing> |
||||
<GeometryDrawing Geometry="M 3.23483495705 9.76516504295 A 0.375,0.375 180 1 0 3.76516504295,9.23483495705 A 0.4375,0.4375 135 0 1 3.23483495705,9.76516504295 Z" Brush="#FF00B300"/> |
<GeometryDrawing Geometry="M 3.23483495705 9.76516504295 A 0.375,0.375 180 1 0 3.76516504295,9.23483495705 A 0.4375,0.4375 135 0 1 3.23483495705,9.76516504295 Z" Brush="#FF00B300"/> |
||||
</DrawingGroup> |
</DrawingGroup> |
||||
</dialogs:ResourceSelectorConverter> |
</dialogs:ResourceSelectorConverter> |
||||
</ResourceDictionary> |
</ResourceDictionary> |
||||
</Style.Resources> |
</ControlTheme.Resources> |
||||
<Setter Property="Template"> |
<Setter Property="Template"> |
||||
|
<ControlTemplate> |
||||
|
<DockPanel> |
||||
|
<ListBox x:Name="QuickLinks" DockPanel.Dock="Left" Items="{Binding QuickLinks}" SelectedIndex="{Binding QuickLinksSelectedIndex}" Focusable="False"> |
||||
|
<ListBox.ItemTemplate> |
||||
|
<DataTemplate> |
||||
|
<StackPanel Spacing="4" Orientation="Horizontal" Background="Transparent"> |
||||
|
<DrawingPresenter Width="16" Height="16" Drawing="{Binding IconKey, Converter={StaticResource Icons}}"/> |
||||
|
<TextBlock Text="{Binding DisplayName}"/> |
||||
|
</StackPanel> |
||||
|
</DataTemplate> |
||||
|
</ListBox.ItemTemplate> |
||||
|
</ListBox> |
||||
|
<DockPanel x:Name="NavBar" DockPanel.Dock="Top" Margin="8,5,8,0" VerticalAlignment="Center"> |
||||
|
<Rectangle Fill="{DynamicResource SystemControlHighlightAltBaseMediumLowBrush}" Height="1" Margin="0,5,0,0" DockPanel.Dock="Bottom"/> |
||||
|
<DockPanel Margin="4,0"> |
||||
|
<Button Command="{Binding GoUp}" DockPanel.Dock="Left"> |
||||
|
<Path Data="M 0 7 L 7 0 L 14 7 M 7 0 L 7 16" Stroke="{CompiledBinding $parent[Button].Foreground}" StrokeThickness="1" HorizontalAlignment="Center" VerticalAlignment="Center" Margin="0,1,0,-1"/> |
||||
|
</Button> |
||||
|
<TextBox x:Name="Location" Text="{Binding Location}"> |
||||
|
<TextBox.KeyBindings> |
||||
|
<KeyBinding Command="{Binding EnterPressed}" Gesture="Enter"/> |
||||
|
</TextBox.KeyBindings> |
||||
|
</TextBox> |
||||
|
</DockPanel> |
||||
|
</DockPanel> |
||||
|
<DockPanel Margin="8,0,8,5" DockPanel.Dock="Bottom"> |
||||
|
<Rectangle Fill="{DynamicResource SystemControlHighlightAltBaseMediumLowBrush}" Height="1" Margin="0,0,0,5" DockPanel.Dock="Top"/> |
||||
|
<DockPanel Margin="4,0"> |
||||
|
<DockPanel DockPanel.Dock="Top" Margin="0,0,0,4"> |
||||
|
<ComboBox DockPanel.Dock="Right" |
||||
|
IsVisible="{Binding ShowFilters}" |
||||
|
Items="{Binding Filters}" |
||||
|
SelectedItem="{Binding SelectedFilter}" /> |
||||
|
<TextBox Text="{Binding FileName}" Watermark="File name" IsVisible="{Binding !SelectingFolder}" /> |
||||
|
</DockPanel> |
||||
|
<CheckBox IsChecked="{Binding ShowHiddenFiles}" Content="Show hidden files" DockPanel.Dock="Left"/> |
||||
|
<UniformGrid x:Name="Finalize" HorizontalAlignment="Right" Rows="1"> |
||||
|
<Button Command="{Binding Ok}">OK</Button> |
||||
|
<Button Command="{Binding Cancel}">Cancel</Button> |
||||
|
</UniformGrid> |
||||
|
</DockPanel> |
||||
|
</DockPanel> |
||||
|
|
||||
|
<DockPanel Grid.IsSharedSizeScope="True"> |
||||
|
<Grid DockPanel.Dock="Top" Margin="15 5 0 0" HorizontalAlignment="Stretch"> |
||||
|
<Grid.ColumnDefinitions> |
||||
|
<ColumnDefinition Width="20" SharedSizeGroup="Icon" /> |
||||
|
<ColumnDefinition Width="16" SharedSizeGroup="Splitter" /> |
||||
|
<ColumnDefinition Width="275" SharedSizeGroup="Name" /> |
||||
|
<ColumnDefinition Width="16" SharedSizeGroup="Splitter" /> |
||||
|
<ColumnDefinition Width="200" SharedSizeGroup="Modified" /> |
||||
|
<ColumnDefinition Width="16" SharedSizeGroup="Splitter" /> |
||||
|
<ColumnDefinition Width="150" SharedSizeGroup="Type" /> |
||||
|
<ColumnDefinition Width="16" SharedSizeGroup="Splitter" /> |
||||
|
<ColumnDefinition Width="200" SharedSizeGroup="Size" /> |
||||
|
</Grid.ColumnDefinitions> |
||||
|
<Grid.Styles> |
||||
|
<Style Selector="GridSplitter"> |
||||
|
<Setter Property="Background" Value="{DynamicResource SystemControlHighlightAltBaseMediumLowBrush}"/> |
||||
|
<Setter Property="Template"> |
||||
|
<ControlTemplate> |
||||
|
<Border VerticalAlignment="Stretch" BorderThickness="0" Background="#01000000"> |
||||
|
<Rectangle Width="1" VerticalAlignment="Stretch" Fill="{TemplateBinding Background}"/> |
||||
|
</Border> |
||||
|
</ControlTemplate> |
||||
|
</Setter> |
||||
|
</Style> |
||||
|
</Grid.Styles> |
||||
|
<GridSplitter Grid.Column="1" /> |
||||
|
<TextBlock Grid.Column="2" Text="Name" /> |
||||
|
<GridSplitter Grid.Column="3" /> |
||||
|
<TextBlock Grid.Column="4" Text="Date Modified" /> |
||||
|
<GridSplitter Grid.Column="5" /> |
||||
|
<TextBlock Grid.Column="6" Text="Type" /> |
||||
|
<GridSplitter Grid.Column="7" /> |
||||
|
<TextBlock Grid.Column="8" Text="Size" /> |
||||
|
</Grid> |
||||
|
<ListBox x:Name="Files" |
||||
|
VirtualizationMode="Simple" |
||||
|
Items="{Binding Items}" |
||||
|
Margin="0 5" |
||||
|
SelectionMode="{Binding SelectionMode}" |
||||
|
SelectedItems="{Binding SelectedItems}" |
||||
|
Background="Transparent" |
||||
|
ScrollViewer.HorizontalScrollBarVisibility="Disabled"> |
||||
|
<ListBox.ItemTemplate> |
||||
|
<DataTemplate> |
||||
|
<Grid Background="Transparent"> |
||||
|
<Grid.ColumnDefinitions> |
||||
|
<ColumnDefinition SharedSizeGroup="Icon" /> |
||||
|
<ColumnDefinition SharedSizeGroup="Splitter" /> |
||||
|
<ColumnDefinition SharedSizeGroup="Name" /> |
||||
|
<ColumnDefinition SharedSizeGroup="Splitter" /> |
||||
|
<ColumnDefinition SharedSizeGroup="Modified" /> |
||||
|
<ColumnDefinition SharedSizeGroup="Splitter" /> |
||||
|
<ColumnDefinition SharedSizeGroup="Type" /> |
||||
|
<ColumnDefinition SharedSizeGroup="Splitter" /> |
||||
|
<ColumnDefinition SharedSizeGroup="Size" /> |
||||
|
</Grid.ColumnDefinitions> |
||||
|
<DrawingPresenter Width="16" Height="16" Drawing="{Binding IconKey, Converter={StaticResource Icons}}"/> |
||||
|
<TextBlock Grid.Column="2" Text="{Binding DisplayName}"/> |
||||
|
<TextBlock Grid.Column="4" Text="{Binding Modified}" /> |
||||
|
<TextBlock Grid.Column="6" Text="{Binding Type}" /> |
||||
|
<TextBlock Grid.Column="8"> |
||||
|
<TextBlock.Text> |
||||
|
<Binding Path="Size"> |
||||
|
<Binding.Converter> |
||||
|
<dialogs:FileSizeStringConverter/> |
||||
|
</Binding.Converter> |
||||
|
</Binding> |
||||
|
</TextBlock.Text> |
||||
|
</TextBlock> |
||||
|
</Grid> |
||||
|
</DataTemplate> |
||||
|
</ListBox.ItemTemplate> |
||||
|
</ListBox> |
||||
|
</DockPanel> |
||||
|
</DockPanel> |
||||
|
</ControlTemplate> |
||||
|
</Setter> |
||||
|
<Style Selector="^ /template/ ListBox#QuickLinks"> |
||||
|
<Setter Property="Margin" Value="0"/> |
||||
|
<Setter Property="Background" Value="{DynamicResource SystemControlBackgroundChromeMediumBrush}"/> |
||||
|
<Setter Property="BorderThickness" Value="0"/> |
||||
|
<Setter Property="Width" Value="240"/> |
||||
|
<Setter Property="Padding" Value="0,20"/> |
||||
|
<Setter Property="Template"> |
||||
|
<ControlTemplate> |
||||
|
<Border Name="border" BoxShadow="inset -6 0 3 -3 #20000000" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}"> |
||||
|
<ScrollViewer Name="PART_ScrollViewer" HorizontalScrollBarVisibility="{TemplateBinding (ScrollViewer.HorizontalScrollBarVisibility)}" VerticalScrollBarVisibility="{TemplateBinding (ScrollViewer.VerticalScrollBarVisibility)}"> |
||||
|
<ItemsPresenter Name="PART_ItemsPresenter" |
||||
|
Items="{TemplateBinding Items}" |
||||
|
ItemsPanel="{TemplateBinding ItemsPanel}" |
||||
|
ItemTemplate="{TemplateBinding ItemTemplate}" |
||||
|
Margin="{TemplateBinding Padding}" |
||||
|
VirtualizationMode="{TemplateBinding VirtualizationMode}"/> |
||||
|
</ScrollViewer> |
||||
|
</Border> |
||||
|
</ControlTemplate> |
||||
|
</Setter> |
||||
|
<Setter Property="ItemContainerTheme"> |
||||
|
<ControlTheme TargetType="ListBoxItem"> |
||||
|
<Setter Property="Height" Value="32"/> |
||||
|
<Setter Property="Padding" Value="30,6"/> |
||||
|
<Setter Property="Template"> |
||||
<ControlTemplate> |
<ControlTemplate> |
||||
<DockPanel> |
<Border x:Name="LayoutRoot" CornerRadius="2" Margin="10,0"> |
||||
<ListBox x:Name="QuickLinks" DockPanel.Dock="Left" Items="{Binding QuickLinks}" SelectedIndex="{Binding QuickLinksSelectedIndex}" Focusable="False"> |
<Panel> |
||||
<ListBox.ItemTemplate> |
<Border x:Name="SelectedLine" HorizontalAlignment="Left" Margin="2,6" CornerRadius="0.5" Width="3" Background="{DynamicResource SystemControlHighlightAccentBrush}" IsVisible="{TemplateBinding IsSelected}"/> |
||||
<DataTemplate> |
<ContentPresenter Name="PART_ContentPresenter" |
||||
<StackPanel Spacing="4" Orientation="Horizontal" Background="Transparent"> |
Background="Transparent" |
||||
<DrawingPresenter Width="16" Height="16" Drawing="{Binding IconKey, Converter={StaticResource Icons}}"/> |
BorderBrush="Transparent" |
||||
<TextBlock Text="{Binding DisplayName}"/> |
BorderThickness="0" |
||||
</StackPanel> |
ContentTemplate="{TemplateBinding ContentTemplate}" |
||||
</DataTemplate> |
Content="{TemplateBinding Content}" |
||||
</ListBox.ItemTemplate> |
Padding="{TemplateBinding Padding}" |
||||
</ListBox> |
VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" |
||||
<DockPanel x:Name="NavBar" DockPanel.Dock="Top" Margin="8,5,8,0" VerticalAlignment="Center"> |
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"/> |
||||
<Rectangle Fill="{DynamicResource SystemControlHighlightAltBaseMediumLowBrush}" Height="1" Margin="0,5,0,0" DockPanel.Dock="Bottom"/> |
|
||||
<DockPanel Margin="4,0"> |
|
||||
<Button Command="{Binding GoUp}" DockPanel.Dock="Left"> |
|
||||
<Path Data="M 0 7 L 7 0 L 14 7 M 7 0 L 7 16" Stroke="{CompiledBinding $parent[Button].Foreground}" StrokeThickness="1" HorizontalAlignment="Center" VerticalAlignment="Center" Margin="0,1,0,-1"/> |
|
||||
</Button> |
|
||||
<TextBox x:Name="Location" Text="{Binding Location}"> |
|
||||
<TextBox.KeyBindings> |
|
||||
<KeyBinding Command="{Binding EnterPressed}" Gesture="Enter"/> |
|
||||
</TextBox.KeyBindings> |
|
||||
</TextBox> |
|
||||
</DockPanel> |
|
||||
</DockPanel> |
|
||||
<DockPanel Margin="8,0,8,5" DockPanel.Dock="Bottom"> |
|
||||
<Rectangle Fill="{DynamicResource SystemControlHighlightAltBaseMediumLowBrush}" Height="1" Margin="0,0,0,5" DockPanel.Dock="Top"/> |
|
||||
<DockPanel Margin="4,0"> |
|
||||
<DockPanel DockPanel.Dock="Top" Margin="0,0,0,4"> |
|
||||
<ComboBox DockPanel.Dock="Right" |
|
||||
IsVisible="{Binding ShowFilters}" |
|
||||
Items="{Binding Filters}" |
|
||||
SelectedItem="{Binding SelectedFilter}" /> |
|
||||
<TextBox Text="{Binding FileName}" Watermark="File name" IsVisible="{Binding !SelectingFolder}" /> |
|
||||
</DockPanel> |
|
||||
<CheckBox IsChecked="{Binding ShowHiddenFiles}" Content="Show hidden files" DockPanel.Dock="Left"/> |
|
||||
<UniformGrid x:Name="Finalize" HorizontalAlignment="Right" Rows="1"> |
|
||||
<Button Command="{Binding Ok}">OK</Button> |
|
||||
<Button Command="{Binding Cancel}">Cancel</Button> |
|
||||
</UniformGrid> |
|
||||
</DockPanel> |
|
||||
</DockPanel> |
|
||||
|
|
||||
<DockPanel Grid.IsSharedSizeScope="True"> |
</Panel> |
||||
<Grid DockPanel.Dock="Top" Margin="15 5 0 0" HorizontalAlignment="Stretch"> |
</Border> |
||||
<Grid.ColumnDefinitions> |
|
||||
<ColumnDefinition Width="20" SharedSizeGroup="Icon" /> |
|
||||
<ColumnDefinition Width="16" SharedSizeGroup="Splitter" /> |
|
||||
<ColumnDefinition Width="275" SharedSizeGroup="Name" /> |
|
||||
<ColumnDefinition Width="16" SharedSizeGroup="Splitter" /> |
|
||||
<ColumnDefinition Width="200" SharedSizeGroup="Modified" /> |
|
||||
<ColumnDefinition Width="16" SharedSizeGroup="Splitter" /> |
|
||||
<ColumnDefinition Width="150" SharedSizeGroup="Type" /> |
|
||||
<ColumnDefinition Width="16" SharedSizeGroup="Splitter" /> |
|
||||
<ColumnDefinition Width="200" SharedSizeGroup="Size" /> |
|
||||
</Grid.ColumnDefinitions> |
|
||||
<Grid.Styles> |
|
||||
<Style Selector="GridSplitter"> |
|
||||
<Setter Property="Background" Value="{DynamicResource SystemControlHighlightAltBaseMediumLowBrush}"/> |
|
||||
<Setter Property="Template"> |
|
||||
<ControlTemplate> |
|
||||
<Border VerticalAlignment="Stretch" BorderThickness="0" Background="#01000000"> |
|
||||
<Rectangle Width="1" VerticalAlignment="Stretch" Fill="{TemplateBinding Background}"/> |
|
||||
</Border> |
|
||||
</ControlTemplate> |
|
||||
</Setter> |
|
||||
</Style> |
|
||||
</Grid.Styles> |
|
||||
<GridSplitter Grid.Column="1" /> |
|
||||
<TextBlock Grid.Column="2" Text="Name" /> |
|
||||
<GridSplitter Grid.Column="3" /> |
|
||||
<TextBlock Grid.Column="4" Text="Date Modified" /> |
|
||||
<GridSplitter Grid.Column="5" /> |
|
||||
<TextBlock Grid.Column="6" Text="Type" /> |
|
||||
<GridSplitter Grid.Column="7" /> |
|
||||
<TextBlock Grid.Column="8" Text="Size" /> |
|
||||
</Grid> |
|
||||
<ListBox x:Name="Files" |
|
||||
VirtualizationMode="Simple" |
|
||||
Items="{Binding Items}" |
|
||||
Margin="0 5" |
|
||||
SelectionMode="{Binding SelectionMode}" |
|
||||
SelectedItems="{Binding SelectedItems}" |
|
||||
Background="Transparent" |
|
||||
ScrollViewer.HorizontalScrollBarVisibility="Disabled"> |
|
||||
<ListBox.ItemTemplate> |
|
||||
<DataTemplate> |
|
||||
<Grid Background="Transparent"> |
|
||||
<Grid.ColumnDefinitions> |
|
||||
<ColumnDefinition SharedSizeGroup="Icon" /> |
|
||||
<ColumnDefinition SharedSizeGroup="Splitter" /> |
|
||||
<ColumnDefinition SharedSizeGroup="Name" /> |
|
||||
<ColumnDefinition SharedSizeGroup="Splitter" /> |
|
||||
<ColumnDefinition SharedSizeGroup="Modified" /> |
|
||||
<ColumnDefinition SharedSizeGroup="Splitter" /> |
|
||||
<ColumnDefinition SharedSizeGroup="Type" /> |
|
||||
<ColumnDefinition SharedSizeGroup="Splitter" /> |
|
||||
<ColumnDefinition SharedSizeGroup="Size" /> |
|
||||
</Grid.ColumnDefinitions> |
|
||||
<DrawingPresenter Width="16" Height="16" Drawing="{Binding IconKey, Converter={StaticResource Icons}}"/> |
|
||||
<TextBlock Grid.Column="2" Text="{Binding DisplayName}"/> |
|
||||
<TextBlock Grid.Column="4" Text="{Binding Modified}" /> |
|
||||
<TextBlock Grid.Column="6" Text="{Binding Type}" /> |
|
||||
<TextBlock Grid.Column="8"> |
|
||||
<TextBlock.Text> |
|
||||
<Binding Path="Size"> |
|
||||
<Binding.Converter> |
|
||||
<dialogs:FileSizeStringConverter/> |
|
||||
</Binding.Converter> |
|
||||
</Binding> |
|
||||
</TextBlock.Text> |
|
||||
</TextBlock> |
|
||||
</Grid> |
|
||||
</DataTemplate> |
|
||||
</ListBox.ItemTemplate> |
|
||||
</ListBox> |
|
||||
</DockPanel> |
|
||||
</DockPanel> |
|
||||
</ControlTemplate> |
</ControlTemplate> |
||||
</Setter> |
</Setter> |
||||
</Style> |
|
||||
|
|
||||
|
<Style Selector="^:pointerover /template/ Border#LayoutRoot"> |
||||
<Style Selector="dialogs|ManagedFileChooser /template/ ListBox#QuickLinks"> |
<Setter Property="Background" Value="{DynamicResource SystemControlBackgroundAltMediumBrush}"/> |
||||
<Setter Property="Margin" Value="0"/> |
</Style> |
||||
<Setter Property="Background" Value="{DynamicResource SystemControlBackgroundChromeMediumBrush}"/> |
<Style Selector="^:selected /template/ Border#LayoutRoot"> |
||||
<Setter Property="BorderThickness" Value="0"/> |
<Setter Property="Background" Value="{DynamicResource SystemControlBackgroundAltMediumHighBrush}"/> |
||||
<Setter Property="Width" Value="240"/> |
</Style> |
||||
<Setter Property="Padding" Value="0,20"/> |
</ControlTheme> |
||||
<Setter Property="Template"> |
</Setter> |
||||
<ControlTemplate> |
|
||||
<Border Name="border" BoxShadow="inset -6 0 3 -3 #20000000" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}"> |
|
||||
<ScrollViewer Name="PART_ScrollViewer" HorizontalScrollBarVisibility="{TemplateBinding (ScrollViewer.HorizontalScrollBarVisibility)}" VerticalScrollBarVisibility="{TemplateBinding (ScrollViewer.VerticalScrollBarVisibility)}"> |
|
||||
<ItemsPresenter Name="PART_ItemsPresenter" |
|
||||
Items="{TemplateBinding Items}" |
|
||||
ItemsPanel="{TemplateBinding ItemsPanel}" |
|
||||
ItemTemplate="{TemplateBinding ItemTemplate}" |
|
||||
Margin="{TemplateBinding Padding}" |
|
||||
VirtualizationMode="{TemplateBinding VirtualizationMode}"/> |
|
||||
</ScrollViewer> |
|
||||
</Border> |
|
||||
</ControlTemplate> |
|
||||
</Setter> |
|
||||
</Style> |
</Style> |
||||
<Style Selector="dialogs|ManagedFileChooser /template/ ListBox#QuickLinks ListBoxItem"> |
|
||||
<Setter Property="Height" Value="32"/> |
|
||||
<Setter Property="Padding" Value="30,6"/> |
|
||||
<Setter Property="Template"> |
|
||||
<ControlTemplate> |
|
||||
<Border x:Name="LayoutRoot" CornerRadius="2" Margin="10,0"> |
|
||||
<Panel> |
|
||||
<Border x:Name="SelectedLine" HorizontalAlignment="Left" Margin="2,6" CornerRadius="0.5" Width="3" Background="{DynamicResource SystemControlHighlightAccentBrush}" IsVisible="{TemplateBinding IsSelected}"/> |
|
||||
<ContentPresenter Name="PART_ContentPresenter" |
|
||||
Background="Transparent" |
|
||||
BorderBrush="Transparent" |
|
||||
BorderThickness="0" |
|
||||
ContentTemplate="{TemplateBinding ContentTemplate}" |
|
||||
Content="{TemplateBinding Content}" |
|
||||
Padding="{TemplateBinding Padding}" |
|
||||
VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" |
|
||||
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"/> |
|
||||
|
|
||||
</Panel> |
<Style Selector="^ /template/ DockPanel#NavBar Button, ^ /template/ DockPanel#NavBar TextBox"> |
||||
</Border> |
<Setter Property="Height" Value="30"/> |
||||
</ControlTemplate> |
|
||||
</Setter> |
|
||||
</Style> |
|
||||
<Style Selector="dialogs|ManagedFileChooser /template/ ListBox#QuickLinks ListBoxItem:pointerover /template/ Border#LayoutRoot"> |
|
||||
<Setter Property="Background" Value="{DynamicResource SystemControlBackgroundAltMediumBrush}"/> |
|
||||
</Style> |
</Style> |
||||
<Style Selector="dialogs|ManagedFileChooser /template/ ListBox#QuickLinks ListBoxItem:selected /template/ Border#LayoutRoot"> |
<Style Selector="^ /template/ DockPanel#NavBar Button"> |
||||
<Setter Property="Background" Value="{DynamicResource SystemControlBackgroundAltMediumHighBrush}"/> |
<Setter Property="VerticalAlignment" Value="Stretch"/> |
||||
|
<Setter Property="Width" Value="40"/> |
||||
|
<Setter Property="Margin" Value="0,0,8,0"/> |
||||
|
<Setter Property="BorderThickness" Value="0"/> |
||||
</Style> |
</Style> |
||||
<Style Selector="dialogs|ManagedFileChooser /template/ DockPanel#NavBar Button, |
<Style Selector="^ /template/ DockPanel#NavBar Button:not(:pointerover):not(:pressed)"> |
||||
dialogs|ManagedFileChooser /template/ DockPanel#NavBar TextBox"> |
<Setter Property="Background" Value="Transparent"/> |
||||
<Setter Property="Height" Value="30"/> |
|
||||
</Style> |
|
||||
<Style Selector="dialogs|ManagedFileChooser /template/ DockPanel#NavBar Button"> |
|
||||
<Setter Property="VerticalAlignment" Value="Stretch"/> |
|
||||
<Setter Property="Width" Value="40"/> |
|
||||
<Setter Property="Margin" Value="0,0,8,0"/> |
|
||||
<Setter Property="BorderThickness" Value="0"/> |
|
||||
</Style> |
|
||||
<Style Selector="dialogs|ManagedFileChooser /template/ DockPanel#NavBar Button:not(:pointerover):not(:pressed)"> |
|
||||
<Setter Property="Background" Value="Transparent"/> |
|
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="dialogs|ManagedFileChooser /template/ UniformGrid#Finalize > Button"> |
<Style Selector="^ /template/ UniformGrid#Finalize > Button"> |
||||
<Setter Property="HorizontalContentAlignment" Value="Center"/> |
<Setter Property="HorizontalContentAlignment" Value="Center"/> |
||||
<Setter Property="HorizontalAlignment" Value="Stretch"/> |
<Setter Property="HorizontalAlignment" Value="Stretch"/> |
||||
<Setter Property="Margin" Value="4,0,0,0"/> |
<Setter Property="Margin" Value="4,0,0,0"/> |
||||
</Style> |
|
||||
<Style Selector="dialogs|ManagedFileChooser /template/ UniformGrid#Finalize > Button /template/ ContentPresenter#PART_ContentPresenter"> |
|
||||
<Setter Property="HorizontalAlignment" Value="Stretch"/> |
|
||||
</Style> |
</Style> |
||||
</Styles> |
</ControlTheme> |
||||
|
</ResourceDictionary> |
||||
|
|||||
@ -1,36 +1,113 @@ |
|||||
<Style xmlns="https://github.com/avaloniaui" |
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
||||
Selector="Menu"> |
|
||||
<Design.PreviewWith> |
<Design.PreviewWith> |
||||
<Border Padding="20"> |
<Border Padding="20"> |
||||
<Menu> |
<Menu> |
||||
<MenuItem Header="New" /> |
<MenuItem Header="_Standard" /> |
||||
<MenuItem Header="Open" /> |
<MenuItem Header="Selected" IsSelected="True" /> |
||||
|
<MenuItem Header="Disabled" IsEnabled="False"/> |
||||
</Menu> |
</Menu> |
||||
</Border> |
</Border> |
||||
</Design.PreviewWith> |
</Design.PreviewWith> |
||||
|
|
||||
<Style.Resources> |
<x:Double x:Key="MenuBarHeight">32</x:Double> |
||||
<x:Double x:Key="MenuBarHeight">32</x:Double> |
|
||||
</Style.Resources> |
|
||||
|
|
||||
<Setter Property="Background" Value="Transparent" /> |
<ControlTheme x:Key="FluentTopLevelMenuItem" TargetType="MenuItem"> |
||||
<Setter Property="Height" Value="{DynamicResource MenuBarHeight}" /> |
<Setter Property="Background" Value="{DynamicResource MenuFlyoutItemBackground}" /> |
||||
<Setter Property="Template"> |
<Setter Property="Foreground" Value="{DynamicResource MenuFlyoutItemForeground}" /> |
||||
<ControlTemplate> |
<!-- Narrow padding should be used for mouse input, when non-narrow one should be used for touch input in future. --> |
||||
<Border Background="{TemplateBinding Background}" |
<Setter Property="FontSize" Value="{DynamicResource ControlContentThemeFontSize}" /> |
||||
BorderBrush="{TemplateBinding BorderBrush}" |
<Setter Property="Padding" Value="{DynamicResource MenuBarItemPadding}" /> |
||||
BorderThickness="{TemplateBinding BorderThickness}" |
<Setter Property="Template"> |
||||
CornerRadius="{TemplateBinding CornerRadius}" |
<ControlTemplate> |
||||
HorizontalAlignment="Stretch" |
<Border Name="PART_LayoutRoot" |
||||
Padding="{TemplateBinding Padding}"> |
Background="{TemplateBinding Background}" |
||||
<ItemsPresenter Name="PART_ItemsPresenter" |
BorderBrush="{TemplateBinding BorderBrush}" |
||||
Items="{TemplateBinding Items}" |
BorderThickness="{TemplateBinding BorderThickness}" |
||||
ItemsPanel="{TemplateBinding ItemsPanel}" |
CornerRadius="{TemplateBinding CornerRadius}"> |
||||
ItemTemplate="{TemplateBinding ItemTemplate}" |
<Panel> |
||||
VerticalAlignment="Stretch" |
<ContentPresenter Name="PART_HeaderPresenter" |
||||
KeyboardNavigation.TabNavigation="Continue" /> |
Content="{TemplateBinding Header}" |
||||
</Border> |
VerticalAlignment="Center" |
||||
</ControlTemplate> |
HorizontalAlignment="Stretch" |
||||
</Setter> |
RecognizesAccessKey="True" |
||||
</Style> |
Margin="{TemplateBinding Padding}"/> |
||||
|
<Popup Name="PART_Popup" |
||||
|
WindowManagerAddShadowHint="False" |
||||
|
MinWidth="{Binding Bounds.Width, RelativeSource={RelativeSource TemplatedParent}}" |
||||
|
IsLightDismissEnabled="True" |
||||
|
IsOpen="{TemplateBinding IsSubMenuOpen, Mode=TwoWay}" |
||||
|
OverlayInputPassThroughElement="{Binding $parent[Menu]}"> |
||||
|
<Border Background="{DynamicResource MenuFlyoutPresenterBackground}" |
||||
|
BorderBrush="{DynamicResource MenuFlyoutPresenterBorderBrush}" |
||||
|
BorderThickness="{DynamicResource MenuFlyoutPresenterBorderThemeThickness}" |
||||
|
Padding="{DynamicResource MenuFlyoutPresenterThemePadding}" |
||||
|
MaxWidth="{DynamicResource FlyoutThemeMaxWidth}" |
||||
|
MinHeight="{DynamicResource MenuFlyoutThemeMinHeight}" |
||||
|
HorizontalAlignment="Stretch" |
||||
|
CornerRadius="{DynamicResource OverlayCornerRadius}"> |
||||
|
<ScrollViewer Classes="menuscroller"> |
||||
|
<ItemsPresenter Name="PART_ItemsPresenter" |
||||
|
Items="{TemplateBinding Items}" |
||||
|
ItemsPanel="{TemplateBinding ItemsPanel}" |
||||
|
ItemTemplate="{TemplateBinding ItemTemplate}" |
||||
|
Margin="{DynamicResource MenuFlyoutScrollerMargin}" |
||||
|
Grid.IsSharedSizeScope="True" /> |
||||
|
</ScrollViewer> |
||||
|
</Border> |
||||
|
</Popup> |
||||
|
</Panel> |
||||
|
</Border> |
||||
|
</ControlTemplate> |
||||
|
</Setter> |
||||
|
|
||||
|
<Style Selector="^:selected"> |
||||
|
<Style Selector="^ /template/ Border#PART_LayoutRoot"> |
||||
|
<Setter Property="Background" Value="{DynamicResource MenuFlyoutItemBackgroundPointerOver}" /> |
||||
|
</Style> |
||||
|
<Style Selector="^ /template/ ContentPresenter#PART_HeaderPresenter"> |
||||
|
<Setter Property="Foreground" Value="{DynamicResource MenuFlyoutItemForegroundPointerOver}" /> |
||||
|
</Style> |
||||
|
</Style> |
||||
|
|
||||
|
<!-- Listen for PART_LayoutRoot:pointerover, so it will not be triggered when subitem is pressed --> |
||||
|
<Style Selector="^:pressed /template/ Border#PART_LayoutRoot:pointerover"> |
||||
|
<Setter Property="Background" Value="{DynamicResource MenuFlyoutItemBackgroundPressed}" /> |
||||
|
<Style Selector="^ ContentPresenter#PART_HeaderPresenter"> |
||||
|
<Setter Property="Foreground" Value="{DynamicResource MenuFlyoutItemForegroundPressed}" /> |
||||
|
</Style> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^:disabled"> |
||||
|
<Style Selector="^ /template/ Border#PART_LayoutRoot"> |
||||
|
<Setter Property="Background" Value="{DynamicResource MenuFlyoutItemBackgroundDisabled}" /> |
||||
|
</Style> |
||||
|
<Style Selector="^ /template/ ContentPresenter#PART_HeaderPresenter"> |
||||
|
<Setter Property="Foreground" Value="{DynamicResource MenuFlyoutItemForegroundDisabled}" /> |
||||
|
</Style> |
||||
|
</Style> |
||||
|
</ControlTheme> |
||||
|
|
||||
|
<ControlTheme x:Key="{x:Type Menu}" TargetType="Menu"> |
||||
|
<Setter Property="Background" Value="Transparent" /> |
||||
|
<Setter Property="Height" Value="{DynamicResource MenuBarHeight}" /> |
||||
|
<Setter Property="ItemContainerTheme" Value="{StaticResource FluentTopLevelMenuItem}"/> |
||||
|
<Setter Property="Template"> |
||||
|
<ControlTemplate> |
||||
|
<Border Background="{TemplateBinding Background}" |
||||
|
BorderBrush="{TemplateBinding BorderBrush}" |
||||
|
BorderThickness="{TemplateBinding BorderThickness}" |
||||
|
CornerRadius="{TemplateBinding CornerRadius}" |
||||
|
HorizontalAlignment="Stretch" |
||||
|
Padding="{TemplateBinding Padding}"> |
||||
|
<ItemsPresenter Name="PART_ItemsPresenter" |
||||
|
Items="{TemplateBinding Items}" |
||||
|
ItemsPanel="{TemplateBinding ItemsPanel}" |
||||
|
ItemTemplate="{TemplateBinding ItemTemplate}" |
||||
|
VerticalAlignment="Stretch" |
||||
|
KeyboardNavigation.TabNavigation="Continue" /> |
||||
|
</Border> |
||||
|
</ControlTemplate> |
||||
|
</Setter> |
||||
|
</ControlTheme> |
||||
|
</ResourceDictionary> |
||||
|
|||||
@ -0,0 +1,98 @@ |
|||||
|
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
||||
|
xmlns:converters="clr-namespace:Avalonia.Controls.Converters;assembly=Avalonia.Controls"> |
||||
|
|
||||
|
<Design.PreviewWith> |
||||
|
<ScrollViewer Theme="{DynamicResource FluentMenuScrollViewer}" Width="200" Height="200"> |
||||
|
<StackPanel Spacing="20"> |
||||
|
<TextBlock>Item 1</TextBlock> |
||||
|
<TextBlock>Item 2</TextBlock> |
||||
|
<TextBlock>Item 3</TextBlock> |
||||
|
<TextBlock>Item 4</TextBlock> |
||||
|
<TextBlock>Item 5</TextBlock> |
||||
|
<TextBlock>Item 6</TextBlock> |
||||
|
<TextBlock>Item 7</TextBlock> |
||||
|
<TextBlock>Item 8</TextBlock> |
||||
|
<TextBlock>Item 9</TextBlock> |
||||
|
</StackPanel> |
||||
|
</ScrollViewer> |
||||
|
</Design.PreviewWith> |
||||
|
|
||||
|
<ControlTheme x:Key="FluentMenuScrollViewer" TargetType="ScrollViewer"> |
||||
|
<Setter Property="Background" Value="Transparent" /> |
||||
|
<Setter Property="Template"> |
||||
|
<ControlTemplate> |
||||
|
<DockPanel> |
||||
|
<RepeatButton DockPanel.Dock="Top" |
||||
|
BorderThickness="0" |
||||
|
Background="Transparent" |
||||
|
HorizontalAlignment="Stretch" |
||||
|
HorizontalContentAlignment="Center" |
||||
|
RenderTransform="{x:Null}" |
||||
|
Command="{Binding LineUp, RelativeSource={RelativeSource TemplatedParent}}"> |
||||
|
<RepeatButton.IsVisible> |
||||
|
<MultiBinding Converter="{x:Static converters:MenuScrollingVisibilityConverter.Instance}" |
||||
|
ConverterParameter="0"> |
||||
|
<Binding RelativeSource="{RelativeSource TemplatedParent}" Path="VerticalScrollBarVisibility" /> |
||||
|
<Binding RelativeSource="{RelativeSource TemplatedParent}" Path="Offset.Y" /> |
||||
|
<Binding RelativeSource="{RelativeSource TemplatedParent}" Path="Extent.Height" /> |
||||
|
<Binding RelativeSource="{RelativeSource TemplatedParent}" Path="Viewport.Height" /> |
||||
|
</MultiBinding> |
||||
|
</RepeatButton.IsVisible> |
||||
|
<Viewbox Width="{DynamicResource ScrollBarButtonArrowIconFontSize}" |
||||
|
Height="{DynamicResource ScrollBarButtonArrowIconFontSize}"> |
||||
|
<Path VerticalAlignment="Center" |
||||
|
HorizontalAlignment="Center" |
||||
|
Data="M 19.091797 14.970703 L 10 5.888672 L 0.908203 14.970703 L 0.029297 14.091797 L 10 4.111328 L 19.970703 14.091797 Z" |
||||
|
Fill="{DynamicResource ScrollBarButtonArrowForeground}" |
||||
|
Width="20" |
||||
|
Height="20" /> |
||||
|
</Viewbox> |
||||
|
</RepeatButton> |
||||
|
<RepeatButton DockPanel.Dock="Bottom" |
||||
|
BorderThickness="0" |
||||
|
Background="Transparent" |
||||
|
HorizontalAlignment="Stretch" |
||||
|
HorizontalContentAlignment="Center" |
||||
|
RenderTransform="{x:Null}" |
||||
|
Command="{Binding LineDown, RelativeSource={RelativeSource TemplatedParent}}"> |
||||
|
<RepeatButton.IsVisible> |
||||
|
<MultiBinding Converter="{x:Static converters:MenuScrollingVisibilityConverter.Instance}" |
||||
|
ConverterParameter="100"> |
||||
|
<Binding RelativeSource="{RelativeSource TemplatedParent}" Path="VerticalScrollBarVisibility" /> |
||||
|
<Binding RelativeSource="{RelativeSource TemplatedParent}" Path="Offset.Y" /> |
||||
|
<Binding RelativeSource="{RelativeSource TemplatedParent}" Path="Extent.Height" /> |
||||
|
<Binding RelativeSource="{RelativeSource TemplatedParent}" Path="Viewport.Height" /> |
||||
|
</MultiBinding> |
||||
|
</RepeatButton.IsVisible> |
||||
|
<Viewbox Width="{DynamicResource ScrollBarButtonArrowIconFontSize}" |
||||
|
Height="{DynamicResource ScrollBarButtonArrowIconFontSize}"> |
||||
|
<Path VerticalAlignment="Center" |
||||
|
HorizontalAlignment="Center" |
||||
|
Data="M 18.935547 4.560547 L 19.814453 5.439453 L 10 15.253906 L 0.185547 5.439453 L 1.064453 4.560547 L 10 13.496094 Z" |
||||
|
Fill="{DynamicResource ScrollBarButtonArrowForeground}" |
||||
|
Width="20" |
||||
|
Height="20" /> |
||||
|
</Viewbox> |
||||
|
</RepeatButton> |
||||
|
<ScrollContentPresenter Name="PART_ContentPresenter" |
||||
|
CanHorizontallyScroll="{TemplateBinding CanHorizontallyScroll}" |
||||
|
CanVerticallyScroll="{TemplateBinding CanVerticallyScroll}" |
||||
|
Content="{TemplateBinding Content}" |
||||
|
Extent="{TemplateBinding Extent, Mode=TwoWay}" |
||||
|
Margin="{TemplateBinding Padding}" |
||||
|
Offset="{TemplateBinding Offset, Mode=TwoWay}" |
||||
|
Viewport="{TemplateBinding Viewport, Mode=TwoWay}"> |
||||
|
<ScrollContentPresenter.GestureRecognizers> |
||||
|
<ScrollGestureRecognizer CanHorizontallyScroll="{TemplateBinding CanHorizontallyScroll}" |
||||
|
CanVerticallyScroll="{TemplateBinding CanVerticallyScroll}" /> |
||||
|
</ScrollContentPresenter.GestureRecognizers> |
||||
|
</ScrollContentPresenter> |
||||
|
</DockPanel> |
||||
|
</ControlTemplate> |
||||
|
</Setter> |
||||
|
<Style Selector="^ /template/ RepeatButton:pointerover > Viewbox > Path"> |
||||
|
<Setter Property="Fill" Value="{DynamicResource ScrollBarButtonArrowForegroundPointerOver}" /> |
||||
|
</Style> |
||||
|
</ControlTheme> |
||||
|
</ResourceDictionary> |
||||
@ -1,31 +1,30 @@ |
|||||
<Style xmlns="https://github.com/avaloniaui" |
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
||||
xmlns:local="clr-namespace:Avalonia.Themes.Fluent" |
xmlns:local="clr-namespace:Avalonia.Themes.Fluent" |
||||
x:CompileBindings="True" |
x:CompileBindings="True"> |
||||
Selector="NativeMenuBar"> |
<local:InverseBooleanValueConverter x:Key="AvaloniaThemesFluentNativeMenuBarInverseBooleanValueConverter" Default="True"/> |
||||
<Style.Resources> |
<local:IBitmapToImageConverter x:Key="AvaloniaThemesFluentNativeMenuBarIBitmapToImageConverter"/> |
||||
<local:InverseBooleanValueConverter x:Key="AvaloniaThemesFluentNativeMenuBarInverseBooleanValueConverter" Default="True"/> |
<ControlTheme x:Key="{x:Type NativeMenuBar}" TargetType="NativeMenuBar"> |
||||
<local:IBitmapToImageConverter x:Key="AvaloniaThemesFluentNativeMenuBarIBitmapToImageConverter"/> |
<Setter Property="Template"> |
||||
</Style.Resources> |
<ControlTemplate> |
||||
<Setter Property="Template"> |
<Menu |
||||
<ControlTemplate> |
IsVisible="{Binding $parent[TopLevel].(NativeMenu.IsNativeMenuExported), Converter={StaticResource AvaloniaThemesFluentNativeMenuBarInverseBooleanValueConverter}}" |
||||
<Menu |
Items="{Binding $parent[TopLevel].(NativeMenu.Menu).Items}"> |
||||
IsVisible="{Binding $parent[TopLevel].(NativeMenu.IsNativeMenuExported), Converter={StaticResource AvaloniaThemesFluentNativeMenuBarInverseBooleanValueConverter}}" |
<Menu.Styles> |
||||
Items="{Binding $parent[TopLevel].(NativeMenu.Menu).Items}"> |
<Style x:CompileBindings="False" Selector="MenuItem"> |
||||
<Menu.Styles> |
<Setter Property="Header" Value="{Binding Header}"/> |
||||
<Style x:CompileBindings="False" Selector="MenuItem"> |
<Setter Property="IsEnabled" Value="{Binding IsEnabled}"/> |
||||
<Setter Property="Header" Value="{Binding Header}"/> |
<Setter Property="InputGesture" Value="{Binding Gesture}"/> |
||||
<Setter Property="IsEnabled" Value="{Binding IsEnabled}"/> |
<Setter Property="Items" Value="{Binding Menu.Items}"/> |
||||
<Setter Property="InputGesture" Value="{Binding Gesture}"/> |
<Setter Property="Command" Value="{Binding Command}"/> |
||||
<Setter Property="Items" Value="{Binding Menu.Items}"/> |
<Setter Property="CommandParameter" Value="{Binding CommandParameter}"/> |
||||
<Setter Property="Command" Value="{Binding Command}"/> |
<Setter Property="(NativeMenuBar.EnableMenuItemClickForwarding)" Value="True"/> |
||||
<Setter Property="CommandParameter" Value="{Binding CommandParameter}"/> |
<!--NativeMenuItem is IBitmap and MenuItem is Image--> |
||||
<Setter Property="(NativeMenuBar.EnableMenuItemClickForwarding)" Value="True"/> |
<Setter Property="Icon" Value="{Binding Icon , Converter={StaticResource AvaloniaThemesFluentNativeMenuBarIBitmapToImageConverter}}"/> |
||||
<!--NativeMenuItem is IBitmap and MenuItem is Image--> |
</Style> |
||||
<Setter Property="Icon" Value="{Binding Icon , Converter={StaticResource AvaloniaThemesFluentNativeMenuBarIBitmapToImageConverter}}"/> |
</Menu.Styles> |
||||
</Style> |
</Menu> |
||||
</Menu.Styles> |
</ControlTemplate> |
||||
</Menu> |
</Setter> |
||||
</ControlTemplate> |
</ControlTheme> |
||||
</Setter> |
</ResourceDictionary> |
||||
</Style> |
|
||||
|
|||||
@ -1,20 +1,23 @@ |
|||||
<Style xmlns="https://github.com/avaloniaui" Selector="OverlayPopupHost"> |
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
<Setter Property="Foreground" Value="{DynamicResource SystemControlForegroundBaseHighBrush}"/> |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
||||
<Setter Property="FontSize" Value="{DynamicResource ControlContentThemeFontSize}"/> |
<ControlTheme x:Key="{x:Type OverlayPopupHost}" TargetType="OverlayPopupHost"> |
||||
<Setter Property="FontFamily" Value="{DynamicResource ContentControlThemeFontFamily}" /> |
<Setter Property="Foreground" Value="{DynamicResource SystemControlForegroundBaseHighBrush}"/> |
||||
<Setter Property="FontWeight" Value="400" /> |
<Setter Property="FontSize" Value="{DynamicResource ControlContentThemeFontSize}"/> |
||||
<Setter Property="FontStyle" Value="Normal" /> |
<Setter Property="FontFamily" Value="{DynamicResource ContentControlThemeFontFamily}" /> |
||||
<Setter Property="Template"> |
<Setter Property="FontWeight" Value="400" /> |
||||
<ControlTemplate> |
<Setter Property="FontStyle" Value="Normal" /> |
||||
<LayoutTransformControl LayoutTransform="{TemplateBinding Transform}"> |
<Setter Property="Template"> |
||||
<VisualLayerManager IsPopup="True"> |
<ControlTemplate> |
||||
<ContentPresenter Name="PART_ContentPresenter" |
<LayoutTransformControl LayoutTransform="{TemplateBinding Transform}"> |
||||
Background="{TemplateBinding Background}" |
<VisualLayerManager IsPopup="True"> |
||||
ContentTemplate="{TemplateBinding ContentTemplate}" |
<ContentPresenter Name="PART_ContentPresenter" |
||||
Content="{TemplateBinding Content}" |
Background="{TemplateBinding Background}" |
||||
Padding="{TemplateBinding Padding}"/> |
ContentTemplate="{TemplateBinding ContentTemplate}" |
||||
</VisualLayerManager> |
Content="{TemplateBinding Content}" |
||||
</LayoutTransformControl> |
Padding="{TemplateBinding Padding}"/> |
||||
</ControlTemplate> |
</VisualLayerManager> |
||||
</Setter> |
</LayoutTransformControl> |
||||
</Style> |
</ControlTemplate> |
||||
|
</Setter> |
||||
|
</ControlTheme> |
||||
|
</ResourceDictionary> |
||||
|
|||||
@ -1,302 +1,283 @@ |
|||||
<Styles xmlns="https://github.com/avaloniaui" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
||||
<Style Selector="ScrollBar"> |
<Design.PreviewWith> |
||||
<Setter Property="MinWidth" Value="{DynamicResource ScrollBarSize}" /> |
<Border Padding="20"> |
||||
<Setter Property="MinHeight" Value="{DynamicResource ScrollBarSize}" /> |
<StackPanel Orientation="Horizontal" Spacing="20"> |
||||
<Setter Property="Background" Value="{DynamicResource ScrollBarBackground}" /> |
<StackPanel Spacing="20"> |
||||
<Setter Property="Foreground" Value="{DynamicResource ScrollBarForeground}" /> |
<ScrollBar Orientation="Horizontal" AllowAutoHide="False" VerticalAlignment="Center" Width="100"/> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource ScrollBarBorderBrush}" /> |
<ScrollBar Orientation="Horizontal" AllowAutoHide="False" VerticalAlignment="Center" Width="100" IsEnabled="False"/> |
||||
</Style> |
<ScrollBar Orientation="Horizontal" AllowAutoHide="True" VerticalAlignment="Center" Width="100"/> |
||||
|
<ScrollBar Orientation="Horizontal" AllowAutoHide="True" VerticalAlignment="Center" Width="100" IsEnabled="False"/> |
||||
<Style Selector="ScrollBar:vertical"> |
</StackPanel> |
||||
<Setter Property="Template"> |
<ScrollBar Orientation="Vertical" AllowAutoHide="False" HorizontalAlignment="Center" Height="100"/> |
||||
<ControlTemplate> |
<ScrollBar Orientation="Vertical" AllowAutoHide="False" HorizontalAlignment="Center" Height="100" IsEnabled="False"/> |
||||
<Grid x:Name="Root"> |
<ScrollBar Orientation="Vertical" AllowAutoHide="True" HorizontalAlignment="Center" Height="100"/> |
||||
|
<ScrollBar Orientation="Vertical" AllowAutoHide="True" HorizontalAlignment="Center" Height="100" IsEnabled="False"/> |
||||
<Border x:Name="VerticalRoot" |
</StackPanel> |
||||
Background="{TemplateBinding Background}" |
</Border> |
||||
BorderBrush="{TemplateBinding BorderBrush}"> |
</Design.PreviewWith> |
||||
<Grid RowDefinitions="Auto,*,Auto"> |
|
||||
|
<ControlTheme x:Key="FluentScrollBarThumb" TargetType="Thumb"> |
||||
<Rectangle x:Name="TrackRect" Grid.RowSpan="3" Margin="0" /> |
<Setter Property="Background" Value="{DynamicResource ScrollBarPanningThumbBackground}"/> |
||||
|
|
||||
<RepeatButton Name="PART_LineUpButton" |
|
||||
HorizontalAlignment="Center" |
|
||||
Classes="line up" |
|
||||
Grid.Row="0" |
|
||||
Focusable="False" |
|
||||
MinWidth="{DynamicResource ScrollBarSize}" |
|
||||
Height="{DynamicResource ScrollBarSize}" /> |
|
||||
|
|
||||
<Track Grid.Row="1" |
|
||||
Minimum="{TemplateBinding Minimum}" |
|
||||
Maximum="{TemplateBinding Maximum}" |
|
||||
Value="{TemplateBinding Value, Mode=TwoWay}" |
|
||||
ViewportSize="{TemplateBinding ViewportSize}" |
|
||||
Orientation="{TemplateBinding Orientation}" |
|
||||
IsDirectionReversed="True"> |
|
||||
<Track.DecreaseButton> |
|
||||
<RepeatButton Name="PART_PageUpButton" |
|
||||
Classes="largeIncrease" |
|
||||
Focusable="False" /> |
|
||||
</Track.DecreaseButton> |
|
||||
<Track.IncreaseButton> |
|
||||
<RepeatButton Name="PART_PageDownButton" |
|
||||
Classes="largeIncrease" |
|
||||
Focusable="False" /> |
|
||||
</Track.IncreaseButton> |
|
||||
<Thumb Classes="thumb" |
|
||||
Opacity="1" |
|
||||
Width="{DynamicResource ScrollBarSize}" |
|
||||
MinHeight="{DynamicResource ScrollBarSize}" |
|
||||
RenderTransformOrigin="100%,50%" /> |
|
||||
</Track> |
|
||||
|
|
||||
<RepeatButton Name="PART_LineDownButton" |
|
||||
HorizontalAlignment="Center" |
|
||||
Classes="line down" |
|
||||
Grid.Row="2" |
|
||||
Focusable="False" |
|
||||
MinWidth="{DynamicResource ScrollBarSize}" |
|
||||
Height="{DynamicResource ScrollBarSize}" /> |
|
||||
|
|
||||
</Grid> |
|
||||
</Border> |
|
||||
|
|
||||
</Grid> |
|
||||
</ControlTemplate> |
|
||||
</Setter> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="ScrollBar:horizontal"> |
|
||||
<Setter Property="Template"> |
|
||||
<ControlTemplate> |
|
||||
<Grid x:Name="Root"> |
|
||||
|
|
||||
<Border x:Name="HorizontalRoot" |
|
||||
Background="{TemplateBinding Background}" |
|
||||
BorderBrush="{TemplateBinding BorderBrush}"> |
|
||||
<Grid ColumnDefinitions="Auto,*,Auto"> |
|
||||
|
|
||||
<Rectangle x:Name="TrackRect" Grid.ColumnSpan="3" Margin="0" /> |
|
||||
|
|
||||
<RepeatButton Name="PART_LineUpButton" |
|
||||
VerticalAlignment="Center" |
|
||||
Classes="line up" |
|
||||
Grid.Column="0" |
|
||||
Focusable="False" |
|
||||
MinHeight="{DynamicResource ScrollBarSize}" |
|
||||
Width="{DynamicResource ScrollBarSize}" /> |
|
||||
|
|
||||
<Track Grid.Column="1" |
|
||||
Minimum="{TemplateBinding Minimum}" |
|
||||
Maximum="{TemplateBinding Maximum}" |
|
||||
Value="{TemplateBinding Value, Mode=TwoWay}" |
|
||||
ViewportSize="{TemplateBinding ViewportSize}" |
|
||||
Orientation="{TemplateBinding Orientation}"> |
|
||||
<Track.DecreaseButton> |
|
||||
<RepeatButton Name="PART_PageUpButton" |
|
||||
Classes="largeIncrease" |
|
||||
Focusable="False" /> |
|
||||
</Track.DecreaseButton> |
|
||||
<Track.IncreaseButton> |
|
||||
<RepeatButton Name="PART_PageDownButton" |
|
||||
Classes="largeIncrease" |
|
||||
Focusable="False" /> |
|
||||
</Track.IncreaseButton> |
|
||||
<Thumb Classes="thumb" |
|
||||
Opacity="1" |
|
||||
Height="{DynamicResource ScrollBarSize}" |
|
||||
MinWidth="{DynamicResource ScrollBarSize}" |
|
||||
RenderTransformOrigin="50%,100%" /> |
|
||||
</Track> |
|
||||
|
|
||||
<RepeatButton Name="PART_LineDownButton" |
|
||||
VerticalAlignment="Center" |
|
||||
Classes="line down" |
|
||||
Grid.Column="2" |
|
||||
Focusable="False" |
|
||||
MinHeight="{DynamicResource ScrollBarSize}" |
|
||||
Width="{DynamicResource ScrollBarSize}" /> |
|
||||
|
|
||||
</Grid> |
|
||||
</Border> |
|
||||
|
|
||||
</Grid> |
|
||||
</ControlTemplate> |
|
||||
</Setter> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="ScrollBar[IsExpanded=true] /template/ Grid#Root"> |
|
||||
<Setter Property="Background" Value="{DynamicResource ScrollBarBackgroundPointerOver}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="ScrollBar /template/ Thumb.thumb"> |
|
||||
<Setter Property="Background" Value="{DynamicResource ScrollBarPanningThumbBackground}" /> |
|
||||
<Setter Property="Template"> |
<Setter Property="Template"> |
||||
<Setter.Value> |
<Setter.Value> |
||||
<ControlTemplate> |
<ControlTemplate> |
||||
<Border x:Name="ThumbVisual" Background="{TemplateBinding Background}" /> |
<Border Background="{TemplateBinding Background}" |
||||
|
CornerRadius="{TemplateBinding CornerRadius}"/> |
||||
</ControlTemplate> |
</ControlTemplate> |
||||
</Setter.Value> |
</Setter.Value> |
||||
</Setter> |
</Setter> |
||||
<Setter Property="Transitions"> |
<Setter Property="Transitions"> |
||||
<Transitions> |
<Transitions> |
||||
|
<CornerRadiusTransition Property="CornerRadius" Duration="0:0:0.1" /> |
||||
<TransformOperationsTransition Property="RenderTransform" Duration="0:0:0.1" /> |
<TransformOperationsTransition Property="RenderTransform" Duration="0:0:0.1" /> |
||||
</Transitions> |
</Transitions> |
||||
</Setter> |
</Setter> |
||||
</Style> |
|
||||
|
|
||||
<Style Selector="ScrollBar:vertical /template/ Thumb.thumb"> |
<Style Selector="^:pointerover /template/ Border"> |
||||
<Setter Property="RenderTransform" Value="{DynamicResource VerticalSmallScrollThumbScaleTransform}" /> |
<Setter Property="Background" Value="{DynamicResource ScrollBarThumbFillPointerOver}" /> |
||||
</Style> |
</Style> |
||||
|
<Style Selector="^:pressed /template/ Border"> |
||||
<Style Selector="ScrollBar:horizontal /template/ Thumb.thumb"> |
<Setter Property="Background" Value="{DynamicResource ScrollBarThumbFillPressed}" /> |
||||
<Setter Property="RenderTransform" Value="{DynamicResource HorizontalSmallScrollThumbScaleTransform}" /> |
</Style> |
||||
</Style> |
<Style Selector="^:disabled /template/ Border"> |
||||
|
<Setter Property="Background" Value="{DynamicResource ScrollBarThumbFillDisabled}" /> |
||||
<Style Selector="ScrollBar[IsExpanded=true] /template/ Thumb.thumb"> |
</Style> |
||||
<Setter Property="RenderTransform" Value="none" /> |
</ControlTheme> |
||||
<Setter Property="Background" Value="{DynamicResource ScrollBarThumbBackgroundColor}" /> |
|
||||
</Style> |
<ControlTheme x:Key="FluentScrollBarPageButton" TargetType="RepeatButton"> |
||||
|
<Setter Property="Background" Value="Transparent" /> |
||||
<Style Selector="ScrollBar /template/ Thumb.thumb /template/ Border#ThumbVisual"> |
<Setter Property="VerticalAlignment" Value="Stretch" /> |
||||
<Setter Property="CornerRadius" Value="{DynamicResource ControlCornerRadius}" /> |
<Setter Property="HorizontalAlignment" Value="Stretch" /> |
||||
<Setter Property="Transitions"> |
<Setter Property="Opacity" Value="0" /> |
||||
<Transitions> |
<Setter Property="Template"> |
||||
<CornerRadiusTransition Property="CornerRadius" Duration="0:0:0.1" /> |
<ControlTemplate> |
||||
</Transitions> |
<Border Background="{TemplateBinding Background}" /> |
||||
|
</ControlTemplate> |
||||
</Setter> |
</Setter> |
||||
</Style> |
</ControlTheme> |
||||
|
|
||||
<Style Selector="ScrollBar[IsExpanded=true] /template/ Thumb.thumb /template/ Border#ThumbVisual"> |
|
||||
<Setter Property="CornerRadius" Value="0" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="ScrollBar /template/ Thumb.thumb:pointerover"> |
|
||||
<Setter Property="Background" Value="{DynamicResource ScrollBarThumbFillPointerOver}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="ScrollBar /template/ Thumb.thumb:pressed"> |
<ControlTheme x:Key="FluentScrollBarLineButton" TargetType="RepeatButton"> |
||||
<Setter Property="Background" Value="{DynamicResource ScrollBarThumbFillPressed}" /> |
<Setter Property="Opacity" Value="0" /> |
||||
</Style> |
<Setter Property="TextElement.Foreground" Value="{DynamicResource ScrollBarButtonArrowForeground}"/> |
||||
|
|
||||
<Style Selector="ScrollBar /template/ Thumb.thumb:disabled"> |
|
||||
<Setter Property="Background" Value="{DynamicResource ScrollBarThumbFillDisabled}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="ScrollBar /template/ RepeatButton.line"> |
|
||||
<Setter Property="Template"> |
<Setter Property="Template"> |
||||
<ControlTemplate> |
<ControlTemplate> |
||||
<Border x:Name="Root"> |
<ContentPresenter Background="{DynamicResource ScrollBarButtonBackground}" |
||||
<Viewbox Width="{DynamicResource ScrollBarButtonArrowIconFontSize}" |
BorderBrush="{DynamicResource ScrollBarButtonBorderBrush}" |
||||
Height="{DynamicResource ScrollBarButtonArrowIconFontSize}"> |
Content="{TemplateBinding Content}"/> |
||||
<Path x:Name="Arrow" |
|
||||
VerticalAlignment="Center" |
|
||||
HorizontalAlignment="Center" |
|
||||
Width="20" Height="20" /> |
|
||||
</Viewbox> |
|
||||
</Border> |
|
||||
</ControlTemplate> |
</ControlTemplate> |
||||
</Setter> |
</Setter> |
||||
<Setter Property="Opacity" Value="0" /> |
|
||||
<Setter Property="Transitions"> |
<Setter Property="Transitions"> |
||||
<Transitions> |
<Transitions> |
||||
<DoubleTransition Property="Opacity" Duration="0:0:0.1" /> |
<DoubleTransition Property="Opacity" Duration="0:0:0.1" /> |
||||
</Transitions> |
</Transitions> |
||||
</Setter> |
</Setter> |
||||
</Style> |
|
||||
|
|
||||
<Style Selector="ScrollBar /template/ RepeatButton.line /template/ Border#Root" > |
|
||||
<Setter Property="Background" Value="{DynamicResource ScrollBarButtonBackground}" /> |
|
||||
<Setter Property="BorderBrush" Value="{DynamicResource ScrollBarButtonBorderBrush}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="ScrollBar /template/ RepeatButton.line:pointerover /template/ Border#Root" > |
<Style Selector="^:pointerover"> |
||||
<Setter Property="Background" Value="{DynamicResource ScrollBarButtonBackgroundPointerOver}" /> |
<Setter Property="TextElement.Foreground" Value="{DynamicResource ScrollBarButtonArrowForegroundPointerOver}"/> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource ScrollBarButtonBorderBrushPointerOver}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="ScrollBar /template/ RepeatButton.line:pressed /template/ Border#Root" > |
<Style Selector="^ /template/ ContentPresenter" > |
||||
<Setter Property="Background" Value="{DynamicResource ScrollBarButtonBackgroundPressed}" /> |
<Setter Property="Background" Value="{DynamicResource ScrollBarButtonBackgroundPointerOver}" /> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource ScrollBarButtonBorderBrushPressed}" /> |
<Setter Property="BorderBrush" Value="{DynamicResource ScrollBarButtonBorderBrushPointerOver}" /> |
||||
</Style> |
</Style> |
||||
|
</Style> |
||||
|
|
||||
<Style Selector="ScrollBar /template/ RepeatButton.line:disabled /template/ Border#Root" > |
<Style Selector="^:pressed"> |
||||
<Setter Property="Background" Value="{DynamicResource ScrollBarButtonBackgroundPressed}" /> |
<Setter Property="TextElement.Foreground" Value="{DynamicResource ScrollBarButtonArrowForegroundPressed}"/> |
||||
<Setter Property="BorderBrush" Value="{DynamicResource ScrollBarButtonBorderBrushDisabled}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="ScrollBar /template/ RepeatButton.line /template/ Path#Arrow" > |
<Style Selector="^ /template/ ContentPresenter" > |
||||
<Setter Property="Fill" Value="{DynamicResource ScrollBarButtonArrowForeground}" /> |
<Setter Property="Background" Value="{DynamicResource ScrollBarButtonBackgroundPressed}" /> |
||||
</Style> |
<Setter Property="BorderBrush" Value="{DynamicResource ScrollBarButtonBorderBrushPressed}" /> |
||||
|
</Style> |
||||
|
</Style> |
||||
|
|
||||
<Style Selector="ScrollBar /template/ RepeatButton.line:pointerover /template/ Path#Arrow" > |
<Style Selector="^:disabled"> |
||||
<Setter Property="Fill" Value="{DynamicResource ScrollBarButtonArrowForegroundPointerOver}" /> |
<Setter Property="TextElement.Foreground" Value="{DynamicResource ScrollBarButtonArrowForegroundDisabled}"/> |
||||
</Style> |
|
||||
|
|
||||
<Style Selector="ScrollBar /template/ RepeatButton.line:pressed /template/ Path#Arrow" > |
<Style Selector="^ /template/ ContentPresenter" > |
||||
<Setter Property="Fill" Value="{DynamicResource ScrollBarButtonArrowForegroundPressed}" /> |
<Setter Property="Background" Value="{DynamicResource ScrollBarButtonBackgroundDisabled}" /> |
||||
</Style> |
<Setter Property="BorderBrush" Value="{DynamicResource ScrollBarButtonBorderBrushDisabled}" /> |
||||
|
</Style> |
||||
|
</Style> |
||||
|
</ControlTheme> |
||||
|
|
||||
<Style Selector="ScrollBar /template/ RepeatButton.line:disabled /template/ Path#Arrow" > |
<ControlTheme x:Key="{x:Type ScrollBar}" TargetType="ScrollBar"> |
||||
<Setter Property="Fill" Value="{DynamicResource ScrollBarButtonArrowForegroundDisabled}" /> |
<Setter Property="MinWidth" Value="{DynamicResource ScrollBarSize}" /> |
||||
</Style> |
<Setter Property="MinHeight" Value="{DynamicResource ScrollBarSize}" /> |
||||
|
<Setter Property="Background" Value="{DynamicResource ScrollBarBackground}" /> |
||||
<Style Selector="ScrollBar[IsExpanded=true] /template/ RepeatButton.line"> |
<Setter Property="Foreground" Value="{DynamicResource ScrollBarForeground}" /> |
||||
<Setter Property="Opacity" Value="1" /> |
<Setter Property="BorderBrush" Value="{DynamicResource ScrollBarBorderBrush}" /> |
||||
</Style> |
|
||||
|
|
||||
<Style Selector="ScrollBar:vertical /template/ RepeatButton.line.up /template/ Path"> |
|
||||
<Setter Property="Data" |
|
||||
Value="M 19.091797 14.970703 L 10 5.888672 L 0.908203 14.970703 L 0.029297 14.091797 L 10 4.111328 L 19.970703 14.091797 Z" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="ScrollBar:vertical /template/ RepeatButton.line.down /template/ Path"> |
|
||||
<Setter Property="Data" |
|
||||
Value="M 18.935547 4.560547 L 19.814453 5.439453 L 10 15.253906 L 0.185547 5.439453 L 1.064453 4.560547 L 10 13.496094 Z" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="ScrollBar:horizontal /template/ RepeatButton.line.up /template/ Path"> |
|
||||
<Setter Property="Data" Value="M 14.091797 19.970703 L 4.111328 10 L 14.091797 0.029297 L 14.970703 0.908203 L 5.888672 10 L 14.970703 19.091797 Z" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="ScrollBar:horizontal /template/ RepeatButton.line.down /template/ Path"> |
|
||||
<Setter Property="Data" Value="M 5.029297 19.091797 L 14.111328 10 L 5.029297 0.908203 L 5.908203 0.029297 L 15.888672 10 L 5.908203 19.970703 Z" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="ScrollBar /template/ Rectangle#TrackRect"> |
|
||||
<Setter Property="StrokeThickness" Value="{DynamicResource ScrollBarTrackBorderThemeThickness}" /> |
|
||||
<Setter Property="Fill" Value="{DynamicResource ScrollBarTrackFill}" /> |
|
||||
<Setter Property="Stroke" Value="{DynamicResource ScrollBarTrackStroke}" /> |
|
||||
<Setter Property="Opacity" Value="0" /> |
|
||||
<Setter Property="Transitions"> |
|
||||
<Transitions> |
|
||||
<DoubleTransition Property="Opacity" Duration="0:0:0.1" /> |
|
||||
</Transitions> |
|
||||
</Setter> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="ScrollBar[IsExpanded=true] /template/ Rectangle#TrackRect"> |
|
||||
<Setter Property="Fill" Value="{DynamicResource ScrollBarTrackFillPointerOver}" /> |
|
||||
<Setter Property="Stroke" Value="{DynamicResource ScrollBarTrackStrokePointerOver}" /> |
|
||||
<Setter Property="Opacity" Value="1" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="ScrollBar /template/ RepeatButton.largeIncrease"> |
|
||||
<Setter Property="Template"> |
|
||||
<ControlTemplate> |
|
||||
<Border Background="{TemplateBinding Background}" /> |
|
||||
</ControlTemplate> |
|
||||
</Setter> |
|
||||
<Setter Property="Background" Value="Transparent" /> |
|
||||
<Setter Property="VerticalAlignment" Value="Stretch" /> |
|
||||
<Setter Property="HorizontalAlignment" Value="Stretch" /> |
|
||||
<Setter Property="Opacity" Value="0" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="ScrollBar[IsExpanded=true] /template/ RepeatButton.largeIncrease"> |
<Style Selector="^:vertical"> |
||||
<Setter Property="Opacity" Value="1" /> |
<Setter Property="Template"> |
||||
</Style> |
<ControlTemplate> |
||||
|
<Grid x:Name="Root"> |
||||
|
<Border x:Name="VerticalRoot" |
||||
|
Background="{TemplateBinding Background}" |
||||
|
BorderBrush="{TemplateBinding BorderBrush}"> |
||||
|
<Grid RowDefinitions="Auto,*,Auto"> |
||||
|
<Rectangle x:Name="TrackRect" |
||||
|
Fill="{DynamicResource ScrollBarTrackFill}" |
||||
|
Stroke="{DynamicResource ScrollBarTrackStroke}" |
||||
|
StrokeThickness="{DynamicResource ScrollBarTrackBorderThemeThickness}" |
||||
|
Opacity="0" |
||||
|
Grid.RowSpan="3"> |
||||
|
<Rectangle.Transitions> |
||||
|
<Transitions> |
||||
|
<DoubleTransition Property="Opacity" Duration="0:0:0.1" /> |
||||
|
</Transitions> |
||||
|
</Rectangle.Transitions> |
||||
|
</Rectangle> |
||||
|
|
||||
|
<RepeatButton Name="PART_LineUpButton" |
||||
|
HorizontalAlignment="Center" |
||||
|
Theme="{StaticResource FluentScrollBarLineButton}" |
||||
|
Grid.Row="0" |
||||
|
Focusable="False" |
||||
|
MinWidth="{DynamicResource ScrollBarSize}" |
||||
|
Height="{DynamicResource ScrollBarSize}"> |
||||
|
<PathIcon Data="M 19.091797 14.970703 L 10 5.888672 L 0.908203 14.970703 L 0.029297 14.091797 L 10 4.111328 L 19.970703 14.091797 Z" |
||||
|
Width="{DynamicResource ScrollBarButtonArrowIconFontSize}" |
||||
|
Height="{DynamicResource ScrollBarButtonArrowIconFontSize}"/> |
||||
|
</RepeatButton> |
||||
|
|
||||
|
<Track Grid.Row="1" |
||||
|
Minimum="{TemplateBinding Minimum}" |
||||
|
Maximum="{TemplateBinding Maximum}" |
||||
|
Value="{TemplateBinding Value, Mode=TwoWay}" |
||||
|
ViewportSize="{TemplateBinding ViewportSize}" |
||||
|
Orientation="{TemplateBinding Orientation}" |
||||
|
IsDirectionReversed="True"> |
||||
|
<Track.DecreaseButton> |
||||
|
<RepeatButton Name="PART_PageUpButton" |
||||
|
Classes="largeIncrease" |
||||
|
Theme="{StaticResource FluentScrollBarPageButton}" |
||||
|
Focusable="False" /> |
||||
|
</Track.DecreaseButton> |
||||
|
<Track.IncreaseButton> |
||||
|
<RepeatButton Name="PART_PageDownButton" |
||||
|
Classes="largeIncrease" |
||||
|
Theme="{StaticResource FluentScrollBarPageButton}" |
||||
|
Focusable="False" /> |
||||
|
</Track.IncreaseButton> |
||||
|
<Thumb Theme="{StaticResource FluentScrollBarThumb}" |
||||
|
Width="{DynamicResource ScrollBarSize}" |
||||
|
MinHeight="{DynamicResource ScrollBarSize}" |
||||
|
RenderTransform="{DynamicResource VerticalSmallScrollThumbScaleTransform}" |
||||
|
RenderTransformOrigin="100%,50%" /> |
||||
|
</Track> |
||||
|
|
||||
|
<RepeatButton Name="PART_LineDownButton" |
||||
|
HorizontalAlignment="Center" |
||||
|
Theme="{StaticResource FluentScrollBarLineButton}" |
||||
|
Grid.Row="2" |
||||
|
Focusable="False" |
||||
|
MinWidth="{DynamicResource ScrollBarSize}" |
||||
|
Height="{DynamicResource ScrollBarSize}"> |
||||
|
<PathIcon Data="M 18.935547 4.560547 L 19.814453 5.439453 L 10 15.253906 L 0.185547 5.439453 L 1.064453 4.560547 L 10 13.496094 Z" |
||||
|
Width="{DynamicResource ScrollBarButtonArrowIconFontSize}" |
||||
|
Height="{DynamicResource ScrollBarButtonArrowIconFontSize}"/> |
||||
|
</RepeatButton> |
||||
|
</Grid> |
||||
|
</Border> |
||||
|
</Grid> |
||||
|
</ControlTemplate> |
||||
|
</Setter> |
||||
|
</Style> |
||||
|
|
||||
</Styles> |
<Style Selector="^:horizontal"> |
||||
|
<Setter Property="Template"> |
||||
|
<ControlTemplate> |
||||
|
<Grid x:Name="Root"> |
||||
|
<Border x:Name="HorizontalRoot" |
||||
|
Background="{TemplateBinding Background}" |
||||
|
BorderBrush="{TemplateBinding BorderBrush}"> |
||||
|
<Grid ColumnDefinitions="Auto,*,Auto"> |
||||
|
<Rectangle x:Name="TrackRect" |
||||
|
Fill="{DynamicResource ScrollBarTrackFill}" |
||||
|
Stroke="{DynamicResource ScrollBarTrackStroke}" |
||||
|
StrokeThickness="{DynamicResource ScrollBarTrackBorderThemeThickness}" |
||||
|
Opacity="0" |
||||
|
Grid.ColumnSpan="3"> |
||||
|
<Rectangle.Transitions> |
||||
|
<Transitions> |
||||
|
<DoubleTransition Property="Opacity" Duration="0:0:0.1" /> |
||||
|
</Transitions> |
||||
|
</Rectangle.Transitions> |
||||
|
</Rectangle> |
||||
|
|
||||
|
<RepeatButton Name="PART_LineUpButton" |
||||
|
Theme="{StaticResource FluentScrollBarLineButton}" |
||||
|
VerticalAlignment="Center" |
||||
|
Grid.Column="0" |
||||
|
Focusable="False" |
||||
|
MinHeight="{DynamicResource ScrollBarSize}" |
||||
|
Width="{DynamicResource ScrollBarSize}"> |
||||
|
<PathIcon Data="M 14.091797 19.970703 L 4.111328 10 L 14.091797 0.029297 L 14.970703 0.908203 L 5.888672 10 L 14.970703 19.091797 Z" |
||||
|
Width="{DynamicResource ScrollBarButtonArrowIconFontSize}" |
||||
|
Height="{DynamicResource ScrollBarButtonArrowIconFontSize}"/> |
||||
|
</RepeatButton> |
||||
|
|
||||
|
<Track Grid.Column="1" |
||||
|
Minimum="{TemplateBinding Minimum}" |
||||
|
Maximum="{TemplateBinding Maximum}" |
||||
|
Value="{TemplateBinding Value, Mode=TwoWay}" |
||||
|
ViewportSize="{TemplateBinding ViewportSize}" |
||||
|
Orientation="{TemplateBinding Orientation}"> |
||||
|
<Track.DecreaseButton> |
||||
|
<RepeatButton Name="PART_PageUpButton" |
||||
|
Classes="largeIncrease" |
||||
|
Theme="{StaticResource FluentScrollBarPageButton}" |
||||
|
Focusable="False" /> |
||||
|
</Track.DecreaseButton> |
||||
|
<Track.IncreaseButton> |
||||
|
<RepeatButton Name="PART_PageDownButton" |
||||
|
Classes="largeIncrease" |
||||
|
Theme="{StaticResource FluentScrollBarPageButton}" |
||||
|
Focusable="False" /> |
||||
|
</Track.IncreaseButton> |
||||
|
<Thumb Theme="{StaticResource FluentScrollBarThumb}" |
||||
|
Height="{DynamicResource ScrollBarSize}" |
||||
|
MinWidth="{DynamicResource ScrollBarSize}" |
||||
|
RenderTransform="{DynamicResource HorizontalSmallScrollThumbScaleTransform}" |
||||
|
RenderTransformOrigin="50%,100%" /> |
||||
|
</Track> |
||||
|
|
||||
|
<RepeatButton Name="PART_LineDownButton" |
||||
|
Theme="{StaticResource FluentScrollBarLineButton}" |
||||
|
VerticalAlignment="Center" |
||||
|
Grid.Column="2" |
||||
|
Focusable="False" |
||||
|
MinHeight="{DynamicResource ScrollBarSize}" |
||||
|
Width="{DynamicResource ScrollBarSize}"> |
||||
|
<PathIcon Data="M 5.029297 19.091797 L 14.111328 10 L 5.029297 0.908203 L 5.908203 0.029297 L 15.888672 10 L 5.908203 19.970703 Z" |
||||
|
Width="{DynamicResource ScrollBarButtonArrowIconFontSize}" |
||||
|
Height="{DynamicResource ScrollBarButtonArrowIconFontSize}"/> |
||||
|
</RepeatButton> |
||||
|
</Grid> |
||||
|
</Border> |
||||
|
</Grid> |
||||
|
</ControlTemplate> |
||||
|
</Setter> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^[IsExpanded=true]"> |
||||
|
<Style Selector="^ /template/ Grid#Root"> |
||||
|
<Setter Property="Background" Value="{DynamicResource ScrollBarBackgroundPointerOver}" /> |
||||
|
</Style> |
||||
|
<Style Selector="^ /template/ Rectangle#TrackRect"> |
||||
|
<Setter Property="Fill" Value="{DynamicResource ScrollBarTrackFillPointerOver}" /> |
||||
|
<Setter Property="Stroke" Value="{DynamicResource ScrollBarTrackStrokePointerOver}" /> |
||||
|
<Setter Property="Opacity" Value="1" /> |
||||
|
</Style> |
||||
|
<Style Selector="^ /template/ Thumb"> |
||||
|
<Setter Property="Background" Value="{DynamicResource ScrollBarThumbBackgroundColor}" /> |
||||
|
<Setter Property="RenderTransform" Value="none" /> |
||||
|
</Style> |
||||
|
<Style Selector="^ /template/ RepeatButton"> |
||||
|
<Setter Property="Opacity" Value="1" /> |
||||
|
</Style> |
||||
|
</Style> |
||||
|
</ControlTheme> |
||||
|
|
||||
|
</ResourceDictionary> |
||||
|
|||||
@ -1,275 +1,397 @@ |
|||||
<Styles xmlns="https://github.com/avaloniaui" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
||||
|
xmlns:sys="clr-namespace:System;assembly=netstandard"> |
||||
<Design.PreviewWith> |
<Design.PreviewWith> |
||||
<Border Margin="20" Width="200" Height="200"> |
<Border Margin="20" Width="400" Height="600"> |
||||
<DockPanel LastChildFill="True"> |
<DockPanel LastChildFill="True"> |
||||
<StackPanel Spacing="10" DockPanel.Dock="Top"> |
<StackPanel Spacing="10" DockPanel.Dock="Top"> |
||||
<Slider Value="50" /> |
<Slider Value="50" /> |
||||
|
<Slider IsDirectionReversed="True" Value="50" /> |
||||
|
<Slider Value="50" TickPlacement="TopLeft" TickFrequency="10"/> |
||||
|
<Slider Value="50" TickPlacement="BottomRight" TickFrequency="10"/> |
||||
|
<Slider Value="50" TickPlacement="Outside" TickFrequency="10"/> |
||||
<Slider IsEnabled="False" Value="50" /> |
<Slider IsEnabled="False" Value="50" /> |
||||
|
<Slider Value="50"> |
||||
|
<DataValidationErrors.Error> |
||||
|
<sys:Exception> |
||||
|
<x:Arguments> |
||||
|
<x:String>Error</x:String> |
||||
|
</x:Arguments> |
||||
|
</sys:Exception> |
||||
|
</DataValidationErrors.Error> |
||||
|
</Slider> |
||||
</StackPanel> |
</StackPanel> |
||||
<StackPanel Spacing="10" Orientation="Horizontal"> |
<StackPanel Spacing="10" Orientation="Horizontal"> |
||||
<Slider Value="50" Orientation="Vertical" /> |
<Slider Value="50" Orientation="Vertical" /> |
||||
|
<Slider IsDirectionReversed="True" Value="50" Orientation="Vertical" /> |
||||
<Slider IsEnabled="False" Orientation="Vertical" Value="50" /> |
<Slider IsEnabled="False" Orientation="Vertical" Value="50" /> |
||||
|
<Slider Value="50" TickPlacement="TopLeft" TickFrequency="10" Orientation="Vertical" /> |
||||
|
<Slider Value="50" TickPlacement="BottomRight" TickFrequency="10" Orientation="Vertical" /> |
||||
|
<Slider Value="50" TickPlacement="Outside" TickFrequency="10" Orientation="Vertical" /> |
||||
</StackPanel> |
</StackPanel> |
||||
</DockPanel> |
</DockPanel> |
||||
</Border> |
</Border> |
||||
</Design.PreviewWith> |
</Design.PreviewWith> |
||||
<Styles.Resources> |
|
||||
<Thickness x:Key="SliderTopHeaderMargin">0,0,0,4</Thickness> |
<Thickness x:Key="SliderTopHeaderMargin">0,0,0,4</Thickness> |
||||
<GridLength x:Key="SliderPreContentMargin">15</GridLength> |
<GridLength x:Key="SliderPreContentMargin">15</GridLength> |
||||
<GridLength x:Key="SliderPostContentMargin">15</GridLength> |
<GridLength x:Key="SliderPostContentMargin">15</GridLength> |
||||
<x:Double x:Key="SliderHorizontalHeight">32</x:Double> |
<x:Double x:Key="SliderHorizontalHeight">32</x:Double> |
||||
<x:Double x:Key="SliderVerticalWidth">32</x:Double> |
<x:Double x:Key="SliderVerticalWidth">32</x:Double> |
||||
<CornerRadius x:Key="SliderThumbCornerRadius">10</CornerRadius> |
<CornerRadius x:Key="SliderThumbCornerRadius">10</CornerRadius> |
||||
<x:Double x:Key="SliderHorizontalThumbWidth">20</x:Double> |
<x:Double x:Key="SliderHorizontalThumbWidth">20</x:Double> |
||||
<x:Double x:Key="SliderHorizontalThumbHeight">20</x:Double> |
<x:Double x:Key="SliderHorizontalThumbHeight">20</x:Double> |
||||
<x:Double x:Key="SliderVerticalThumbWidth">20</x:Double> |
<x:Double x:Key="SliderVerticalThumbWidth">20</x:Double> |
||||
<x:Double x:Key="SliderVerticalThumbHeight">20</x:Double> |
<x:Double x:Key="SliderVerticalThumbHeight">20</x:Double> |
||||
</Styles.Resources> |
|
||||
<Style Selector="Thumb.SliderThumbStyle"> |
<ControlTheme x:Key="FluentSliderHorizontalRepeatButton" TargetType="RepeatButton"> |
||||
<Setter Property="BorderThickness" Value="0" /> |
|
||||
<Setter Property="Template"> |
<Setter Property="Template"> |
||||
<Setter.Value> |
<ControlTemplate> |
||||
<ControlTemplate> |
<Grid> |
||||
<Border Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="{DynamicResource SliderThumbCornerRadius}" /> |
<Border Name="FocusTarget" Margin="0,-10" Background="Transparent" /> |
||||
</ControlTemplate> |
<Border Name="TrackBackground" |
||||
</Setter.Value> |
Background="{TemplateBinding Background}" |
||||
|
CornerRadius="{DynamicResource ControlCornerRadius}" |
||||
|
Height="{DynamicResource SliderTrackThemeHeight}" |
||||
|
VerticalAlignment="Center"/> |
||||
|
</Grid> |
||||
|
</ControlTemplate> |
||||
</Setter> |
</Setter> |
||||
</Style> |
</ControlTheme> |
||||
<Style Selector="Slider:horizontal"> |
|
||||
<Setter Property="Background" Value="{DynamicResource SliderTrackFill}" /> |
<ControlTheme x:Key="FluentSliderVerticalRepeatButton" TargetType="RepeatButton"> |
||||
<Setter Property="BorderThickness" Value="{DynamicResource SliderBorderThemeThickness}" /> |
|
||||
<Setter Property="Foreground" Value="{DynamicResource SliderTrackValueFill}" /> |
|
||||
<Setter Property="FontSize" Value="{DynamicResource ControlContentThemeFontSize}" /> |
|
||||
<Setter Property="Template"> |
<Setter Property="Template"> |
||||
<ControlTemplate> |
<ControlTemplate> |
||||
<DataValidationErrors> |
<Grid> |
||||
<Border BorderThickness="{TemplateBinding BorderThickness}" BorderBrush="{TemplateBinding BorderBrush}" CornerRadius="{TemplateBinding CornerRadius}"> |
<Border Name="FocusTarget" Margin="0,-10" Background="Transparent" /> |
||||
<Grid Name="grid" Margin="{TemplateBinding Padding}" RowDefinitions="Auto, *"> |
<Border Name="TrackBackground" |
||||
<ContentPresenter x:Name="HeaderContentPresenter" Grid.Row="0" TextElement.FontWeight="{DynamicResource SliderHeaderThemeFontWeight}" TextElement.Foreground="{DynamicResource SliderHeaderForeground}" |
Background="{TemplateBinding Background}" |
||||
Margin="{DynamicResource SliderTopHeaderMargin}" /> |
CornerRadius="{DynamicResource ControlCornerRadius}" |
||||
<Grid x:Name="SliderContainer" Grid.Row="1"> |
Width="{DynamicResource SliderTrackThemeHeight}" |
||||
<Grid.Styles> |
HorizontalAlignment="Center"/> |
||||
<Style Selector="TickBar"> |
</Grid> |
||||
<Setter Property="ReservedSpace" Value="{Binding #PART_Track.Thumb.Bounds}" /> |
|
||||
</Style> |
|
||||
</Grid.Styles> |
|
||||
<Grid x:Name="HorizontalTemplate" ColumnDefinitions="Auto,Auto,*" MinHeight="{DynamicResource SliderHorizontalHeight}"> |
|
||||
<Grid.RowDefinitions> |
|
||||
<RowDefinition Height="{DynamicResource SliderPreContentMargin}" /> |
|
||||
<RowDefinition Height="Auto" /> |
|
||||
<RowDefinition Height="{DynamicResource SliderPostContentMargin}" /> |
|
||||
</Grid.RowDefinitions> |
|
||||
<TickBar Name="TopTickBar" Placement="Top" Height="{DynamicResource SliderOutsideTickBarThemeHeight}" VerticalAlignment="Bottom" Margin="0,0,0,4" Grid.ColumnSpan="3" /> |
|
||||
<!-- <TickBar Name="HorizontalInlineTickBar" Placement="Top" Fill="{DynamicResource SliderInlineTickBarFill}" Height="{DynamicResource SliderTrackThemeHeight}" Grid.Row="1" Grid.ColumnSpan="3" /> --> |
|
||||
<TickBar Name="BottomTickBar" Placement="Bottom" Height="{DynamicResource SliderOutsideTickBarThemeHeight}" VerticalAlignment="Top" Margin="0,4,0,0" Grid.Row="2" Grid.ColumnSpan="3" /> |
|
||||
<Track Name="PART_Track" Grid.Row="1" Grid.ColumnSpan="3" IsDirectionReversed="{TemplateBinding IsDirectionReversed}" Orientation="Horizontal"> |
|
||||
<Track.DecreaseButton> |
|
||||
<RepeatButton Name="PART_DecreaseButton" Background="{TemplateBinding Foreground}" Focusable="False" HorizontalAlignment="Stretch" VerticalAlignment="Stretch"> |
|
||||
<RepeatButton.Template> |
|
||||
<ControlTemplate> |
|
||||
<Grid> |
|
||||
<Border Name="FocusTarget" Background="Transparent" Margin="0,-10" /> |
|
||||
<Border Name="TrackBackground" Background="{TemplateBinding Background}" CornerRadius="{DynamicResource ControlCornerRadius}" Height="{DynamicResource SliderTrackThemeHeight}" VerticalAlignment="Center" /> |
|
||||
</Grid> |
|
||||
</ControlTemplate> |
|
||||
</RepeatButton.Template> |
|
||||
</RepeatButton> |
|
||||
</Track.DecreaseButton> |
|
||||
<Track.IncreaseButton> |
|
||||
<RepeatButton Name="PART_IncreaseButton" Background="{TemplateBinding Background}" Focusable="False" HorizontalAlignment="Stretch" VerticalAlignment="Stretch"> |
|
||||
<RepeatButton.Template> |
|
||||
<ControlTemplate> |
|
||||
<Grid> |
|
||||
<Border Name="FocusTarget" Background="Transparent" Margin="0,-10" /> |
|
||||
<Border Name="TrackBackground" Background="{TemplateBinding Background}" CornerRadius="{DynamicResource ControlCornerRadius}" Height="{DynamicResource SliderTrackThemeHeight}" VerticalAlignment="Center" /> |
|
||||
</Grid> |
|
||||
</ControlTemplate> |
|
||||
</RepeatButton.Template> |
|
||||
</RepeatButton> |
|
||||
</Track.IncreaseButton> |
|
||||
<Thumb Classes="SliderThumbStyle" Name="thumb" Margin="0" Padding="0" DataContext="{TemplateBinding Value}" Height="{DynamicResource SliderHorizontalThumbHeight}" Width="{DynamicResource SliderHorizontalThumbWidth}" /> |
|
||||
</Track> |
|
||||
</Grid> |
|
||||
</Grid> |
|
||||
</Grid> |
|
||||
</Border> |
|
||||
</DataValidationErrors> |
|
||||
</ControlTemplate> |
</ControlTemplate> |
||||
</Setter> |
</Setter> |
||||
</Style> |
</ControlTheme> |
||||
<Style Selector="Slider:vertical"> |
|
||||
|
<ControlTheme x:Key="FluentSliderThumbTheme" TargetType="Thumb"> |
||||
|
<Setter Property="Template"> |
||||
|
<ControlTemplate> |
||||
|
<Border |
||||
|
Background="{TemplateBinding Background}" |
||||
|
BorderBrush="{TemplateBinding BorderBrush}" |
||||
|
BorderThickness="{TemplateBinding BorderThickness}" |
||||
|
CornerRadius="{DynamicResource SliderThumbCornerRadius}" /> |
||||
|
</ControlTemplate> |
||||
|
</Setter> |
||||
|
</ControlTheme> |
||||
|
|
||||
|
<ControlTheme x:Key="{x:Type Slider}" TargetType="Slider"> |
||||
<Setter Property="Background" Value="{DynamicResource SliderTrackFill}" /> |
<Setter Property="Background" Value="{DynamicResource SliderTrackFill}" /> |
||||
<Setter Property="BorderThickness" Value="{DynamicResource SliderBorderThemeThickness}" /> |
<Setter Property="BorderThickness" Value="{DynamicResource SliderBorderThemeThickness}" /> |
||||
<Setter Property="Foreground" Value="{DynamicResource SliderTrackValueFill}" /> |
<Setter Property="Foreground" Value="{DynamicResource SliderTrackValueFill}" /> |
||||
<Setter Property="FontSize" Value="{DynamicResource ControlContentThemeFontSize}" /> |
<Setter Property="FontSize" Value="{DynamicResource ControlContentThemeFontSize}" /> |
||||
<Setter Property="Template"> |
<Style Selector="^:horizontal"> |
||||
<ControlTemplate> |
<Setter Property="Template"> |
||||
<DataValidationErrors> |
<ControlTemplate> |
||||
<Border BorderThickness="{TemplateBinding BorderThickness}" BorderBrush="{TemplateBinding BorderBrush}" CornerRadius="{TemplateBinding CornerRadius}"> |
<DataValidationErrors> |
||||
<Grid Name="grid" Margin="{TemplateBinding Padding}" RowDefinitions="Auto, *"> |
<Border |
||||
<ContentPresenter x:Name="HeaderContentPresenter" Grid.Row="0" TextElement.FontWeight="{DynamicResource SliderHeaderThemeFontWeight}" TextElement.Foreground="{DynamicResource SliderHeaderForeground}" |
BorderBrush="{TemplateBinding BorderBrush}" |
||||
Margin="{DynamicResource SliderTopHeaderMargin}" /> |
BorderThickness="{TemplateBinding BorderThickness}" |
||||
<Grid x:Name="SliderContainer" Grid.Row="1"> |
CornerRadius="{TemplateBinding CornerRadius}"> |
||||
<Grid.Styles> |
<Grid |
||||
<Style Selector="TickBar"> |
Name="grid" |
||||
<Setter Property="ReservedSpace" Value="{Binding #PART_Track.Thumb.Bounds}" /> |
Margin="{TemplateBinding Padding}" |
||||
</Style> |
RowDefinitions="Auto, *"> |
||||
</Grid.Styles> |
<ContentPresenter |
||||
<Grid x:Name="VerticalTemplate" RowDefinitions="*,Auto,Auto" MinWidth="{DynamicResource SliderVerticalWidth}"> |
x:Name="HeaderContentPresenter" |
||||
<Grid.ColumnDefinitions> |
Grid.Row="0" |
||||
<ColumnDefinition Width="{DynamicResource SliderPreContentMargin}" /> |
Margin="{DynamicResource SliderTopHeaderMargin}" |
||||
<ColumnDefinition Width="Auto" /> |
TextElement.FontWeight="{DynamicResource SliderHeaderThemeFontWeight}" |
||||
<ColumnDefinition Width="{DynamicResource SliderPostContentMargin}" /> |
TextElement.Foreground="{DynamicResource SliderHeaderForeground}" /> |
||||
</Grid.ColumnDefinitions> |
<Grid x:Name="SliderContainer" |
||||
<TickBar Name="LeftTickBar" Placement="Left" Width="{DynamicResource SliderOutsideTickBarThemeHeight}" HorizontalAlignment="Right" Margin="0,0,4,0" Grid.RowSpan="3" /> |
Grid.Row="1" |
||||
<!-- <TickBar Name="VerticalInlineTickBar" Placement="Inline" Fill="{DynamicResource SliderInlineTickBarFill}" Width="{DynamicResource SliderTrackThemeHeight}" Grid.Column="1" Grid.RowSpan="3" /> --> |
Background="{DynamicResource SliderContainerBackground}"> |
||||
<TickBar Name="RightTickBar" Placement="Right" Width="{DynamicResource SliderOutsideTickBarThemeHeight}" HorizontalAlignment="Left" Margin="4,0,0,0" Grid.Column="2" Grid.RowSpan="3" /> |
<Grid.Styles> |
||||
<Track Name="PART_Track" Grid.Column="1" Grid.ColumnSpan="1" Grid.RowSpan="3" IsDirectionReversed="{TemplateBinding IsDirectionReversed}" Orientation="Vertical"> |
<Style Selector="TickBar"> |
||||
<Track.DecreaseButton> |
<Setter Property="ReservedSpace" Value="{Binding #PART_Track.Thumb.Bounds}" /> |
||||
<RepeatButton Name="PART_DecreaseButton" Background="{TemplateBinding Foreground}" Focusable="False" VerticalAlignment="Stretch" HorizontalAlignment="Stretch"> |
</Style> |
||||
<RepeatButton.Template> |
</Grid.Styles> |
||||
<ControlTemplate> |
<Grid |
||||
<Grid> |
x:Name="HorizontalTemplate" |
||||
<Border Name="FocusTarget" Background="Transparent" Margin="0,-10" /> |
MinHeight="{DynamicResource SliderHorizontalHeight}" |
||||
<Border Name="TrackBackground" Background="{TemplateBinding Background}" CornerRadius="{DynamicResource ControlCornerRadius}" Width="{DynamicResource SliderTrackThemeHeight}" HorizontalAlignment="Center" /> |
ColumnDefinitions="Auto,Auto,*"> |
||||
</Grid> |
<Grid.RowDefinitions> |
||||
</ControlTemplate> |
<RowDefinition Height="{DynamicResource SliderPreContentMargin}" /> |
||||
</RepeatButton.Template> |
<RowDefinition Height="Auto" /> |
||||
</RepeatButton> |
<RowDefinition Height="{DynamicResource SliderPostContentMargin}" /> |
||||
</Track.DecreaseButton> |
</Grid.RowDefinitions> |
||||
<Track.IncreaseButton> |
<TickBar |
||||
<RepeatButton Name="PART_IncreaseButton" Background="{TemplateBinding Background}" Focusable="False" VerticalAlignment="Stretch" HorizontalAlignment="Stretch"> |
Name="TopTickBar" |
||||
<RepeatButton.Template> |
Grid.ColumnSpan="3" |
||||
<ControlTemplate> |
Ticks="{TemplateBinding Ticks}" |
||||
<Grid> |
TickFrequency="{TemplateBinding Slider.TickFrequency}" |
||||
<Border Name="FocusTarget" Background="Transparent" Margin="0,-10" /> |
Orientation="{TemplateBinding Slider.Orientation}" |
||||
<Border Name="TrackBackground" Background="{TemplateBinding Background}" CornerRadius="{DynamicResource ControlCornerRadius}" Width="{DynamicResource SliderTrackThemeHeight}" HorizontalAlignment="Center" /> |
Minimum="{TemplateBinding Slider.Minimum}" |
||||
</Grid> |
Maximum="{TemplateBinding Slider.Maximum}" |
||||
</ControlTemplate> |
Height="{DynamicResource SliderOutsideTickBarThemeHeight}" |
||||
</RepeatButton.Template> |
Margin="0,0,0,4" |
||||
</RepeatButton> |
VerticalAlignment="Bottom" |
||||
</Track.IncreaseButton> |
Placement="Top" |
||||
<Thumb Classes="SliderThumbStyle" Name="SliderThumb" Margin="0" Padding="0" DataContext="{TemplateBinding Value}" Height="{DynamicResource SliderVerticalThumbHeight}" Width="{DynamicResource SliderVerticalThumbWidth}" /> |
IsVisible="False" |
||||
</Track> |
Fill="{DynamicResource SliderTickBarFill}"/> |
||||
|
<TickBar |
||||
|
Name="BottomTickBar" |
||||
|
Grid.Row="2" |
||||
|
Grid.ColumnSpan="3" |
||||
|
Ticks="{TemplateBinding Ticks}" |
||||
|
TickFrequency="{TemplateBinding Slider.TickFrequency}" |
||||
|
Orientation="{TemplateBinding Slider.Orientation}" |
||||
|
Minimum="{TemplateBinding Slider.Minimum}" |
||||
|
Maximum="{TemplateBinding Slider.Maximum}" |
||||
|
Height="{DynamicResource SliderOutsideTickBarThemeHeight}" |
||||
|
Margin="0,4,0,0" |
||||
|
VerticalAlignment="Top" |
||||
|
Placement="Bottom" |
||||
|
IsVisible="False" |
||||
|
Fill="{DynamicResource SliderTickBarFill}" /> |
||||
|
<Track |
||||
|
Name="PART_Track" |
||||
|
Grid.Row="1" |
||||
|
Grid.ColumnSpan="3" |
||||
|
Minimum="{TemplateBinding Minimum}" |
||||
|
Maximum="{TemplateBinding Maximum}" |
||||
|
Value="{TemplateBinding Value, Mode=TwoWay}" |
||||
|
IsDirectionReversed="{TemplateBinding IsDirectionReversed}" |
||||
|
Orientation="Horizontal"> |
||||
|
<Track.DecreaseButton> |
||||
|
<RepeatButton |
||||
|
Name="PART_DecreaseButton" |
||||
|
Theme="{StaticResource FluentSliderHorizontalRepeatButton}" |
||||
|
Background="{TemplateBinding Foreground}" |
||||
|
Focusable="False"/> |
||||
|
</Track.DecreaseButton> |
||||
|
<Track.IncreaseButton> |
||||
|
<RepeatButton |
||||
|
Name="PART_IncreaseButton" |
||||
|
Theme="{StaticResource FluentSliderHorizontalRepeatButton}" |
||||
|
Background="{TemplateBinding Background}" |
||||
|
Focusable="False"/> |
||||
|
</Track.IncreaseButton> |
||||
|
<Thumb |
||||
|
Name="thumb" |
||||
|
Width="{DynamicResource SliderHorizontalThumbWidth}" |
||||
|
Height="{DynamicResource SliderHorizontalThumbHeight}" |
||||
|
Margin="0" |
||||
|
Padding="0" |
||||
|
Background="{DynamicResource SliderThumbBackground}" |
||||
|
BorderThickness="0" |
||||
|
Theme="{StaticResource FluentSliderThumbTheme}" |
||||
|
DataContext="{TemplateBinding Value}"/> |
||||
|
</Track> |
||||
|
</Grid> |
||||
</Grid> |
</Grid> |
||||
</Grid> |
</Grid> |
||||
</Grid> |
</Border> |
||||
</Border> |
</DataValidationErrors> |
||||
</DataValidationErrors> |
</ControlTemplate> |
||||
</ControlTemplate> |
</Setter> |
||||
</Setter> |
</Style> |
||||
</Style> |
<Style Selector="^:vertical"> |
||||
<Style Selector="Slider /template/ Track#PART_Track"> |
<Setter Property="Template"> |
||||
<Setter Property="Minimum" Value="{TemplateBinding Minimum}" /> |
<ControlTemplate> |
||||
<Setter Property="Maximum" Value="{TemplateBinding Maximum}" /> |
<DataValidationErrors> |
||||
<Setter Property="Value" Value="{TemplateBinding Value, Mode=TwoWay}" /> |
<Border |
||||
</Style> |
BorderBrush="{TemplateBinding BorderBrush}" |
||||
<Style Selector="Slider /template/ TickBar"> |
BorderThickness="{TemplateBinding BorderThickness}" |
||||
<Setter Property="Fill" Value="{DynamicResource SliderTickBarFill}" /> |
CornerRadius="{TemplateBinding CornerRadius}"> |
||||
<Setter Property="TickFrequency" Value="{TemplateBinding Slider.TickFrequency}" /> |
<Grid |
||||
<Setter Property="Orientation" Value="{TemplateBinding Slider.Orientation}" /> |
Name="grid" |
||||
<Setter Property="Minimum" Value="{TemplateBinding Slider.Minimum}" /> |
Margin="{TemplateBinding Padding}" |
||||
<Setter Property="Maximum" Value="{TemplateBinding Slider.Maximum}" /> |
RowDefinitions="Auto, *"> |
||||
</Style> |
<ContentPresenter |
||||
|
x:Name="HeaderContentPresenter" |
||||
<!-- Normal State --> |
Grid.Row="0" |
||||
|
Margin="{DynamicResource SliderTopHeaderMargin}" |
||||
<Style Selector="Slider /template/ Thumb.SliderThumbStyle"> |
TextElement.FontWeight="{DynamicResource SliderHeaderThemeFontWeight}" |
||||
<Setter Property="Background" Value="{DynamicResource SliderThumbBackground}" /> |
TextElement.Foreground="{DynamicResource SliderHeaderForeground}" /> |
||||
</Style> |
<Grid x:Name="SliderContainer" |
||||
|
Grid.Row="1" |
||||
|
Background="{DynamicResource SliderContainerBackground}"> |
||||
|
<Grid.Styles> |
||||
|
<Style Selector="TickBar"> |
||||
|
<Setter Property="ReservedSpace" Value="{Binding #PART_Track.Thumb.Bounds}" /> |
||||
|
</Style> |
||||
|
</Grid.Styles> |
||||
|
<Grid |
||||
|
x:Name="VerticalTemplate" |
||||
|
MinWidth="{DynamicResource SliderVerticalWidth}" |
||||
|
RowDefinitions="*,Auto,Auto"> |
||||
|
<Grid.ColumnDefinitions> |
||||
|
<ColumnDefinition Width="{DynamicResource SliderPreContentMargin}" /> |
||||
|
<ColumnDefinition Width="Auto" /> |
||||
|
<ColumnDefinition Width="{DynamicResource SliderPostContentMargin}" /> |
||||
|
</Grid.ColumnDefinitions> |
||||
|
<TickBar |
||||
|
Name="LeftTickBar" |
||||
|
Grid.RowSpan="3" |
||||
|
Ticks="{TemplateBinding Ticks}" |
||||
|
TickFrequency="{TemplateBinding Slider.TickFrequency}" |
||||
|
Orientation="{TemplateBinding Slider.Orientation}" |
||||
|
Minimum="{TemplateBinding Slider.Minimum}" |
||||
|
Maximum="{TemplateBinding Slider.Maximum}" |
||||
|
Width="{DynamicResource SliderOutsideTickBarThemeHeight}" |
||||
|
Margin="0,0,4,0" |
||||
|
HorizontalAlignment="Right" |
||||
|
Placement="Left" |
||||
|
IsVisible="False" |
||||
|
Fill="{DynamicResource SliderTickBarFill}"/> |
||||
|
<TickBar |
||||
|
Name="RightTickBar" |
||||
|
Grid.RowSpan="3" |
||||
|
Grid.Column="2" |
||||
|
Ticks="{TemplateBinding Ticks}" |
||||
|
TickFrequency="{TemplateBinding Slider.TickFrequency}" |
||||
|
Orientation="{TemplateBinding Slider.Orientation}" |
||||
|
Minimum="{TemplateBinding Slider.Minimum}" |
||||
|
Maximum="{TemplateBinding Slider.Maximum}" |
||||
|
Width="{DynamicResource SliderOutsideTickBarThemeHeight}" |
||||
|
Margin="4,0,0,0" |
||||
|
HorizontalAlignment="Left" |
||||
|
Placement="Right" |
||||
|
IsVisible="False" |
||||
|
Fill="{DynamicResource SliderTickBarFill}"/> |
||||
|
<Track |
||||
|
Name="PART_Track" |
||||
|
Grid.RowSpan="3" |
||||
|
Grid.Column="1" |
||||
|
Grid.ColumnSpan="1" |
||||
|
Minimum="{TemplateBinding Minimum}" |
||||
|
Maximum="{TemplateBinding Maximum}" |
||||
|
Value="{TemplateBinding Value, Mode=TwoWay}" |
||||
|
IsDirectionReversed="{TemplateBinding IsDirectionReversed}" |
||||
|
Orientation="Vertical"> |
||||
|
<Track.DecreaseButton> |
||||
|
<RepeatButton |
||||
|
Name="PART_DecreaseButton" |
||||
|
Theme="{StaticResource FluentSliderVerticalRepeatButton}" |
||||
|
Background="{TemplateBinding Foreground}" |
||||
|
Focusable="False"/> |
||||
|
</Track.DecreaseButton> |
||||
|
<Track.IncreaseButton> |
||||
|
<RepeatButton |
||||
|
Name="PART_IncreaseButton" |
||||
|
Background="{TemplateBinding Background}" |
||||
|
Theme="{StaticResource FluentSliderVerticalRepeatButton}" |
||||
|
Focusable="False"/> |
||||
|
</Track.IncreaseButton> |
||||
|
<Thumb |
||||
|
Name="SliderThumb" |
||||
|
Width="{DynamicResource SliderVerticalThumbWidth}" |
||||
|
Height="{DynamicResource SliderVerticalThumbHeight}" |
||||
|
Margin="0" |
||||
|
Padding="0" |
||||
|
Background="{DynamicResource SliderThumbBackground}" |
||||
|
BorderThickness="0" |
||||
|
Theme="{StaticResource FluentSliderThumbTheme}" |
||||
|
DataContext="{TemplateBinding Value}" /> |
||||
|
</Track> |
||||
|
</Grid> |
||||
|
</Grid> |
||||
|
</Grid> |
||||
|
</Border> |
||||
|
</DataValidationErrors> |
||||
|
</ControlTemplate> |
||||
|
</Setter> |
||||
|
</Style> |
||||
|
|
||||
<Style Selector="Slider /template/ Grid#SliderContainer"> |
<!-- TickBar Placement States --> |
||||
<Setter Property="Background" Value="{DynamicResource SliderContainerBackground}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="Slider /template/ TickBar"> |
<Style Selector="^[TickPlacement=TopLeft] /template/ TickBar#LeftTickBar, ^[TickPlacement=Outside] /template/ TickBar#LeftTickBar"> |
||||
<Setter Property="IsVisible" Value="False" /> |
<Setter Property="IsVisible" Value="True" /> |
||||
<Setter Property="Ticks" Value="{TemplateBinding Ticks}" /> |
</Style> |
||||
</Style> |
|
||||
|
|
||||
<!-- TickBar Placement States --> |
<Style Selector="^[TickPlacement=TopLeft] /template/ TickBar#TopTickBar, ^[TickPlacement=Outside] /template/ TickBar#TopTickBar"> |
||||
|
<Setter Property="IsVisible" Value="True" /> |
||||
|
</Style> |
||||
|
|
||||
<Style Selector="Slider[TickPlacement=TopLeft] /template/ TickBar#LeftTickBar, Slider[TickPlacement=Outside] /template/ TickBar#LeftTickBar"> |
<Style Selector="^[TickPlacement=BottomRight] /template/ TickBar#BottomTickBar, ^[TickPlacement=Outside] /template/ TickBar#BottomTickBar"> |
||||
<Setter Property="IsVisible" Value="True" /> |
<Setter Property="IsVisible" Value="True" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="Slider[TickPlacement=TopLeft] /template/ TickBar#TopTickBar, Slider[TickPlacement=Outside] /template/ TickBar#TopTickBar"> |
|
||||
<Setter Property="IsVisible" Value="True" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="Slider[TickPlacement=BottomRight] /template/ TickBar#BottomTickBar, Slider[TickPlacement=Outside] /template/ TickBar#BottomTickBar"> |
|
||||
<Setter Property="IsVisible" Value="True" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="Slider[TickPlacement=BottomRight] /template/ TickBar#RightTickBar, Slider[TickPlacement=Outside] /template/ TickBar#RightTickBar"> |
|
||||
<Setter Property="IsVisible" Value="True" /> |
|
||||
</Style> |
|
||||
|
|
||||
<!-- Disabled State --> |
|
||||
|
|
||||
<Style Selector="Slider:disabled /template/ ContentPresenter#HeaderContentPresenter"> |
<Style Selector="^[TickPlacement=BottomRight] /template/ TickBar#RightTickBar, ^[TickPlacement=Outside] /template/ TickBar#RightTickBar"> |
||||
<Setter Property="Foreground" Value="{DynamicResource SliderHeaderForegroundDisabled}" /> |
<Setter Property="IsVisible" Value="True" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="Slider:disabled /template/ RepeatButton#PART_DecreaseButton"> |
|
||||
<Setter Property="Background" Value="{DynamicResource SliderTrackValueFillDisabled}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="Slider:disabled /template/ RepeatButton#PART_IncreaseButton"> |
|
||||
<Setter Property="Background" Value="{DynamicResource SliderTrackFillDisabled}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="Slider:disabled /template/ Thumb.SliderThumbStyle"> |
|
||||
<Setter Property="Background" Value="{DynamicResource SliderThumbBackgroundDisabled}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="Slider:disabled /template/ TickBar"> |
|
||||
<Setter Property="Fill" Value="{DynamicResource SliderTickBarFillDisabled}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="Slider:pointerover /template/ Grid#SliderContainer"> |
|
||||
<Setter Property="Background" Value="{DynamicResource SliderContainerBackgroundDisabled}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<!-- PointerOver State --> |
<!-- Disabled State --> |
||||
<Style Selector="Slider:pointerover /template/ RepeatButton#PART_IncreaseButton"> |
|
||||
<Setter Property="Background" Value="{DynamicResource SliderTrackFillPointerOver}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="Slider:pointerover /template/ Thumb.SliderThumbStyle"> |
|
||||
<Setter Property="Background" Value="{DynamicResource SliderThumbBackgroundPointerOver}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="Slider:pointerover /template/ Grid#SliderContainer"> |
|
||||
<Setter Property="Background" Value="{DynamicResource SliderContainerBackgroundPointerOver}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="Slider:pointerover /template/ RepeatButton#PART_DecreaseButton"> |
|
||||
<Setter Property="Background" Value="{DynamicResource SliderTrackValueFillPointerOver}" /> |
|
||||
</Style> |
|
||||
|
|
||||
<!-- Pressed State --> |
<Style Selector="^:disabled"> |
||||
<Style Selector="Slider:pressed /template/ RepeatButton#PART_IncreaseButton"> |
<Style Selector="^ /template/ ContentPresenter#HeaderContentPresenter"> |
||||
<Setter Property="Background" Value="{DynamicResource SliderTrackFillPressed}" /> |
<Setter Property="Foreground" Value="{DynamicResource SliderHeaderForegroundDisabled}" /> |
||||
</Style> |
</Style> |
||||
|
<Style Selector="^ /template/ RepeatButton#PART_DecreaseButton"> |
||||
|
<Setter Property="Background" Value="{DynamicResource SliderTrackValueFillDisabled}" /> |
||||
|
</Style> |
||||
|
|
||||
<Style Selector="Slider:pressed /template/ Thumb.SliderThumbStyle"> |
<Style Selector="^ /template/ RepeatButton#PART_IncreaseButton"> |
||||
<Setter Property="Background" Value="{DynamicResource SliderThumbBackgroundPressed}" /> |
<Setter Property="Background" Value="{DynamicResource SliderTrackFillDisabled}" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="Slider:pointerover /template/ Grid#SliderContainer"> |
<Style Selector="^ /template/ Thumb"> |
||||
<Setter Property="Background" Value="{DynamicResource SliderContainerBackgroundPressed}" /> |
<Setter Property="Background" Value="{DynamicResource SliderThumbBackgroundDisabled}" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="Slider:pointerover /template/ RepeatButton#PART_DecreaseButton"> |
<Style Selector="^ /template/ TickBar"> |
||||
<Setter Property="Background" Value="{DynamicResource SliderTrackValueFillPressed}" /> |
<Setter Property="Fill" Value="{DynamicResource SliderTickBarFillDisabled}" /> |
||||
</Style> |
</Style> |
||||
|
</Style> |
||||
<Style Selector="Slider:error /template/ Thumb.SliderThumbStyle"> |
|
||||
<Setter Property="Background" Value="{DynamicResource SystemControlErrorTextForegroundBrush}" /> |
<!-- PointerOver State --> |
||||
</Style> |
<Style Selector="^:pointerover"> |
||||
|
<Style Selector="^ /template/ Grid#SliderContainer"> |
||||
<Style Selector="Slider:error"> |
<Setter Property="Background" Value="{DynamicResource SliderContainerBackgroundDisabled}" /> |
||||
|
</Style> |
||||
|
<Style Selector="^ /template/ RepeatButton#PART_IncreaseButton"> |
||||
|
<Setter Property="Background" Value="{DynamicResource SliderTrackFillPointerOver}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ Thumb"> |
||||
|
<Setter Property="Background" Value="{DynamicResource SliderThumbBackgroundPointerOver}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ Grid#SliderContainer"> |
||||
|
<Setter Property="Background" Value="{DynamicResource SliderContainerBackgroundPointerOver}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ RepeatButton#PART_DecreaseButton"> |
||||
|
<Setter Property="Background" Value="{DynamicResource SliderTrackValueFillPointerOver}" /> |
||||
|
</Style> |
||||
|
|
||||
|
</Style> |
||||
|
|
||||
|
<!-- Pressed State --> |
||||
|
<Style Selector="^:pressed"> |
||||
|
<Style Selector="^ /template/ Grid#SliderContainer"> |
||||
|
<Setter Property="Background" Value="{DynamicResource SliderContainerBackgroundPressed}" /> |
||||
|
</Style> |
||||
|
<Style Selector="^ /template/ RepeatButton#PART_DecreaseButton"> |
||||
|
<Setter Property="Background" Value="{DynamicResource SliderTrackValueFillPressed}" /> |
||||
|
</Style> |
||||
|
<Style Selector="^ /template/ RepeatButton#PART_IncreaseButton"> |
||||
|
<Setter Property="Background" Value="{DynamicResource SliderTrackFillPressed}" /> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^ /template/ Thumb"> |
||||
|
<Setter Property="Background" Value="{DynamicResource SliderThumbBackgroundPressed}" /> |
||||
|
</Style> |
||||
|
</Style> |
||||
|
|
||||
|
<Style Selector="^:error"> |
||||
<Setter Property="Foreground" Value="{DynamicResource SystemControlErrorTextForegroundBrush}" /> |
<Setter Property="Foreground" Value="{DynamicResource SystemControlErrorTextForegroundBrush}" /> |
||||
</Style> |
<Style Selector="^ /template/ Thumb"> |
||||
</Styles> |
<Setter Property="Background" Value="{DynamicResource SystemControlErrorTextForegroundBrush}" /> |
||||
|
</Style> |
||||
|
</Style> |
||||
|
|
||||
|
</ControlTheme> |
||||
|
</ResourceDictionary> |
||||
|
|||||
@ -1,53 +1,59 @@ |
|||||
<Styles xmlns="https://github.com/avaloniaui" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
<Design.PreviewWith> |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
||||
<Border> |
<Design.PreviewWith> |
||||
<TitleBar Background="SkyBlue" Height="30" Width="300" Foreground="Black" /> |
<Border Height="30" Width="300"> |
||||
</Border> |
<TitleBar Background="SkyBlue" Foreground="Black" /> |
||||
</Design.PreviewWith> |
</Border> |
||||
<Style Selector="TitleBar"> |
</Design.PreviewWith> |
||||
<Setter Property="Foreground" Value="{DynamicResource SystemControlForegroundBaseHighBrush}"/> |
|
||||
<Setter Property="VerticalAlignment" Value="Top" /> |
|
||||
<Setter Property="HorizontalAlignment" Value="Stretch" /> |
|
||||
<Setter Property="Background" Value="Transparent" /> |
|
||||
<Setter Property="Template"> |
|
||||
<ControlTemplate> |
|
||||
<Panel HorizontalAlignment="{TemplateBinding HorizontalAlignment}" VerticalAlignment="Stretch"> |
|
||||
<Panel x:Name="PART_MouseTracker" Height="1" VerticalAlignment="Top" /> |
|
||||
<Panel x:Name="PART_Container"> |
|
||||
<Border x:Name="PART_Background" Background="{TemplateBinding Background}" /> |
|
||||
<CaptionButtons x:Name="PART_CaptionButtons" VerticalAlignment="Top" HorizontalAlignment="Right" Foreground="{TemplateBinding Foreground}" /> |
|
||||
</Panel> |
|
||||
</Panel> |
|
||||
</ControlTemplate> |
|
||||
</Setter> |
|
||||
</Style> |
|
||||
|
|
||||
<Style Selector="TitleBar:fullscreen"> |
<ControlTheme x:Key="{x:Type TitleBar}" TargetType="TitleBar"> |
||||
<Setter Property="Background" Value="{DynamicResource SystemAccentColor}" /> |
<Setter Property="Foreground" Value="{DynamicResource SystemControlForegroundBaseHighBrush}" /> |
||||
</Style> |
<Setter Property="VerticalAlignment" Value="Top" /> |
||||
|
<Setter Property="HorizontalAlignment" Value="Stretch" /> |
||||
|
<Setter Property="Background" Value="Transparent" /> |
||||
|
<Setter Property="Template"> |
||||
|
<ControlTemplate> |
||||
|
<Panel HorizontalAlignment="{TemplateBinding HorizontalAlignment}" |
||||
|
VerticalAlignment="Stretch"> |
||||
|
<Panel x:Name="PART_MouseTracker" |
||||
|
Height="1" |
||||
|
VerticalAlignment="Top" /> |
||||
|
<Panel x:Name="PART_Container"> |
||||
|
<Border x:Name="PART_Background" |
||||
|
Background="{TemplateBinding Background}" |
||||
|
IsHitTestVisible="False"/> |
||||
|
<CaptionButtons x:Name="PART_CaptionButtons" |
||||
|
VerticalAlignment="Top" |
||||
|
HorizontalAlignment="Right" |
||||
|
Foreground="{TemplateBinding Foreground}" /> |
||||
|
</Panel> |
||||
|
</Panel> |
||||
|
</ControlTemplate> |
||||
|
</Setter> |
||||
|
|
||||
<Style Selector="TitleBar /template/ Border#PART_Background"> |
<Style Selector="^:fullscreen"> |
||||
<Setter Property="IsHitTestVisible" Value="False" /> |
<Setter Property="Background" Value="{DynamicResource SystemAccentColor}" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="TitleBar:fullscreen /template/ Border#PART_Background"> |
<Style Selector="^:fullscreen /template/ Border#PART_Background"> |
||||
<Setter Property="IsHitTestVisible" Value="True" /> |
<Setter Property="IsHitTestVisible" Value="True" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="TitleBar:fullscreen /template/ Panel#PART_MouseTracker"> |
<Style Selector="^:fullscreen /template/ Panel#PART_MouseTracker"> |
||||
<Setter Property="Background" Value="Transparent" /> |
<Setter Property="Background" Value="Transparent" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="TitleBar:fullscreen /template/ Panel#PART_Container"> |
<Style Selector="^:fullscreen /template/ Panel#PART_Container"> |
||||
<Setter Property="RenderTransform" Value="translateY(-30px)" /> |
<Setter Property="RenderTransform" Value="translateY(-30px)" /> |
||||
<Setter Property="Transitions"> |
<Setter Property="Transitions"> |
||||
<Transitions> |
<Transitions> |
||||
<TransformOperationsTransition Property="RenderTransform" Duration="0:0:.25" /> |
<TransformOperationsTransition Property="RenderTransform" Duration="0:0:.25" /> |
||||
</Transitions> |
</Transitions> |
||||
</Setter> |
</Setter> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="TitleBar:fullscreen:pointerover /template/ Panel#PART_Container"> |
<Style Selector="^:fullscreen:pointerover /template/ Panel#PART_Container"> |
||||
<Setter Property="RenderTransform" Value="none" /> |
<Setter Property="RenderTransform" Value="none" /> |
||||
</Style> |
</Style> |
||||
</Styles> |
</ControlTheme> |
||||
|
</ResourceDictionary> |
||||
|
|||||
@ -1,28 +1,43 @@ |
|||||
<Style xmlns="https://github.com/avaloniaui" |
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
Selector="TreeView"> |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
||||
<Setter Property="Background" Value="Transparent" /> |
<Design.PreviewWith> |
||||
<Setter Property="BorderBrush" Value="Transparent" /> |
<Border Padding="20"> |
||||
<Setter Property="BorderThickness" Value="0" /> |
<StackPanel Spacing="20"> |
||||
<Setter Property="Padding" Value="0" /> |
<TreeView> |
||||
<Setter Property="ScrollViewer.HorizontalScrollBarVisibility" Value="Auto" /> |
<TreeViewItem Header="Root" IsExpanded="True"> |
||||
<Setter Property="ScrollViewer.VerticalScrollBarVisibility" Value="Auto" /> |
<TreeViewItem Header="Child1"/> |
||||
<Setter Property="ScrollViewer.IsScrollChainingEnabled" Value="True" /> |
<TreeViewItem Header="Child2"/> |
||||
<Setter Property="Template"> |
</TreeViewItem> |
||||
<ControlTemplate> |
</TreeView> |
||||
<Border BorderBrush="{TemplateBinding BorderBrush}" |
</StackPanel> |
||||
BorderThickness="{TemplateBinding BorderThickness}" |
</Border> |
||||
CornerRadius="{TemplateBinding CornerRadius}"> |
</Design.PreviewWith> |
||||
<ScrollViewer Background="{TemplateBinding Background}" |
|
||||
HorizontalScrollBarVisibility="{TemplateBinding (ScrollViewer.HorizontalScrollBarVisibility)}" |
<ControlTheme x:Key="{x:Type TreeView}" TargetType="TreeView"> |
||||
VerticalScrollBarVisibility="{TemplateBinding (ScrollViewer.VerticalScrollBarVisibility)}" |
<Setter Property="Background" Value="Transparent" /> |
||||
IsScrollChainingEnabled="{TemplateBinding (ScrollViewer.IsScrollChainingEnabled)}" |
<Setter Property="BorderBrush" Value="Transparent" /> |
||||
AllowAutoHide="{TemplateBinding (ScrollViewer.AllowAutoHide)}"> |
<Setter Property="BorderThickness" Value="0" /> |
||||
<ItemsPresenter Name="PART_ItemsPresenter" |
<Setter Property="Padding" Value="0" /> |
||||
Items="{TemplateBinding Items}" |
<Setter Property="ScrollViewer.HorizontalScrollBarVisibility" Value="Auto" /> |
||||
ItemsPanel="{TemplateBinding ItemsPanel}" |
<Setter Property="ScrollViewer.VerticalScrollBarVisibility" Value="Auto" /> |
||||
Margin="{TemplateBinding Padding}" /> |
<Setter Property="ScrollViewer.IsScrollChainingEnabled" Value="True" /> |
||||
</ScrollViewer> |
<Setter Property="Template"> |
||||
</Border> |
<ControlTemplate> |
||||
</ControlTemplate> |
<Border BorderBrush="{TemplateBinding BorderBrush}" |
||||
</Setter> |
BorderThickness="{TemplateBinding BorderThickness}" |
||||
</Style> |
CornerRadius="{TemplateBinding CornerRadius}"> |
||||
|
<ScrollViewer Background="{TemplateBinding Background}" |
||||
|
HorizontalScrollBarVisibility="{TemplateBinding (ScrollViewer.HorizontalScrollBarVisibility)}" |
||||
|
VerticalScrollBarVisibility="{TemplateBinding (ScrollViewer.VerticalScrollBarVisibility)}" |
||||
|
IsScrollChainingEnabled="{TemplateBinding (ScrollViewer.IsScrollChainingEnabled)}" |
||||
|
AllowAutoHide="{TemplateBinding (ScrollViewer.AllowAutoHide)}"> |
||||
|
<ItemsPresenter Name="PART_ItemsPresenter" |
||||
|
Items="{TemplateBinding Items}" |
||||
|
ItemsPanel="{TemplateBinding ItemsPanel}" |
||||
|
Margin="{TemplateBinding Padding}" /> |
||||
|
</ScrollViewer> |
||||
|
</Border> |
||||
|
</ControlTemplate> |
||||
|
</Setter> |
||||
|
</ControlTheme> |
||||
|
</ResourceDictionary> |
||||
|
|||||
@ -1,16 +1,24 @@ |
|||||
<Style xmlns="https://github.com/avaloniaui" Selector=":is(UserControl)"> |
<Style xmlns="https://github.com/avaloniaui" |
||||
<Setter Property="Template"> |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
||||
<ControlTemplate> |
Selector=":is(UserControl)"> |
||||
<ContentPresenter Name="PART_ContentPresenter" |
<Style.Resources> |
||||
Background="{TemplateBinding Background}" |
<ControlTheme x:Key="FluentUserControl" TargetType="UserControl"> |
||||
BorderBrush="{TemplateBinding BorderBrush}" |
<Setter Property="Template"> |
||||
BorderThickness="{TemplateBinding BorderThickness}" |
<ControlTemplate> |
||||
CornerRadius="{TemplateBinding CornerRadius}" |
<ContentPresenter Name="PART_ContentPresenter" |
||||
ContentTemplate="{TemplateBinding ContentTemplate}" |
Background="{TemplateBinding Background}" |
||||
Content="{TemplateBinding Content}" |
BorderBrush="{TemplateBinding BorderBrush}" |
||||
Padding="{TemplateBinding Padding}" |
BorderThickness="{TemplateBinding BorderThickness}" |
||||
VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" |
CornerRadius="{TemplateBinding CornerRadius}" |
||||
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"/> |
ContentTemplate="{TemplateBinding ContentTemplate}" |
||||
</ControlTemplate> |
Content="{TemplateBinding Content}" |
||||
</Setter> |
Padding="{TemplateBinding Padding}" |
||||
|
VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" |
||||
|
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"/> |
||||
|
</ControlTemplate> |
||||
|
</Setter> |
||||
|
</ControlTheme> |
||||
|
</Style.Resources> |
||||
|
|
||||
|
<Setter Property="Theme" Value="{StaticResource FluentUserControl}" /> |
||||
</Style> |
</Style> |
||||
|
|||||
@ -1,27 +1,30 @@ |
|||||
<Style xmlns="https://github.com/avaloniaui" Selector="Window"> |
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
<Setter Property="Background" Value="{DynamicResource SystemControlBackgroundAltHighBrush}"/> |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
||||
<Setter Property="TransparencyBackgroundFallback" Value="{DynamicResource SystemControlBackgroundAltHighBrush}" /> |
<ControlTheme x:Key="{x:Type Window}" TargetType="Window"> |
||||
<Setter Property="Foreground" Value="{DynamicResource SystemControlForegroundBaseHighBrush}"/> |
<Setter Property="Background" Value="{DynamicResource SystemControlBackgroundAltHighBrush}"/> |
||||
<Setter Property="FontSize" Value="{DynamicResource ControlContentThemeFontSize}"/> |
<Setter Property="TransparencyBackgroundFallback" Value="{DynamicResource SystemControlBackgroundAltHighBrush}" /> |
||||
<Setter Property="FontFamily" Value="{DynamicResource ContentControlThemeFontFamily}" /> |
<Setter Property="Foreground" Value="{DynamicResource SystemControlForegroundBaseHighBrush}"/> |
||||
<Setter Property="Template"> |
<Setter Property="FontSize" Value="{DynamicResource ControlContentThemeFontSize}"/> |
||||
<ControlTemplate> |
<Setter Property="FontFamily" Value="{DynamicResource ContentControlThemeFontFamily}" /> |
||||
<Panel> |
<Setter Property="Template"> |
||||
<Border Name="PART_TransparencyFallback" IsHitTestVisible="False" /> |
<ControlTemplate> |
||||
<Border Background="{TemplateBinding Background}" IsHitTestVisible="False" /> |
<Panel> |
||||
<Panel Background="Transparent" Margin="{TemplateBinding WindowDecorationMargin}" /> |
<Border Name="PART_TransparencyFallback" IsHitTestVisible="False" /> |
||||
<VisualLayerManager> |
<Border Background="{TemplateBinding Background}" IsHitTestVisible="False" /> |
||||
<VisualLayerManager.ChromeOverlayLayer> |
<Panel Background="Transparent" Margin="{TemplateBinding WindowDecorationMargin}" /> |
||||
<TitleBar /> |
<VisualLayerManager> |
||||
</VisualLayerManager.ChromeOverlayLayer> |
<VisualLayerManager.ChromeOverlayLayer> |
||||
<ContentPresenter Name="PART_ContentPresenter" |
<TitleBar /> |
||||
ContentTemplate="{TemplateBinding ContentTemplate}" |
</VisualLayerManager.ChromeOverlayLayer> |
||||
Content="{TemplateBinding Content}" |
<ContentPresenter Name="PART_ContentPresenter" |
||||
Margin="{TemplateBinding Padding}" |
ContentTemplate="{TemplateBinding ContentTemplate}" |
||||
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" |
Content="{TemplateBinding Content}" |
||||
VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}"/> |
Margin="{TemplateBinding Padding}" |
||||
</VisualLayerManager> |
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" |
||||
</Panel> |
VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}"/> |
||||
</ControlTemplate> |
</VisualLayerManager> |
||||
</Setter> |
</Panel> |
||||
</Style> |
</ControlTemplate> |
||||
|
</Setter> |
||||
|
</ControlTheme> |
||||
|
</ResourceDictionary> |
||||
|
|||||
@ -1,47 +1,57 @@ |
|||||
<Styles xmlns="https://github.com/avaloniaui" |
<ResourceDictionary xmlns="https://github.com/avaloniaui" |
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
||||
x:DataType="WindowNotificationManager" |
x:CompileBindings="True" |
||||
x:CompileBindings="True"> |
x:DataType="WindowNotificationManager"> |
||||
<Style Selector="WindowNotificationManager"> |
<ControlTheme x:Key="{x:Type WindowNotificationManager}" TargetType="WindowNotificationManager"> |
||||
<Setter Property="Margin" Value="0 0"/> |
<Setter Property="Margin" Value="0 0" /> |
||||
<Setter Property="Template"> |
<Setter Property="Template"> |
||||
<ControlTemplate> |
<ControlTemplate> |
||||
<ReversibleStackPanel Name="PART_Items"> |
<ReversibleStackPanel Name="PART_Items"> |
||||
<ReversibleStackPanel.DataTemplates> |
<ReversibleStackPanel.DataTemplates> |
||||
<DataTemplate DataType="INotification"> |
<DataTemplate DataType="INotification"> |
||||
<StackPanel Spacing="8" Margin="12" TextElement.Foreground="{DynamicResource SystemControlForegroundBaseHighBrush}"> |
<StackPanel |
||||
<TextBlock Text="{Binding Title}" FontWeight="Medium" /> |
Margin="12" |
||||
<TextBlock MaxHeight="80" Text="{Binding Message}" TextWrapping="Wrap" Margin="0,0,12,0"/> |
Spacing="8" |
||||
|
TextElement.Foreground="{DynamicResource SystemControlForegroundBaseHighBrush}"> |
||||
|
<TextBlock FontWeight="Medium" Text="{Binding Title}" /> |
||||
|
<TextBlock |
||||
|
MaxHeight="80" |
||||
|
Margin="0,0,12,0" |
||||
|
Text="{Binding Message}" |
||||
|
TextWrapping="Wrap" /> |
||||
</StackPanel> |
</StackPanel> |
||||
</DataTemplate> |
</DataTemplate> |
||||
<DataTemplate DataType="x:String"> |
<DataTemplate DataType="x:String"> |
||||
<TextBlock Text="{Binding }" Margin="12" Foreground="{DynamicResource SystemControlForegroundBaseHighBrush}" /> |
<TextBlock |
||||
|
Margin="12" |
||||
|
Foreground="{DynamicResource SystemControlForegroundBaseHighBrush}" |
||||
|
Text="{Binding}" /> |
||||
</DataTemplate> |
</DataTemplate> |
||||
</ReversibleStackPanel.DataTemplates> |
</ReversibleStackPanel.DataTemplates> |
||||
</ReversibleStackPanel> |
</ReversibleStackPanel> |
||||
</ControlTemplate> |
</ControlTemplate> |
||||
</Setter> |
</Setter> |
||||
</Style> |
|
||||
|
|
||||
<Style Selector="WindowNotificationManager:topleft /template/ ReversibleStackPanel#PART_Items"> |
<Style Selector="^:topleft /template/ ReversibleStackPanel#PART_Items"> |
||||
<Setter Property="VerticalAlignment" Value="Top"/> |
<Setter Property="VerticalAlignment" Value="Top" /> |
||||
<Setter Property="HorizontalAlignment" Value="Left"/> |
<Setter Property="HorizontalAlignment" Value="Left" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="WindowNotificationManager:topright /template/ ReversibleStackPanel#PART_Items"> |
<Style Selector="^:topright /template/ ReversibleStackPanel#PART_Items"> |
||||
<Setter Property="VerticalAlignment" Value="Top"/> |
<Setter Property="VerticalAlignment" Value="Top" /> |
||||
<Setter Property="HorizontalAlignment" Value="Right"/> |
<Setter Property="HorizontalAlignment" Value="Right" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="WindowNotificationManager:bottomleft /template/ ReversibleStackPanel#PART_Items"> |
<Style Selector="^:bottomleft /template/ ReversibleStackPanel#PART_Items"> |
||||
<Setter Property="ReverseOrder" Value="True"/> |
<Setter Property="ReverseOrder" Value="True" /> |
||||
<Setter Property="VerticalAlignment" Value="Bottom"/> |
<Setter Property="VerticalAlignment" Value="Bottom" /> |
||||
<Setter Property="HorizontalAlignment" Value="Left"/> |
<Setter Property="HorizontalAlignment" Value="Left" /> |
||||
</Style> |
</Style> |
||||
|
|
||||
<Style Selector="WindowNotificationManager:bottomright /template/ ReversibleStackPanel#PART_Items"> |
<Style Selector="^:bottomright /template/ ReversibleStackPanel#PART_Items"> |
||||
<Setter Property="ReverseOrder" Value="True"/> |
<Setter Property="ReverseOrder" Value="True" /> |
||||
<Setter Property="VerticalAlignment" Value="Bottom"/> |
<Setter Property="VerticalAlignment" Value="Bottom" /> |
||||
<Setter Property="HorizontalAlignment" Value="Right"/> |
<Setter Property="HorizontalAlignment" Value="Right" /> |
||||
</Style> |
</Style> |
||||
</Styles> |
</ControlTheme> |
||||
|
</ResourceDictionary> |
||||
|
|||||
Some files were not shown because too many files changed in this diff
Loading…
Reference in new issue