1
1
<ResourceDictionary xmlns =" https://github.com/avaloniaui"
2
2
xmlns : x =" http://schemas.microsoft.com/winfx/2006/xaml" >
3
- <Color x : Key =" ButtonDefaultBackgroundColor" >White</Color >
4
- <Color x : Key =" ButtonBackgroundActiveColor" >LightGray</Color >
5
- <Color x : Key =" ButtonBackgroundPointerOverColor" >red</Color >
6
- <Color x : Key =" ButtonBorderTopColor" >#d6d6d6</Color >
7
- <Color x : Key =" ButtonBorderBottomColor" >#b5b5b5</Color >
8
- <!-- TODO: Appkit buttons have DD at the bottom, EE at the top & fading ... -->
9
- <Color x : Key =" ButtonPrimaryForegroundColor" >White</Color >
10
- <Color x : Key =" CodeFontColor" >SlateBlue</Color >
11
- <Color x : Key =" CodeBackgroundColor" >#f7f7f7</Color >
12
- <!-- <Color x:Key="SelectionUnfocusedColor">#f3f3f3</Color> -->
13
- <Color x : Key =" TabUnselectedColor" >#f2f2f2</Color >
14
- <Color x : Key =" PanelBorderColor" >#ececec</Color >
15
- <Color x : Key =" PanelBackgroundColor" >#f7f7f7</Color >
16
- <Color x : Key =" SidePanelBackgroundColor" >#e5e5e5</Color >
17
- <Color x : Key =" TabStripBorderColor" >#e6e6e6</Color >
3
+ <Color x : Key =" BackgroundColor" >#ffffff</Color >
4
+ <Color x : Key =" ForegroundColor" >#000000</Color >
18
5
6
+ <Color x : Key =" AccentForegroundColor" >#ffffff</Color >
7
+
8
+ <Color x : Key =" ControlBorderHighColor" >#4a000000</Color > <!-- 29% -->
9
+ <Color x : Key =" ControlBorderLowColor" >#29000000</Color > <!-- 16% -->
10
+ <!-- TODO: Appkit buttons have DD at the bottom, EE at the top & fading -> try sub-pixel rendering (UseLayoutRounding) (s. `default button issues.psd` ... -->
19
11
20
12
<CornerRadius x : Key =" ControlCornerRadius" >5</CornerRadius >
21
13
22
- <!-- Typography -->
23
- <SolidColorBrush x : Key =" TextPrimaryColor" Color =" Black" />
24
- <SolidColorBrush x : Key =" TextOnDarkColor" Color =" White" />
25
- <SolidColorBrush x : Key =" TextSecondaryColor" Color =" Black" Opacity =" 0.5" />
26
- <SolidColorBrush x : Key =" TextTertiaryColor" Color =" Black" Opacity =" 0.25" />
27
- <SolidColorBrush x : Key =" SelectionUnfocused" Color =" Black" Opacity =" 0.09" />
28
- <x : Double x : Key =" H1FontSize" >16</x : Double >
29
- <FontWeight x : Key =" H1FontWeight" >Bold</FontWeight >
30
- <Thickness x : Key =" H1Margins" >0,0,0,10</Thickness >
31
- <FontFamily x : Key =" CodeFontFamily" >"Courier New, Courier, monospace"</FontFamily >
14
+ <Thickness x : Key =" BorderThickness" >1</Thickness >
15
+ <Thickness x : Key =" ControlBorderThickness" >1</Thickness >
32
16
33
- <SolidColorBrush x : Key =" Highlight " Color = " {DynamicResource HighlightColor} " / >
17
+ <x : Double x : Key =" FontSize " >13</ x : Double >
34
18
35
- <SolidColorBrush x : Key =" PanelBorder" Color =" {DynamicResource PanelBorderColor}" />
36
- <SolidColorBrush x : Key =" PanelBackground" Color =" {DynamicResource PanelBackgroundColor}" />
37
- <SolidColorBrush x : Key =" SidePanelBackground" Color =" {DynamicResource SidePanelBackgroundColor}" />
38
- <Thickness x : Key =" PanelBorderThickness" >1</Thickness >
39
19
40
- <Thickness x : Key =" TabItemPadding" >8 2</Thickness >
20
+ <SolidColorBrush x : Key =" ForegroundHighBrush" Color =" {StaticResource ForegroundColor}" />
21
+ <SolidColorBrush x : Key =" ForegroundMidBrush" Color =" {StaticResource ForegroundColor}" Opacity =" 0.5" />
22
+ <SolidColorBrush x : Key =" ForegroundLowBrush" Color =" {StaticResource ForegroundColor}" Opacity =" 0.25" />
41
23
42
- <Thickness x : Key =" ButtonDefaultBorderThickness" >1</Thickness >
43
- <Thickness x : Key =" ButtonDefaultPadding" >10 2</Thickness >
44
- <x : Double x : Key =" ButtonDefaultFontSize" >13</x : Double >
45
- <FontWeight x : Key =" ButtonDefaultFontWeight" >400</FontWeight >
46
- <SolidColorBrush x : Key =" ButtonDefaultBackground" Color =" {DynamicResource ButtonDefaultBackgroundColor}" />
47
- <SolidColorBrush x : Key =" ButtonDefaultPressedBackground" Color =" {DynamicResource ButtonBackgroundActiveColor}" />
48
- <LinearGradientBrush x : Key =" ButtonDefaultBorder" StartPoint =" 0%,0%" EndPoint =" 0%,100%" >
49
- <GradientStop Offset =" 0" Color =" {DynamicResource ButtonBorderTopColor}" />
50
- <GradientStop Offset =" 1" Color =" {DynamicResource ButtonBorderBottomColor}" />
51
- </LinearGradientBrush >
52
- <SolidColorBrush x : Key =" ButtonDisabledBorder" Color =" {DynamicResource ButtonBorderTopColor}" />
53
- <SolidColorBrush x : Key =" ButtonDisabledBackground" Color =" {DynamicResource ButtonDefaultBackgroundColor}" Opacity =" 50" />
54
- <SolidColorBrush x : Key =" ButtonPrimaryForeground" Color =" {DynamicResource ButtonPrimaryForegroundColor}" />
55
- <SolidColorBrush x : Key =" AccentDefault" Color =" {DynamicResource SystemAccentColor}" />
56
- <SolidColorBrush x : Key =" AccentDefaultDark" Color =" {DynamicResource SystemAccentColorDark1}" />
57
- <SolidColorBrush x : Key =" TabStripBorder" Color =" {DynamicResource TabStripBorderColor}" />
24
+ <SolidColorBrush x : Key =" LayoutBackgroundHighBrush" Color =" {StaticResource ForegroundColor}" Opacity =" 0.12" />
25
+ <SolidColorBrush x : Key =" LayoutBackgroundLowBrush" Color =" {StaticResource ForegroundColor}" Opacity =" 0.03" />
58
26
59
- <LinearGradientBrush x : Key =" ButtonPrimaryBackground" StartPoint =" 0%,0%" EndPoint =" 0%,100%" >
60
- <GradientStop Offset =" 0" Color =" {DynamicResource SystemAccentColorLight1}" />
61
- <GradientStop Offset =" 1" Color =" {DynamicResource SystemAccentColor}" />
27
+ <SolidColorBrush x : Key =" LayoutBorderMidBrush" Color =" {StaticResource ForegroundColor}" Opacity =" 0.07" />
28
+ <SolidColorBrush x : Key =" LayoutBorderLowBrush" Color =" {StaticResource ForegroundColor}" Opacity =" 0.02" />
29
+
30
+ <SolidColorBrush x : Key =" ControlForegroundAccentHighBrush" Color =" {StaticResource AccentForegroundColor}" />
31
+
32
+ <SolidColorBrush x : Key =" ControlBackgroundHighBrush" Color =" {StaticResource BackgroundColor}" />
33
+ <SolidColorBrush x : Key =" ControlBackgroundMidBrush" Color =" {StaticResource ForegroundColor}" Opacity =" 0.1" />
34
+ <SolidColorBrush x : Key =" ControlBackgroundLowBrush" Color =" {StaticResource ForegroundColor}" Opacity =" 0.9" />
35
+ <SolidColorBrush x : Key =" ControlBackgroundActiveHighBrush" Color =" {StaticResource ForegroundColor}" Opacity =" 0.05" />
36
+ <LinearGradientBrush x : Key =" ControlBackgroundAccentRaisedBrush" StartPoint =" 0%,0%" EndPoint =" 0%,100%" >
37
+ <GradientStop Offset =" 0" Color =" {StaticResource SystemAccentColorLight1}" />
38
+ <GradientStop Offset =" 1" Color =" {StaticResource SystemAccentColor}" />
39
+ </LinearGradientBrush >
40
+ <LinearGradientBrush x : Key =" ControlBackgroundAccentRecessedBrush" StartPoint =" 0%,0%" EndPoint =" 0%,100%" >
41
+ <GradientStop Offset =" 0" Color =" {StaticResource SystemAccentColor}" />
42
+ <GradientStop Offset =" 1" Color =" {StaticResource SystemAccentColorDark1}" />
62
43
</LinearGradientBrush >
63
- <LinearGradientBrush x : Key =" ButtonPrimaryPressedBackground" StartPoint =" 0%,0%" EndPoint =" 0%,100%" >
64
- <GradientStop Offset =" 0" Color =" {DynamicResource SystemAccentColor}" />
65
- <GradientStop Offset =" 1" Color =" {DynamicResource SystemAccentColorDark1}" />
44
+ <SolidColorBrush x : Key =" ControlBackgroundDisabledHighBrush"
45
+ Color =" {StaticResource BackgroundColor}" Opacity =" 0.5" />
46
+ <LinearGradientBrush x : Key =" ControlBorderRaisedBrush" StartPoint =" 0%,0%" EndPoint =" 0%,100%" >
47
+ <GradientStop Offset =" 0" Color =" {StaticResource ControlBorderLowColor}" />
48
+ <GradientStop Offset =" 1" Color =" {StaticResource ControlBorderHighColor}" />
66
49
</LinearGradientBrush >
67
- <VisualBrush x : Key =" ButtonPrimaryBackgroundPrecise" Stretch =" Fill" >
50
+ <LinearGradientBrush x : Key =" ControlBorderRecessedBrush" StartPoint =" 0%,0%" EndPoint =" 0%,100%" >
51
+ <GradientStop Offset =" 0" Color =" {StaticResource ControlBorderHighColor}" />
52
+ <GradientStop Offset =" 1" Color =" {StaticResource ControlBorderLowColor}" />
53
+ </LinearGradientBrush >
54
+ <SolidColorBrush x : Key =" ControlBorderDisabledBrush" Color =" {StaticResource ControlBorderLowColor}" />
55
+
56
+ <!-- Button Resources -->
57
+ <Thickness x : Key =" ButtonPadding" >10 2</Thickness >
58
+ <FontWeight x : Key =" ButtonFontWeight" >400</FontWeight >
59
+
60
+ <!-- TabControl & TabItem Resources -->
61
+ <Color x : Key =" TabControlBackgroundColor" >#f2f2f2</Color >
62
+ <Thickness x : Key =" TabItemPadding" >8 2</Thickness >
63
+ <SolidColorBrush x : Key =" TabControlBackgroundBrush" Color =" {StaticResource TabControlBackgroundColor}" />
64
+
65
+ <!-- TODO: To be replaced by templated button control (accent colour with hard-coded gradient overlay) -->
66
+ <VisualBrush x : Key =" TempButtonPrimaryBackgroundPrecise" Stretch =" Fill" >
68
67
<VisualBrush .Visual>
69
68
<Panel >
70
- <!-- <Rectangle Fill="{DynamicResource SystemAccentColor}" Width="20" Height="20" /> // might not have access to Logical tree where resources are defined-->
69
+ <!-- <Rectangle Fill="{StaticResource SystemAccentColor}" Width="20" Height="20" /> // might not have access to Logical tree where resources are defined-->
71
70
<Rectangle Fill =" #007aff" Width =" 20" Height =" 20" />
72
71
<Rectangle >
73
72
<Rectangle .Fill>
84
83
</VisualBrush .Visual>
85
84
</VisualBrush >
86
85
87
- <VisualBrush x : Key =" ButtonPrimaryPressedBackgroundPrecise " Stretch =" Fill" >
86
+ <VisualBrush x : Key =" TempButtonPrimaryPressedBackgroundPrecise " Stretch =" Fill" >
88
87
<VisualBrush .Visual>
89
88
<Panel >
90
- <!-- <Rectangle Fill="{DynamicResource AccentDefaultDark }" Width="20" Height="20" /> -->
89
+ <!-- <Rectangle Fill="{StaticResource ControlBackgroundAccentMidBrush }" Width="20" Height="20" /> -->
91
90
<Rectangle Fill =" #005FC6" Width =" 20" Height =" 20" />
92
91
<Rectangle >
93
92
<Rectangle .Fill>
103
102
</Panel >
104
103
</VisualBrush .Visual>
105
104
</VisualBrush >
106
-
107
105
</ResourceDictionary >
0 commit comments