|
3 | 3 |
|
4 | 4 | namespace System.Windows.Forms; |
5 | 5 |
|
| 6 | +/// <summary> |
| 7 | +/// Cache of colors for different button states. |
| 8 | +/// </summary> |
| 9 | +internal static class DarkModeButtonColors |
| 10 | +{ |
| 11 | + // Normal Button (non-default) |
| 12 | + |
| 13 | + /// <summary> |
| 14 | + /// Button background color for normal state (#2B2B2B). |
| 15 | + /// </summary> |
| 16 | + public static Color NormalBackgroundColor => Color.FromArgb(43, 43, 43); // #2B2B2B |
| 17 | + |
| 18 | + /// <summary> |
| 19 | + /// Button background color for hover state (#3B3B3B). |
| 20 | + /// </summary> |
| 21 | + public static Color HoverBackgroundColor => Color.FromArgb(59, 59, 59); // #3B3B3B |
| 22 | + |
| 23 | + /// <summary> |
| 24 | + /// Button background color for pressed state (#4B4B4B). |
| 25 | + /// </summary> |
| 26 | + public static Color PressedBackgroundColor => Color.FromArgb(75, 75, 75); // #4B4B4B |
| 27 | + |
| 28 | + /// <summary> |
| 29 | + /// Button background color for disabled state (#252525). |
| 30 | + /// </summary> |
| 31 | + public static Color DisabledBackgroundColor => Color.FromArgb(37, 37, 37); // #252525 |
| 32 | + |
| 33 | + // Default Button |
| 34 | + |
| 35 | + /// <summary> |
| 36 | + /// Default button background color (#2B2B2B). |
| 37 | + /// </summary> |
| 38 | + public static Color DefaultBackgroundColor => NormalBackgroundColor; // #2B2B2B |
| 39 | + |
| 40 | + /// <summary> |
| 41 | + /// Default button hover background color (#3B3B3B). |
| 42 | + /// </summary> |
| 43 | + public static Color DefaultHoverBackgroundColor => HoverBackgroundColor; // #3B3B3B |
| 44 | + |
| 45 | + /// <summary> |
| 46 | + /// Default button pressed background color (#4B4B4B). |
| 47 | + /// </summary> |
| 48 | + public static Color DefaultPressedBackgroundColor => PressedBackgroundColor; // #4B4B4B |
| 49 | + |
| 50 | + /// <summary> |
| 51 | + /// Default button disabled background color (#252525). |
| 52 | + /// </summary> |
| 53 | + public static Color DefaultDisabledBackgroundColor => DisabledBackgroundColor; // #252525 |
| 54 | + |
| 55 | + // Text Colors |
| 56 | + |
| 57 | + /// <summary> |
| 58 | + /// Normal text color (#E0E0E0). |
| 59 | + /// </summary> |
| 60 | + public static Color NormalTextColor => Color.FromArgb(224, 224, 224); // #E0E0E0 |
| 61 | + |
| 62 | + /// <summary> |
| 63 | + /// Default button text color (#FFFFFF). |
| 64 | + /// </summary> |
| 65 | + public static Color DefaultTextColor => Color.White; // #FFFFFF |
| 66 | + |
| 67 | + /// <summary> |
| 68 | + /// Disabled text color (#606060, ~40% opacity). |
| 69 | + /// </summary> |
| 70 | + public static Color DisabledTextColor => Color.FromArgb(96, 96, 96); // #606060 |
| 71 | + |
| 72 | + /// <summary> |
| 73 | + /// Gets the single border color for a button in dark mode (#969696). |
| 74 | + /// </summary> |
| 75 | + public static Color SingleBorderColor => Color.FromArgb(150, 150, 150); // #969696 |
| 76 | + |
6 | 77 | /// <summary> |
7 | | - /// Cache of colors for different button states. |
8 | | - /// </summary> |
9 | | - internal static class DarkModeButtonColors |
10 | | - { |
11 | | - // Normal Button (non-default) |
12 | | - |
13 | | - /// <summary> |
14 | | - /// Button background color for normal state (#2B2B2B). |
15 | | - /// </summary> |
16 | | - public static Color NormalBackgroundColor => Color.FromArgb(43, 43, 43); // #2B2B2B |
17 | | - |
18 | | - /// <summary> |
19 | | - /// Button background color for hover state (#3B3B3B). |
20 | | - /// </summary> |
21 | | - public static Color HoverBackgroundColor => Color.FromArgb(59, 59, 59); // #3B3B3B |
22 | | - |
23 | | - /// <summary> |
24 | | - /// Button background color for pressed state (#4B4B4B). |
25 | | - /// </summary> |
26 | | - public static Color PressedBackgroundColor => Color.FromArgb(75, 75, 75); // #4B4B4B |
27 | | - |
28 | | - /// <summary> |
29 | | - /// Button background color for disabled state (#252525). |
30 | | - /// </summary> |
31 | | - public static Color DisabledBackgroundColor => Color.FromArgb(37, 37, 37); // #252525 |
32 | | - |
33 | | - // Default Button |
34 | | - |
35 | | - /// <summary> |
36 | | - /// Default button background color (#2B2B2B). |
37 | | - /// </summary> |
38 | | - public static Color DefaultBackgroundColor => NormalBackgroundColor; // #2B2B2B |
39 | | - |
40 | | - /// <summary> |
41 | | - /// Default button hover background color (#3B3B3B). |
42 | | - /// </summary> |
43 | | - public static Color DefaultHoverBackgroundColor => HoverBackgroundColor; // #3B3B3B |
44 | | - |
45 | | - /// <summary> |
46 | | - /// Default button pressed background color (#4B4B4B). |
47 | | - /// </summary> |
48 | | - public static Color DefaultPressedBackgroundColor => PressedBackgroundColor; // #4B4B4B |
49 | | - |
50 | | - /// <summary> |
51 | | - /// Default button disabled background color (#252525). |
52 | | - /// </summary> |
53 | | - public static Color DefaultDisabledBackgroundColor => DisabledBackgroundColor; // #252525 |
54 | | - |
55 | | - // Text Colors |
56 | | - |
57 | | - /// <summary> |
58 | | - /// Normal text color (#E0E0E0). |
59 | | - /// </summary> |
60 | | - public static Color NormalTextColor => Color.FromArgb(224, 224, 224); // #E0E0E0 |
61 | | - |
62 | | - /// <summary> |
63 | | - /// Default button text color (#FFFFFF). |
64 | | - /// </summary> |
65 | | - public static Color DefaultTextColor => Color.White; // #FFFFFF |
66 | | - |
67 | | - /// <summary> |
68 | | - /// Disabled text color (#606060, ~40% opacity). |
69 | | - /// </summary> |
70 | | - public static Color DisabledTextColor => Color.FromArgb(96, 96, 96); // #606060 |
71 | | - |
72 | | - /// <summary> |
73 | | - /// Gets the single border color for a button in dark mode (#969696). |
74 | | - /// </summary> |
75 | | - public static Color SingleBorderColor => Color.FromArgb(150, 150, 150); // #969696 |
76 | | - |
77 | | - /// <summary> |
78 | | - /// Gets the single border color for a default button in dark mode (#D2D2D2). |
79 | | - /// </summary> |
80 | | - public static Color DefaultSingleBorderColor => Color.FromArgb(210, 210, 210); // #D2D2D2 |
81 | | - |
82 | | - /// <summary> |
83 | | - /// Gets the single border color for a pressed button in dark mode (#DCDCDC). |
84 | | - /// </summary> |
85 | | - public static Color PressedSingleBorderColor => Color.FromArgb(220, 220, 220); // #DCDCDC |
86 | | - |
87 | | - /// <summary> |
88 | | - /// Button top-left border color (#555555). |
89 | | - /// </summary> |
90 | | - public static Color TopLeftBorderColor => Color.FromArgb(85, 85, 85); // #555555 |
91 | | - |
92 | | - /// <summary> |
93 | | - /// Button bottom-right border color (#222222). |
94 | | - /// </summary> |
95 | | - public static Color BottomRightBorderColor => Color.FromArgb(34, 34, 34); // #222222 |
96 | | - |
97 | | - // Focus Colors |
98 | | - |
99 | | - /// <summary> |
100 | | - /// Focus indicator color (#F0F0F0). |
101 | | - /// </summary> |
102 | | - public static Color FocusIndicatorColor => Color.FromArgb(240, 240, 240); // #F0F0F0 |
103 | | - |
104 | | - /// <summary> |
105 | | - /// Default button focus indicator color (#FFFFFF). |
106 | | - /// </summary> |
107 | | - public static Color DefaultFocusIndicatorColor => Color.White; // #FFFFFF |
108 | | - |
109 | | - // Shadow and Highlight Colors for 3D effects |
110 | | - |
111 | | - /// <summary> |
112 | | - /// Shadow color for dark areas (#282828). |
113 | | - /// </summary> |
114 | | - public static Color ShadowDarkColor { get; } = Color.FromArgb(40, 40, 40); // #282828 |
115 | | - |
116 | | - /// <summary> |
117 | | - /// Shadow color for mid-tone areas (#3C3C3C). |
118 | | - /// </summary> |
119 | | - public static Color ShadowColor { get; } = Color.FromArgb(60, 60, 60); // #3C3C3C |
120 | | - |
121 | | - /// <summary> |
122 | | - /// Highlight color for button edges (#6E6E6E). |
123 | | - /// </summary> |
124 | | - public static Color HighlightColor { get; } = Color.FromArgb(110, 110, 110); // #6E6E6E |
125 | | - |
126 | | - /// <summary> |
127 | | - /// Bright highlight color for button edges (#828282). |
128 | | - /// </summary> |
129 | | - public static Color HighlightBrightColor { get; } = Color.FromArgb(130, 130, 130); // #828282 |
130 | | - |
131 | | - /// <summary> |
132 | | - /// Disabled border dark color (#2D2D2D). |
133 | | - /// </summary> |
134 | | - public static Color DisabledBorderDarkColor { get; } = Color.FromArgb(45, 45, 45); // #2D2D2D |
135 | | - |
136 | | - /// <summary> |
137 | | - /// Disabled border light color (#373737). |
138 | | - /// </summary> |
139 | | - public static Color DisabledBorderLightColor { get; } = Color.FromArgb(55, 55, 55); // #373737 |
140 | | - |
141 | | - /// <summary> |
142 | | - /// Disabled border mid color (#323232). |
143 | | - /// </summary> |
144 | | - public static Color DisabledBorderMidColor { get; } = Color.FromArgb(50, 50, 50); // #323232 |
145 | | - } |
| 78 | + /// Gets the single border color for a default button in dark mode (#D2D2D2). |
| 79 | + /// </summary> |
| 80 | + public static Color DefaultSingleBorderColor => Color.FromArgb(210, 210, 210); // #D2D2D2 |
| 81 | + |
| 82 | + /// <summary> |
| 83 | + /// Gets the single border color for a pressed button in dark mode (#DCDCDC). |
| 84 | + /// </summary> |
| 85 | + public static Color PressedSingleBorderColor => Color.FromArgb(220, 220, 220); // #DCDCDC |
| 86 | + |
| 87 | + /// <summary> |
| 88 | + /// Button top-left border color (#555555). |
| 89 | + /// </summary> |
| 90 | + public static Color TopLeftBorderColor => Color.FromArgb(85, 85, 85); // #555555 |
| 91 | + |
| 92 | + /// <summary> |
| 93 | + /// Button bottom-right border color (#222222). |
| 94 | + /// </summary> |
| 95 | + public static Color BottomRightBorderColor => Color.FromArgb(34, 34, 34); // #222222 |
| 96 | + |
| 97 | + // Focus Colors |
| 98 | + |
| 99 | + /// <summary> |
| 100 | + /// Focus indicator color (#F0F0F0). |
| 101 | + /// </summary> |
| 102 | + public static Color FocusIndicatorColor => Color.FromArgb(240, 240, 240); // #F0F0F0 |
| 103 | + |
| 104 | + /// <summary> |
| 105 | + /// Default button focus indicator color (#FFFFFF). |
| 106 | + /// </summary> |
| 107 | + public static Color DefaultFocusIndicatorColor => Color.White; // #FFFFFF |
| 108 | + |
| 109 | + // Shadow and Highlight Colors for 3D effects |
| 110 | + |
| 111 | + /// <summary> |
| 112 | + /// Shadow color for dark areas (#282828). |
| 113 | + /// </summary> |
| 114 | + public static Color ShadowDarkColor { get; } = Color.FromArgb(40, 40, 40); // #282828 |
| 115 | + |
| 116 | + /// <summary> |
| 117 | + /// Shadow color for mid-tone areas (#3C3C3C). |
| 118 | + /// </summary> |
| 119 | + public static Color ShadowColor { get; } = Color.FromArgb(60, 60, 60); // #3C3C3C |
| 120 | + |
| 121 | + /// <summary> |
| 122 | + /// Highlight color for button edges (#6E6E6E). |
| 123 | + /// </summary> |
| 124 | + public static Color HighlightColor { get; } = Color.FromArgb(110, 110, 110); // #6E6E6E |
| 125 | + |
| 126 | + /// <summary> |
| 127 | + /// Bright highlight color for button edges (#828282). |
| 128 | + /// </summary> |
| 129 | + public static Color HighlightBrightColor { get; } = Color.FromArgb(130, 130, 130); // #828282 |
| 130 | + |
| 131 | + /// <summary> |
| 132 | + /// Disabled border dark color (#2D2D2D). |
| 133 | + /// </summary> |
| 134 | + public static Color DisabledBorderDarkColor { get; } = Color.FromArgb(45, 45, 45); // #2D2D2D |
| 135 | + |
| 136 | + /// <summary> |
| 137 | + /// Disabled border light color (#373737). |
| 138 | + /// </summary> |
| 139 | + public static Color DisabledBorderLightColor { get; } = Color.FromArgb(55, 55, 55); // #373737 |
| 140 | + |
| 141 | + /// <summary> |
| 142 | + /// Disabled border mid color (#323232). |
| 143 | + /// </summary> |
| 144 | + public static Color DisabledBorderMidColor { get; } = Color.FromArgb(50, 50, 50); // #323232 |
| 145 | +} |
0 commit comments