调整代码

This commit is contained in:
GG Z
2026-02-22 20:03:42 +08:00
parent 2ad3d0fde0
commit 7e2d5be3cd
258 changed files with 2916 additions and 5013 deletions

View File

@@ -3,7 +3,7 @@
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:controls="clr-namespace:Melskin.Controls"
xmlns:decorations="clr-namespace:Melskin.Controls.Decorations">
<Style TargetType="{x:Type controls:Card}">
<Style x:Key="FloatLightedCardStyle" TargetType="{x:Type controls:Card}">
<Setter Property="Focusable" Value="False" />
<Setter Property="Padding" Value="10,8" />
<Setter Property="CornerRadius" Value="4" />
@@ -54,4 +54,39 @@
</Setter.Value>
</Setter>
</Style>
<Style TargetType="{x:Type controls:Card}">
<Setter Property="Focusable" Value="False" />
<Setter Property="Padding" Value="10,8" />
<Setter Property="CornerRadius" Value="4" />
<Setter Property="HorizontalContentAlignment" Value="Center" />
<Setter Property="VerticalContentAlignment" Value="Center" />
<Setter Property="Background" Value="{DynamicResource BackgroundContainerBrush}" />
<Setter Property="Foreground" Value="{DynamicResource TextPrimaryBrush}" />
<Setter Property="BorderBrush" Value="{DynamicResource BorderNormalBrush}" />
<Setter Property="BorderThickness" Value="1" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type controls:Card}">
<Border
x:Name="mainBorder"
Padding="0"
Background="{TemplateBinding Background}"
BorderBrush="{TemplateBinding BorderBrush}"
BorderThickness="{TemplateBinding BorderThickness}"
CornerRadius="{TemplateBinding CornerRadius}">
<ContentPresenter
x:Name="contentPresenter"
Margin="{TemplateBinding Padding}"
HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
Focusable="False"
RecognizesAccessKey="True"
SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
TextElement.Foreground="{TemplateBinding Foreground}" />
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</ResourceDictionary>