mirror of
https://github.com/Artemis-RGB/Artemis
synced 2026-11-12 03:48:56 +00:00
Fixed color picker button
This commit is contained in:
1 parent
0116bac346
commit
73933ee324
3 files changed
+20
-20
No files matched your search
@@ -2,14 +2,17 @@
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:controls="clr-namespace:FluentAvalonia.UI.Controls;assembly=FluentAvalonia">
|
||||
<Design.PreviewWith>
|
||||
<Border Padding="20">
|
||||
<Grid Height="24" ColumnDefinitions="*">
|
||||
<Border Padding="20" Width="600" Height="600">
|
||||
<Grid Height="24" ColumnDefinitions="*" Width="200">
|
||||
<TextBox Classes="condensed"
|
||||
Text="#FFFF0000"
|
||||
Padding="2 2 30 2">
|
||||
Padding="2 2 30 2"
|
||||
>
|
||||
</TextBox>
|
||||
<controls:ColorPickerButton Classes="contained-color-picker-button"
|
||||
ShowAcceptDismissButtons="False" />
|
||||
Color="Red"
|
||||
ShowAcceptDismissButtons="False"
|
||||
/>
|
||||
</Grid>
|
||||
</Border>
|
||||
</Design.PreviewWith>
|
||||
@@ -25,23 +28,21 @@
|
||||
<Setter Property="HorizontalAlignment" Value="Right" />
|
||||
<Setter Property="Cursor" Value="Hand" />
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate>
|
||||
<Button Name="MainButton"
|
||||
Padding="0"
|
||||
BorderThickness="0"
|
||||
CornerRadius="{TemplateBinding CornerRadius}">
|
||||
<ControlTemplate>
|
||||
<Button Name="ShowFlyoutButton"
|
||||
CornerRadius="{TemplateBinding CornerRadius}"
|
||||
HorizontalContentAlignment="Stretch"
|
||||
Padding="0">
|
||||
<Grid ColumnDefinitions="*,Auto">
|
||||
<Border BorderBrush="{DynamicResource ColorPickerButtonOutline}"
|
||||
BorderThickness="1"
|
||||
HorizontalAlignment="Stretch" VerticalAlignment="Stretch"
|
||||
MinWidth="18" MinHeight="18"
|
||||
Background="{TemplateBinding Color, Converter={StaticResource ColorBrushConv}}"
|
||||
CornerRadius="{TemplateBinding CornerRadius}">
|
||||
<controls:FAColorPicker Name="ColorPicker" IsVisible="False" />
|
||||
</Border>
|
||||
</Button>
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
CornerRadius="{TemplateBinding CornerRadius}"/>
|
||||
</Grid>
|
||||
</Button>
|
||||
</ControlTemplate>
|
||||
</Setter>
|
||||
</Style>
|
||||
|
||||
|
||||
Reference in new issue
Block a user