1155 references to SystemColors
Accessibility_Core_App (3)
CommonControl2.Designer.cs (1)
132
this.richTextBox1.BackColor = System.Drawing.
SystemColors
.Window;
ContainerControls2.Designer.cs (1)
290
groupBox5.ForeColor =
SystemColors
.Control;
DataBindingExample.Designer.cs (1)
168
this.richTextBox1.BackColor = System.Drawing.
SystemColors
.Window;
BinaryFormatTests (1)
FormatTests\FormattedObject\BinaryFormatWriterTests.cs (1)
206
SystemColors
.ButtonFace
DesignSurface (1)
MainForm.Designer.cs (1)
74
this.splitContainer.Panel1.BackColor = System.Drawing.
SystemColors
.Window;
PresentationUI (11)
MS\Internal\Documents\Application\DocumentPropertiesDialog.Designer.cs (5)
145
this._tabControl.BackColor = System.Drawing.
SystemColors
.Control;
150
this._summaryTab.BackColor = System.Drawing.
SystemColors
.Control;
218
this._title.BackColor = System.Drawing.
SystemColors
.Control;
345
this._author.BackColor = System.Drawing.
SystemColors
.Control;
422
this._infoTab.BackColor = System.Drawing.
SystemColors
.Control;
MS\Internal\Documents\DialogBaseForm.cs (1)
71
BackColor = System.Drawing.
SystemColors
.Control;
MS\Internal\Documents\DialogDivider.cs (1)
80
new Pen(new SolidBrush(System.Drawing.
SystemColors
.ControlDark)),
MS\Internal\Documents\SignatureSummaryDialog.Designer.cs (4)
137
_columnHeaderPanel.BackColor = System.Drawing.
SystemColors
.Control;
147
_listBoxSummary.BackColor = System.Drawing.
SystemColors
.Window;
164
_listboxMainPanel.BackColor = System.Drawing.
SystemColors
.Info;
174
_listboxItemPanel.BackColor = System.Drawing.
SystemColors
.GradientActiveCaption;
System.ComponentModel.TypeConverter (2)
src\libraries\Common\src\System\Drawing\ColorTable.cs (1)
18
FillWithProperties(colors, typeof(
SystemColors
));
System\Drawing\ColorConverter.cs (1)
107
member = typeof(Color).GetProperty(c.Name) ?? typeof(
SystemColors
).GetProperty(c.Name);
System.Drawing (1)
System.Drawing.cs (1)
155
[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Drawing.
SystemColors
))]
System.Drawing.Common (1)
Special\Forwards.cs (1)
18
[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Drawing.
SystemColors
))]
System.Drawing.Common.Tests (140)
System\Drawing\ColorTranslatorTests.cs (70)
12
yield return (unchecked((int)0x8000000A),
SystemColors
.ActiveBorder);
13
yield return (unchecked((int)0x80000002),
SystemColors
.ActiveCaption);
14
yield return (unchecked((int)0x80000009),
SystemColors
.ActiveCaptionText);
15
yield return (unchecked((int)0x8000000C),
SystemColors
.AppWorkspace);
16
yield return (unchecked((int)0x8000000F),
SystemColors
.Control);
17
yield return (unchecked((int)0x80000010),
SystemColors
.ControlDark);
18
yield return (unchecked((int)0x80000015),
SystemColors
.ControlDarkDark);
19
yield return (unchecked((int)0x80000016),
SystemColors
.ControlLight);
20
yield return (unchecked((int)0x80000014),
SystemColors
.ControlLightLight);
21
yield return (unchecked((int)0x80000012),
SystemColors
.ControlText);
22
yield return (unchecked((int)0x80000001),
SystemColors
.Desktop);
23
yield return (unchecked((int)0x8000001B),
SystemColors
.GradientActiveCaption);
24
yield return (unchecked((int)0x8000001C),
SystemColors
.GradientInactiveCaption);
25
yield return (unchecked((int)0x80000011),
SystemColors
.GrayText);
26
yield return (unchecked((int)0x8000000D),
SystemColors
.Highlight);
27
yield return (unchecked((int)0x8000000E),
SystemColors
.HighlightText);
28
yield return (unchecked((int)0x8000001A),
SystemColors
.HotTrack);
29
yield return (unchecked((int)0x8000000B),
SystemColors
.InactiveBorder);
30
yield return (unchecked((int)0x80000003),
SystemColors
.InactiveCaption);
31
yield return (unchecked((int)0x80000013),
SystemColors
.InactiveCaptionText);
32
yield return (unchecked((int)0x80000018),
SystemColors
.Info);
33
yield return (unchecked((int)0x80000017),
SystemColors
.InfoText);
34
yield return (unchecked((int)0x80000004),
SystemColors
.Menu);
35
yield return (unchecked((int)0x8000001E),
SystemColors
.MenuBar);
36
yield return (unchecked((int)0x8000001D),
SystemColors
.MenuHighlight);
37
yield return (unchecked((int)0x80000007),
SystemColors
.MenuText);
38
yield return (unchecked((int)0x80000000),
SystemColors
.ScrollBar);
39
yield return (unchecked((int)0x80000005),
SystemColors
.Window);
40
yield return (unchecked((int)0x80000006),
SystemColors
.WindowFrame);
41
yield return (unchecked((int)0x80000008),
SystemColors
.WindowText);
61
yield return new object[] { int.MinValue,
SystemColors
.ScrollBar };
97
yield return new object[] {
SystemColors
.ButtonFace, unchecked((int)0x8000000F) };
98
yield return new object[] {
SystemColors
.ButtonHighlight, unchecked((int)0x80000014) };
99
yield return new object[] {
SystemColors
.ButtonShadow, unchecked((int)0x80000010) };
111
yield return ("activeborder",
SystemColors
.ActiveBorder);
112
yield return ("activecaption",
SystemColors
.ActiveCaption);
113
yield return ("appworkspace",
SystemColors
.AppWorkspace);
114
yield return ("background",
SystemColors
.Desktop);
115
yield return ("buttonface",
SystemColors
.Control);
116
yield return ("buttonhighlight",
SystemColors
.ControlLightLight);
117
yield return ("buttonshadow",
SystemColors
.ControlDark);
118
yield return ("buttontext",
SystemColors
.ControlText);
119
yield return ("captiontext",
SystemColors
.ActiveCaptionText);
120
yield return ("graytext",
SystemColors
.GrayText);
121
yield return ("highlight",
SystemColors
.Highlight);
122
yield return ("highlighttext",
SystemColors
.HighlightText);
123
yield return ("inactiveborder",
SystemColors
.InactiveBorder);
124
yield return ("inactivecaption",
SystemColors
.InactiveCaption);
125
yield return ("inactivecaptiontext",
SystemColors
.InactiveCaptionText);
126
yield return ("infobackground",
SystemColors
.Info);
127
yield return ("infotext",
SystemColors
.InfoText);
128
yield return ("menu",
SystemColors
.Menu);
129
yield return ("menutext",
SystemColors
.MenuText);
130
yield return ("scrollbar",
SystemColors
.ScrollBar);
131
yield return ("window",
SystemColors
.Window);
132
yield return ("windowframe",
SystemColors
.WindowFrame);
133
yield return ("windowtext",
SystemColors
.WindowText);
134
yield return ("threeddarkshadow",
SystemColors
.ControlDarkDark);
152
yield return new object[] { "ActiveBorder",
SystemColors
.ActiveBorder };
153
yield return new object[] { "ACTIVEBORDER",
SystemColors
.ActiveBorder };
178
yield return new object[] { "threedface",
SystemColors
.Control };
179
yield return new object[] { "threedhighlight",
SystemColors
.ControlLight };
180
yield return new object[] { "threedlightshadow",
SystemColors
.ControlLightLight };
245
yield return new object[] {
SystemColors
.ControlLight, "buttonface" };
246
yield return new object[] {
SystemColors
.GradientActiveCaption, "activecaption" };
247
yield return new object[] {
SystemColors
.HotTrack, "highlight" };
248
yield return new object[] {
SystemColors
.MenuHighlight, "highlighttext" };
249
yield return new object[] {
SystemColors
.GradientInactiveCaption, "inactivecaption" };
250
yield return new object[] {
SystemColors
.MenuBar, "menu" };
251
yield return new object[] {
SystemColors
.ButtonShadow, "" };
System\Drawing\Drawing2D\HatchBrushTests.cs (2)
74
clone.Color =
SystemColors
.AppWorkspace;
75
Assert.Equal(
SystemColors
.AppWorkspace, clone.Color);
System\Drawing\SolidBrushTests.cs (2)
45
clone.Color =
SystemColors
.AppWorkspace;
46
Assert.Equal(
SystemColors
.AppWorkspace, clone.Color);
System\Drawing\SystemBrushesTests.cs (33)
10
yield return Brush(() => SystemBrushes.ActiveBorder,
SystemColors
.ActiveBorder);
11
yield return Brush(() => SystemBrushes.ActiveCaption,
SystemColors
.ActiveCaption);
12
yield return Brush(() => SystemBrushes.ActiveCaptionText,
SystemColors
.ActiveCaptionText);
13
yield return Brush(() => SystemBrushes.AppWorkspace,
SystemColors
.AppWorkspace);
14
yield return Brush(() => SystemBrushes.ButtonFace,
SystemColors
.ButtonFace);
15
yield return Brush(() => SystemBrushes.ButtonHighlight,
SystemColors
.ButtonHighlight);
16
yield return Brush(() => SystemBrushes.ButtonShadow,
SystemColors
.ButtonShadow);
17
yield return Brush(() => SystemBrushes.Control,
SystemColors
.Control);
18
yield return Brush(() => SystemBrushes.ControlDark,
SystemColors
.ControlDark);
19
yield return Brush(() => SystemBrushes.ControlDarkDark,
SystemColors
.ControlDarkDark);
20
yield return Brush(() => SystemBrushes.ControlLight,
SystemColors
.ControlLight);
21
yield return Brush(() => SystemBrushes.ControlLightLight,
SystemColors
.ControlLightLight);
22
yield return Brush(() => SystemBrushes.ControlText,
SystemColors
.ControlText);
23
yield return Brush(() => SystemBrushes.Desktop,
SystemColors
.Desktop);
24
yield return Brush(() => SystemBrushes.GradientActiveCaption,
SystemColors
.GradientActiveCaption);
25
yield return Brush(() => SystemBrushes.GradientInactiveCaption,
SystemColors
.GradientInactiveCaption);
26
yield return Brush(() => SystemBrushes.GrayText,
SystemColors
.GrayText);
27
yield return Brush(() => SystemBrushes.Highlight,
SystemColors
.Highlight);
28
yield return Brush(() => SystemBrushes.HighlightText,
SystemColors
.HighlightText);
29
yield return Brush(() => SystemBrushes.HotTrack,
SystemColors
.HotTrack);
30
yield return Brush(() => SystemBrushes.InactiveBorder,
SystemColors
.InactiveBorder);
31
yield return Brush(() => SystemBrushes.InactiveCaption,
SystemColors
.InactiveCaption);
32
yield return Brush(() => SystemBrushes.InactiveCaptionText,
SystemColors
.InactiveCaptionText);
33
yield return Brush(() => SystemBrushes.Info,
SystemColors
.Info);
34
yield return Brush(() => SystemBrushes.InfoText,
SystemColors
.InfoText);
35
yield return Brush(() => SystemBrushes.Menu,
SystemColors
.Menu);
36
yield return Brush(() => SystemBrushes.MenuBar,
SystemColors
.MenuBar);
37
yield return Brush(() => SystemBrushes.MenuHighlight,
SystemColors
.MenuHighlight);
38
yield return Brush(() => SystemBrushes.MenuText,
SystemColors
.MenuText);
39
yield return Brush(() => SystemBrushes.ScrollBar,
SystemColors
.ScrollBar);
40
yield return Brush(() => SystemBrushes.Window,
SystemColors
.Window);
41
yield return Brush(() => SystemBrushes.WindowFrame,
SystemColors
.WindowFrame);
42
yield return Brush(() => SystemBrushes.WindowText,
SystemColors
.WindowText);
System\Drawing\SystemPensTest.cs (33)
12
yield return Pen(() => SystemPens.ActiveBorder,
SystemColors
.ActiveBorder);
13
yield return Pen(() => SystemPens.ActiveCaption,
SystemColors
.ActiveCaption);
14
yield return Pen(() => SystemPens.ActiveCaptionText,
SystemColors
.ActiveCaptionText);
15
yield return Pen(() => SystemPens.AppWorkspace,
SystemColors
.AppWorkspace);
16
yield return Pen(() => SystemPens.ButtonFace,
SystemColors
.ButtonFace);
17
yield return Pen(() => SystemPens.ButtonHighlight,
SystemColors
.ButtonHighlight);
18
yield return Pen(() => SystemPens.ButtonShadow,
SystemColors
.ButtonShadow);
19
yield return Pen(() => SystemPens.Control,
SystemColors
.Control);
20
yield return Pen(() => SystemPens.ControlDark,
SystemColors
.ControlDark);
21
yield return Pen(() => SystemPens.ControlDarkDark,
SystemColors
.ControlDarkDark);
22
yield return Pen(() => SystemPens.ControlLight,
SystemColors
.ControlLight);
23
yield return Pen(() => SystemPens.ControlLightLight,
SystemColors
.ControlLightLight);
24
yield return Pen(() => SystemPens.ControlText,
SystemColors
.ControlText);
25
yield return Pen(() => SystemPens.Desktop,
SystemColors
.Desktop);
26
yield return Pen(() => SystemPens.GradientActiveCaption,
SystemColors
.GradientActiveCaption);
27
yield return Pen(() => SystemPens.GradientInactiveCaption,
SystemColors
.GradientInactiveCaption);
28
yield return Pen(() => SystemPens.GrayText,
SystemColors
.GrayText);
29
yield return Pen(() => SystemPens.Highlight,
SystemColors
.Highlight);
30
yield return Pen(() => SystemPens.HighlightText,
SystemColors
.HighlightText);
31
yield return Pen(() => SystemPens.HotTrack,
SystemColors
.HotTrack);
32
yield return Pen(() => SystemPens.InactiveBorder,
SystemColors
.InactiveBorder);
33
yield return Pen(() => SystemPens.InactiveCaption,
SystemColors
.InactiveCaption);
34
yield return Pen(() => SystemPens.InactiveCaptionText,
SystemColors
.InactiveCaptionText);
35
yield return Pen(() => SystemPens.Info,
SystemColors
.Info);
36
yield return Pen(() => SystemPens.InfoText,
SystemColors
.InfoText);
37
yield return Pen(() => SystemPens.Menu,
SystemColors
.Menu);
38
yield return Pen(() => SystemPens.MenuBar,
SystemColors
.MenuBar);
39
yield return Pen(() => SystemPens.MenuHighlight,
SystemColors
.MenuHighlight);
40
yield return Pen(() => SystemPens.MenuText,
SystemColors
.MenuText);
41
yield return Pen(() => SystemPens.ScrollBar,
SystemColors
.ScrollBar);
42
yield return Pen(() => SystemPens.Window,
SystemColors
.Window);
43
yield return Pen(() => SystemPens.WindowFrame,
SystemColors
.WindowFrame);
44
yield return Pen(() => SystemPens.WindowText,
SystemColors
.WindowText);
System.Drawing.Primitives (3)
src\libraries\Common\src\System\Drawing\ColorTable.cs (1)
18
FillWithProperties(colors, typeof(
SystemColors
));
System\Drawing\KnownColorTable.cs (1)
543
return (!
SystemColors
.s_useAlternativeColorSet)
System\Drawing\SystemColors.cs (1)
57
/// the alternative color set (as returned by <see cref="
SystemColors
"/> statics or
System.Windows.Forms (349)
System\Windows\Forms\ActiveX\AxHost.cs (2)
3366
qaContainer.colorFore = GetOleColorFromColor(
SystemColors
.WindowText);
3367
qaContainer.colorBack = GetOleColorFromColor(
SystemColors
.Window);
System\Windows\Forms\Application.cs (2)
309
bool useAlternateColorSet =
SystemColors
.UseAlternativeColorSet;
314
SystemColors
.UseAlternativeColorSet = darkModeEnabled;
System\Windows\Forms\Control.cs (4)
1546
public static Color DefaultBackColor =>
SystemColors
.Control;
1577
public static Color DefaultForeColor =>
SystemColors
.ControlText;
1626
color =
SystemColors
.Control;
8160
using CreateBrushScope hbrush = new(
SystemColors
.Control);
System\Windows\Forms\Controls\Buttons\ButtonBase.cs (1)
1265
get => (_isEnableVisualStyleBackgroundSet || (RawBackColor.IsEmpty && (BackColor ==
SystemColors
.Control)))
System\Windows\Forms\Controls\Buttons\ButtonInternal\ButtonBaseAdapter.ColorOptions.cs (6)
40
if (_backColor ==
SystemColors
.Control)
42
colors.ButtonShadow =
SystemColors
.ControlDark;
43
colors.ButtonShadowDark =
SystemColors
.ControlDarkDark;
44
colors.Highlight =
SystemColors
.ControlLightLight;
62
colors.WindowDisabled = HighContrast ?
SystemColors
.GrayText : colors.ButtonShadow;
88
if (HighContrast && _backColor !=
SystemColors
.Control)
System\Windows\Forms\Controls\Buttons\ButtonInternal\ButtonBaseAdapter.cs (15)
105
if (Control.BackColor !=
SystemColors
.Control && SystemInformation.HighContrast)
131
bool stockColor = colors.ButtonFace.ToKnownColor() ==
SystemColors
.Control.ToKnownColor();
146
: stockColor ?
SystemColors
.ControlLightLight : colors.Highlight);
155
: stockColor ?
SystemColors
.ControlDarkDark : colors.ButtonShadowDark);
164
? SystemInformation.HighContrast ?
SystemColors
.ControlLight :
SystemColors
.Control
180
: stockColor ?
SystemColors
.ControlDark : colors.ButtonShadow);
223
colors.ButtonFace.ToKnownColor() ==
SystemColors
.Control.ToKnownColor()
224
?
SystemColors
.ControlLight
234
bool stockColor = colors.ButtonFace.ToKnownColor() ==
SystemColors
.Control.ToKnownColor();
249
: stockColor ?
SystemColors
.ControlLightLight : colors.Highlight);
258
: stockColor ?
SystemColors
.ControlDarkDark : colors.ButtonShadowDark);
273
: SystemInformation.HighContrast ?
SystemColors
.ControlLight :
SystemColors
.Control);
284
: stockColor ?
SystemColors
.ControlDark : colors.ButtonShadow);
System\Windows\Forms\Controls\Buttons\ButtonInternal\ButtonFlatAdapter.cs (4)
67
PaintBackground(e, r, IsHighContrastHighlighted() ?
SystemColors
.Highlight : backColor);
75
PaintField(e, layout, colors, IsHighContrastHighlighted() ?
SystemColors
.HighlightText : colors.WindowText, drawFocus: false);
244
PaintBackground(e, r, IsHighContrastHighlighted() ?
SystemColors
.Highlight : backColor);
256
IsHighContrastHighlighted() ?
SystemColors
.HighlightText : colors.WindowText,
System\Windows\Forms\Controls\Buttons\ButtonInternal\ButtonPopupAdapter.cs (4)
27
Control.PaintBackground(e, r, IsHighContrastHighlighted() ?
SystemColors
.Highlight : Control.BackColor, r.Location);
40
state != CheckState.Indeterminate && IsHighContrastHighlighted() ?
SystemColors
.HighlightText : colors.WindowText,
73
Control.PaintBackground(e, r, IsHighContrastHighlighted() ?
SystemColors
.Highlight : Control.BackColor, r.Location);
82
PaintField(e, layout, colors, IsHighContrastHighlighted() ?
SystemColors
.HighlightText : colors.WindowText, drawFocus: true);
System\Windows\Forms\Controls\Buttons\ButtonInternal\ButtonStandardAdapter.cs (3)
73
Color color = isHighContrastHighlighted ?
SystemColors
.Highlight : Control.BackColor;
167
Color highlightTextColor =
SystemColors
.HighlightText;
178
PaintField(e, layout, colors,
SystemColors
.HighlightText, drawFocus: true);
System\Windows\Forms\Controls\Buttons\ButtonInternal\CheckBoxBaseAdapter.cs (7)
96
color =
SystemColors
.Control;
98
else if (controlCheckState == CheckState.Indeterminate && checkBackground ==
SystemColors
.Window && disabledColors)
100
Color comboColor = SystemInformation.HighContrast ?
SystemColors
.ControlDark :
SystemColors
.Control;
102
(byte)((comboColor.R +
SystemColors
.Window.R) / 2),
103
(byte)((comboColor.G +
SystemColors
.Window.G) / 2),
104
(byte)((comboColor.B +
SystemColors
.Window.B) / 2));
System\Windows\Forms\Controls\Buttons\ButtonInternal\RadioButtonBaseAdapter.cs (3)
37
field =
SystemColors
.Control;
72
field =
SystemColors
.Control;
142
checkColor =
SystemColors
.ControlDark;
System\Windows\Forms\Controls\Buttons\ButtonRenderer.cs (2)
159
textColor =
SystemColors
.ControlText;
270
textColor =
SystemColors
.ControlText;
System\Windows\Forms\Controls\Buttons\CheckBoxRenderer.cs (2)
144
textColor =
SystemColors
.ControlText;
216
textColor =
SystemColors
.ControlText;
System\Windows\Forms\Controls\Buttons\RadioButtonRenderer.cs (2)
144
textColor =
SystemColors
.ControlText;
237
textColor =
SystemColors
.ControlText;
System\Windows\Forms\Controls\ComboBox\ComboBox.cs (4)
258
get => ShouldSerializeBackColor() ? base.BackColor :
SystemColors
.Window;
538
get => ShouldSerializeForeColor() ? base.ForeColor :
SystemColors
.WindowText;
3453
using var hbrush = new CreateBrushScope(ParentInternal?.BackColor ??
SystemColors
.Control);
3732
&& !(SystemInformation.HighContrast && BackColor ==
SystemColors
.Window))
System\Windows\Forms\Controls\ComboBox\ComboBox.FlatComboAdapter.cs (6)
190
=> comboBox.Enabled ?
SystemColors
.Window :
SystemColors
.ControlDark;
196
return
SystemColors
.ControlDark;
199
return focused ?
SystemColors
.ControlDark :
SystemColors
.Window;
203
=> comboBox.Enabled ? comboBox.BackColor :
SystemColors
.Control;
System\Windows\Forms\Controls\ComboBox\ComboBoxRenderer.cs (1)
35
if (windowColor !=
SystemColors
.Window)
System\Windows\Forms\Controls\DataGridView\DataGridView.cs (3)
356
private static readonly Color s_defaultBackColor =
SystemColors
.Window;
357
private static readonly Color s_defaultBackgroundColor =
SystemColors
.ControlDark;
2080
private static Color DefaultGridColor =>
SystemColors
.WindowFrame;
System\Windows\Forms\Controls\DataGridView\DataGridView.Methods.cs (3)
5675
using var brush =
SystemColors
.HotTrack.GetCachedSolidBrushScope();
16699
ControlPaint.DrawHighContrastFocusRectangle(g, GetGridFocusRectangle(),
SystemColors
.ActiveCaptionText);
19313
using var pen =
SystemColors
.ControlText.GetCachedPenScope();
System\Windows\Forms\Controls\DataGridView\DataGridViewButtonCell.cs (2)
752
SystemColors
.Control,
788
using CreateBrushScope hbrush = new(
SystemColors
.ControlDark);
System\Windows\Forms\Controls\DataGridView\DataGridViewCell.cs (10)
1433
int darkDistance = ColorDistance(baseline,
SystemColors
.ControlDark);
1434
int lightDistance = ColorDistance(baseline,
SystemColors
.ControlLightLight);
1443
:
SystemColors
.ControlDark;
1447
:
SystemColors
.ControlLightLight;
1453
:
SystemColors
.WindowFrame;
1457
:
SystemColors
.ControlLightLight;
3155
DataGridViewAdvancedCellBorderStyle.Inset =>
SystemColors
.ControlLightLight,
3156
_ =>
SystemColors
.ControlDark,
3190
DataGridViewAdvancedCellBorderStyle.Inset =>
SystemColors
.ControlLightLight,
3191
_ =>
SystemColors
.ControlDark,
System\Windows\Forms\Controls\DataGridView\DataGridViewLinkCell.cs (9)
58
return Selected ?
SystemColors
.HighlightText : LinkUtilities.IEActiveLinkColor;
96
return !ActiveLinkColor.Equals(
SystemColors
.HotTrack);
166
return Selected ?
SystemColors
.HighlightText : LinkUtilities.IELinkColor;
201
? !LinkColor.Equals(
SystemColors
.HotTrack)
298
return Selected ?
SystemColors
.HighlightText : LinkUtilities.GetVisitedLinkColor();
303
return Selected ?
SystemColors
.HighlightText : LinkUtilities.IEVisitedLinkColor;
343
return !VisitedLinkColor.Equals(
SystemColors
.HotTrack);
356
return Selected ?
SystemColors
.HighlightText :
SystemColors
.HotTrack;
System\Windows\Forms\Controls\DataGridView\DataGridViewLinkColumn.cs (3)
70
return !ActiveLinkColor.Equals(
SystemColors
.HotTrack);
181
return !LinkColor.Equals(
SystemColors
.HotTrack);
361
return !VisitedLinkColor.Equals(
SystemColors
.HotTrack);
System\Windows\Forms\Controls\DateTimePicker\DateTimePicker.cs (6)
28
protected static readonly Color DefaultTitleBackColor =
SystemColors
.ActiveCaption;
33
protected static readonly Color DefaultTitleForeColor =
SystemColors
.ActiveCaptionText;
38
protected static readonly Color DefaultMonthBackColor =
SystemColors
.Window;
43
protected static readonly Color DefaultTrailingForeColor =
SystemColors
.GrayText;
130
get => ShouldSerializeBackColor() ? base.BackColor :
SystemColors
.Window;
495
:
SystemColors
.WindowText;
System\Windows\Forms\Controls\GroupBox\GroupBox.cs (1)
547
Color boxColor = Enabled ? ForeColor :
SystemColors
.GrayText;
System\Windows\Forms\Controls\GroupBox\GroupBoxRenderer.cs (4)
248
Color backColor =
SystemColors
.Control;
328
using CreatePenScope hpenDark = new(
SystemColors
.ControlDark);
340
using CreatePenScope hpenLight = new(
SystemColors
.ControlLight);
353
return
SystemColors
.ControlText;
System\Windows\Forms\Controls\Labels\LinkLabel.cs (1)
238
? SystemInformation.HighContrast ?
SystemColors
.HotTrack : IELinkColor
System\Windows\Forms\Controls\Labels\LinkUtilities.cs (5)
116
int r = (
SystemColors
.Window.R +
SystemColors
.WindowText.R + 1) / 2;
117
int g =
SystemColors
.WindowText.G;
118
int b = (
SystemColors
.Window.B +
SystemColors
.WindowText.B + 1) / 2;
System\Windows\Forms\Controls\ListBoxes\CheckedListBox.cs (6)
585
foreColor =
SystemColors
.GrayText;
598
backColor =
SystemColors
.Highlight;
599
foreColor =
SystemColors
.HighlightText;
603
backColor =
SystemColors
.InactiveBorder;
604
foreColor =
SystemColors
.GrayText;
731
foreColor =
SystemColors
.GrayText;
System\Windows\Forms\Controls\ListBoxes\ListBox.cs (2)
163
return
SystemColors
.Window;
456
return
SystemColors
.WindowText;
System\Windows\Forms\Controls\ListView\ListView.cs (7)
106
private Color _odCacheForeColor =
SystemColors
.WindowText;
107
private Color _odCacheBackColor =
SystemColors
.Window;
348
get => ShouldSerializeBackColor() ? base.BackColor :
SystemColors
.Window;
833
get => ShouldSerializeForeColor() ? base.ForeColor :
SystemColors
.WindowText;
2850
if (nmcd->clrText == ColorTranslator.ToWin32(
SystemColors
.HotTrack))
4935
if (c !=
SystemColors
.Window || Application.IsDarkModeEnabled)
4942
if (c !=
SystemColors
.WindowText || Application.IsDarkModeEnabled)
System\Windows\Forms\Controls\ListView\ListViewItem.cs (2)
291
return
SystemColors
.Window;
422
return
SystemColors
.WindowText;
System\Windows\Forms\Controls\ListView\ListViewItem.ListViewSubItem.cs (2)
80
return _owner?._listView?.BackColor ??
SystemColors
.Window;
173
return _owner?._listView?.ForeColor ??
SystemColors
.WindowText;
System\Windows\Forms\Controls\MonthCalendar\MonthCalendar.cs (5)
62
private static readonly Color s_defaultTitleBackColor =
SystemColors
.ActiveCaption;
63
private static readonly Color s_defaultTitleForeColor =
SystemColors
.ActiveCaptionText;
64
private static readonly Color s_trailingForeColor =
SystemColors
.GrayText;
205
return
SystemColors
.Window;
421
return
SystemColors
.WindowText;
System\Windows\Forms\Controls\ProgressBar\ProgressBar.cs (1)
28
private static readonly Color s_defaultForeColor =
SystemColors
.Highlight;
System\Windows\Forms\Controls\PropertyGrid\PropertyGrid.cs (11)
73
private Color _lineColor = SystemInformation.HighContrast ?
SystemColors
.ControlDarkDark :
SystemColors
.InactiveBorder;
74
private Color _categoryForegroundColor =
SystemColors
.ControlText;
75
private Color _categorySplitterColor =
SystemColors
.Control;
76
private Color _viewBorderColor =
SystemColors
.ControlDark;
77
private Color _selectedItemWithFocusForeColor =
SystemColors
.HighlightText;
78
private Color _selectedItemWithFocusBackColor =
SystemColors
.Highlight;
214
_helpPane.BackColor =
SystemColors
.Control;
215
_helpPane.ForeColor =
SystemColors
.ControlText;
3700
=> _commandsPane.SetColors(
SystemColors
.Control,
SystemColors
.ControlText, Color.Empty, Color.Empty, Color.Empty, Color.Empty);
System\Windows\Forms\Controls\PropertyGrid\PropertyGrid.SnappableControl.cs (1)
35
public Color BorderColor { get; set; } =
SystemColors
.ControlDark;
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\CategoryGridEntry.cs (1)
125
ControlPaint.DrawFocusRectangle(g, focusRect,
SystemColors
.ControlText, OwnerGrid.LineColor);
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\CommandsPane.cs (1)
78
DisabledLinkColor =
SystemColors
.ControlDark
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\DropDownButton.DropDownButtonAdapter.cs (3)
18
if (Control.BackColor !=
SystemColors
.Control && SystemInformation.HighContrast)
75
Color c = (ARGB)
SystemColors
.Window;
90
Color backgroundColor = isHighContrastHighlighted ?
SystemColors
.Highlight : Control.BackColor;
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\PropertyGridView.cs (9)
138
BackColor =
SystemColors
.Window;
139
ForeColor =
SystemColors
.WindowText;
140
_grayTextColor =
SystemColors
.GrayText;
208
_dropDownButton.BackColor =
SystemColors
.Control;
209
_dropDownButton.ForeColor =
SystemColors
.ControlText;
244
BackColor =
SystemColors
.Control,
245
ForeColor =
SystemColors
.ControlText,
360
if (ForeColor.ToArgb() ==
SystemColors
.WindowText.ToArgb())
362
return
SystemColors
.GrayText;
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\PropertyGridView.DropDownHolder.cs (1)
515
using Pen pen = new(
SystemColors
.ControlDark, 1)
System\Windows\Forms\Controls\PropertyGrid\PropertyGridToolStripButton.cs (2)
49
Pen focusPen1 = new(
SystemColors
.ControlText, penWidth)
54
Pen focusPen2 = new(
SystemColors
.Control, penWidth)
System\Windows\Forms\Controls\TabControl\TabControl.cs (1)
177
return
SystemColors
.Control;
System\Windows\Forms\Controls\TextBox\TextBox.cs (1)
910
TextRenderer.DrawTextInternal(hdc, PlaceholderText, Font, rectangle,
SystemColors
.GrayText, TextRenderer.DefaultQuality, flags);
System\Windows\Forms\Controls\TextBox\TextBoxBase.cs (3)
292
return
SystemColors
.Control;
296
return
SystemColors
.Window;
506
return
SystemColors
.WindowText;
System\Windows\Forms\Controls\TextBox\TextBoxRenderer.cs (1)
31
if (windowColor !=
SystemColors
.Window)
System\Windows\Forms\Controls\ToolStrips\ProfessionalColorTable.cs (32)
116
public virtual Color ButtonPressedHighlightBorder =>
SystemColors
.Highlight;
122
public virtual Color ButtonCheckedHighlightBorder =>
SystemColors
.Highlight;
178
public virtual Color ImageMarginGradientEnd => (_usingSystemColors) ?
SystemColors
.Control : FromKnownColor(KnownColors.msocbvcrCBGradVertEnd);
233
public virtual Color StatusStripBorder =>
SystemColors
.ButtonHighlight;
346
SystemColors
.Window,
347
GetAlphaBlendedColor(screen,
SystemColors
.Highlight,
SystemColors
.Window, 160),
351
SystemColors
.Window,
352
GetAlphaBlendedColor(screen,
SystemColors
.Highlight,
SystemColors
.Window, 80),
358
rgbTable[KnownColors.ButtonPressedHighlight] =
SystemColors
.Highlight;
359
rgbTable[KnownColors.ButtonCheckedHighlight] =
SystemColors
.ControlLight;
360
rgbTable[KnownColors.ButtonSelectedHighlight] =
SystemColors
.ControlLight;
371
Color buttonFace =
SystemColors
.ButtonFace;
372
Color buttonShadow =
SystemColors
.ButtonShadow;
373
Color highlight =
SystemColors
.Highlight;
374
Color window =
SystemColors
.Window;
376
Color controlText =
SystemColors
.ControlText;
377
Color buttonHighlight =
SystemColors
.ButtonHighlight;
378
Color grayText =
SystemColors
.GrayText;
379
Color highlightText =
SystemColors
.HighlightText;
380
Color windowText =
SystemColors
.WindowText;
400
gradientEnd =
SystemColors
.ButtonFace;
409
rgbTable[KnownColors.msocbvcrCBCtlBkgdSelectedMouseOver] =
SystemColors
.ControlLight;
437
rgbTable[KnownColors.msocbvcrCBCtlBkgdSelected] = (lowResolution) ?
SystemColors
.ControlLight : highlight;
516
rgbTable[KnownColors.msocbvcrDocTabBdrDarkMouseOver] =
SystemColors
.MenuText;
519
rgbTable[KnownColors.msocbvcrDocTabBdrLightMouseOver] =
SystemColors
.MenuText;
521
rgbTable[KnownColors.msocbvcrDocTabBdrMouseOver] =
SystemColors
.MenuText;
546
rgbTable[KnownColors.msocbvcrFocuslessHighlightedBkgd] =
SystemColors
.InactiveCaption;
548
rgbTable[KnownColors.msocbvcrFocuslessHighlightedText] =
SystemColors
.InactiveCaptionText;
655
rgbTable[KnownColors.msocbvcrWPInfoTipBkgd] =
SystemColors
.Info;
656
rgbTable[KnownColors.msocbvcrWPInfoTipText] =
SystemColors
.InfoText;
System\Windows\Forms\Controls\ToolStrips\ToolStripComboBox.ToolStripComboBoxControl.ToolStripComboBoxFlatComboAdapter.cs (3)
48
return (comboBox.Enabled) ?
SystemColors
.Window : GetColorTable(comboBox as ToolStripComboBoxControl).ComboBoxBorder;
60
return
SystemColors
.ControlDark;
65
:
SystemColors
.Window;
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDownButton.cs (4)
203
arrowColor = Enabled ?
SystemColors
.HighlightText :
SystemColors
.ControlDark;
207
arrowColor = Enabled ?
SystemColors
.ControlText :
SystemColors
.ControlDark;
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDownMenu.cs (1)
568
Renderer.DrawImageMargin(new ToolStripRenderEventArgs(e.Graphics, this, ImageMargin,
SystemColors
.Control));
System\Windows\Forms\Controls\ToolStrips\ToolStripHighContrastRenderer.cs (15)
154
Color arrowColor = item.Selected && !item.Pressed ?
SystemColors
.HighlightText :
SystemColors
.ControlText;
205
Color arrowColor = !item.Enabled ?
SystemColors
.ControlDark
206
: item.Selected && !item.Pressed ?
SystemColors
.HighlightText
207
:
SystemColors
.ControlText;
220
e.DefaultTextColor =
SystemColors
.HighlightText;
222
else if (e.TextColor !=
SystemColors
.HighlightText && e.TextColor !=
SystemColors
.ControlText)
227
e.DefaultTextColor =
SystemColors
.HighlightText;
231
e.DefaultTextColor =
SystemColors
.ControlText;
245
e.TextColor =
SystemColors
.HighlightText;
292
using Pen p = new(
SystemColors
.ButtonShadow)
382
return
SystemColors
.Control.ToArgb() == Color.Black.ToArgb();
468
Pen focusPen1 = new(
SystemColors
.ControlText, penWidth)
473
Pen focusPen2 = new(
SystemColors
.Control, penWidth)
System\Windows\Forms\Controls\ToolStrips\ToolStripItemTextRenderEventArgs.cs (1)
13
private Color _textColor =
SystemColors
.ControlText;
System\Windows\Forms\Controls\ToolStrips\ToolStripMenuItem.cs (7)
715
image.MakeTransparent(
SystemColors
.Control);
955
Color textColor =
SystemColors
.MenuText;
964
textColor =
SystemColors
.HighlightText;
968
textColor =
SystemColors
.MenuText;
1010
Color arrowColor = (Selected || Pressed) ?
SystemColors
.HighlightText :
SystemColors
.MenuText;
1011
arrowColor = (Enabled) ? arrowColor :
SystemColors
.ControlDark;
System\Windows\Forms\Controls\ToolStrips\ToolStripProfessionalLowResolutionRenderer.cs (1)
57
using Pen p = new(
SystemColors
.ButtonShadow)
System\Windows\Forms\Controls\ToolStrips\ToolstripProfessionalRenderer.cs (5)
307
DrawArrow(new ToolStripArrowRenderEventArgs(g, item, dropDownRect,
SystemColors
.ControlText, ArrowDirection.Down));
571
borderColor =
SystemColors
.Highlight;
628
borderColor =
SystemColors
.Highlight;
681
e.DefaultArrowColor = item.Enabled ?
SystemColors
.ControlText :
SystemColors
.ControlDark;
System\Windows\Forms\Controls\ToolStrips\ToolStripRenderer.cs (2)
835
Color backgroundColor = e.Item.Selected ?
SystemColors
.Highlight : e.Item.BackColor;
872
textColor = (item is not null && item.Enabled) ? textColor :
SystemColors
.GrayText;
System\Windows\Forms\Controls\ToolStrips\ToolStripRenderEventArgs.cs (4)
65
_backColor =
SystemColors
.Control;
77
_backColor =
SystemColors
.Menu;
81
_backColor =
SystemColors
.MenuBar;
85
_backColor =
SystemColors
.Control;
System\Windows\Forms\Controls\ToolStrips\ToolStripSeparator.cs (2)
18
ForeColor =
SystemColors
.ControlDark;
304
internal override bool ShouldSerializeForeColor() => ForeColor !=
SystemColors
.ControlDark;
System\Windows\Forms\Controls\ToolStrips\ToolStripSystemRenderer.cs (14)
202
FillBackground(g, bounds,
SystemColors
.ButtonFace);
206
FillBackground(g, bounds, (toolStrip is ToolStripDropDown) ?
SystemColors
.ControlLight : e.BackColor);
211
e.BackColor :
SystemColors
.Menu);
216
e.BackColor :
SystemColors
.MenuBar);
227
e.BackColor :
SystemColors
.MenuBar);
393
Color arrowColor = item.Enabled ?
SystemColors
.ControlText :
SystemColors
.ControlDark;
462
?
SystemColors
.Highlight
524
Color arrowColor = splitButton.Enabled ?
SystemColors
.ControlText :
SystemColors
.ControlDark;
586
ControlPaint.DrawBorderSimple(g, clientBounds,
SystemColors
.Highlight);
587
using var brush =
SystemColors
.Highlight.GetCachedSolidBrushScope();
663
ControlPaint.DrawBorderSimple(g, bounds,
SystemColors
.Highlight);
803
if (vsRenderer is null || (item.BackColor !=
SystemColors
.Control))
System\Windows\Forms\Controls\ToolStrips\ToolStripTextBox.ToolStripTextBoxControl.cs (2)
249
outerBorderColor =
SystemColors
.ControlDark;
250
innerBorderColor =
SystemColors
.Control;
System\Windows\Forms\Controls\TrackBar\TrackBar.cs (1)
240
get =>
SystemColors
.WindowText;
System\Windows\Forms\Controls\TreeView\TreeView.cs (6)
198
get => ShouldSerializeBackColor() ? base.BackColor :
SystemColors
.Window;
442
get => ShouldSerializeForeColor() ? base.ForeColor :
SystemColors
.WindowText;
1885
if (c !=
SystemColors
.Window || Application.IsDarkModeEnabled)
1892
if (c !=
SystemColors
.WindowText || Application.IsDarkModeEnabled)
2841
Color color = (((curState & TreeNodeStates.Selected) == TreeNodeStates.Selected) && node.TreeView.Focused) ?
SystemColors
.HighlightText : (node.ForeColor != Color.Empty) ? node.ForeColor : node.TreeView.ForeColor;
2847
ControlPaint.DrawFocusRectangle(g, bounds, color,
SystemColors
.Highlight);
System\Windows\Forms\Controls\UpDown\UpDownBase.cs (1)
585
ControlPaint.DrawBorderSimple(e, editBounds,
SystemColors
.Control);
System\Windows\Forms\DarkProfessionalColors.cs (9)
20
=>
SystemColors
.ControlText;
29
=>
SystemColors
.Control;
32
=>
SystemColors
.Control;
35
=>
SystemColors
.Control;
38
=>
SystemColors
.Control;
41
=>
SystemColors
.Control;
44
=>
SystemColors
.Control;
47
=>
SystemColors
.Control;
50
=>
SystemColors
.Control;
System\Windows\Forms\Design\ComponentEditorForm.cs (1)
194
BackColor =
SystemColors
.ControlDark
System\Windows\Forms\Design\ComponentEditorForm.PageSelector.cs (7)
30
BackColor =
SystemColors
.Control;
160
savedColor = PInvokeCore.SetBkColor(dc, (COLORREF)(uint)ColorTranslator.ToWin32(
SystemColors
.ControlLightLight));
171
PInvokeCore.SetBkColor(dc, (COLORREF)(uint)ColorTranslator.ToWin32(
SystemColors
.ControlDark));
232
(COLORREF)(uint)ColorTranslator.ToWin32(
SystemColors
.Control),
233
(COLORREF)(uint)ColorTranslator.ToWin32(
SystemColors
.ControlText));
266
COLORREF oldTextColor = PInvokeCore.SetTextColor(dc, (COLORREF)(uint)ColorTranslator.ToWin32(
SystemColors
.ControlLightLight));
267
COLORREF oldBackColor = PInvokeCore.SetBkColor(dc, (COLORREF)(uint)ColorTranslator.ToWin32(
SystemColors
.Control));
System\Windows\Forms\Dialogs\CommonDialogs\FontDialog.cs (3)
112
_color =
SystemColors
.ControlText;
370
_color =
SystemColors
.ControlText;
396
rgbColors = ShowColor || ShowEffects ? _color :
SystemColors
.ControlText
System\Windows\Forms\Help\Help.cs (1)
85
clrBackground =
SystemColors
.Window
System\Windows\Forms\MDI\MDIClient.cs (2)
36
BackColor =
SystemColors
.AppWorkspace;
318
internal override bool ShouldSerializeBackColor() => BackColor !=
SystemColors
.AppWorkspace;
System\Windows\Forms\Printing\PrintPreviewControl.cs (5)
293
public override void ResetBackColor() => BackColor =
SystemColors
.AppWorkspace;
295
internal override bool ShouldSerializeBackColor() => !BackColor.Equals(
SystemColors
.AppWorkspace);
595
using var brush =
SystemColors
.ControlText.GetCachedSolidBrushScope();
720
ControlPaint.DrawHighContrastFocusRectangle(e.Graphics, focusRect,
SystemColors
.ControlText);
740
return (isHighContract && !ShouldSerializeBackColor()) ?
SystemColors
.ControlDark : BackColor;
System\Windows\Forms\Rendering\ControlPaint.cs (20)
140
=> SystemInformation.HighContrast ?
SystemColors
.WindowFrame :
SystemColors
.ControlDark;
1084
if (color.ToKnownColor() ==
SystemColors
.Control.ToKnownColor())
1100
bool stockColor = color.ToKnownColor() ==
SystemColors
.Control.ToKnownColor();
1104
using var lightPen = (stockColor ?
SystemColors
.ControlLightLight : hls.Lighter(1.0f)).GetCachedPenScope();
1109
using var darkPen = (stockColor ?
SystemColors
.ControlDarkDark : hls.Darker(1.0f)).GetCachedPenScope();
1122
?
SystemColors
.ControlLightLight
1123
:
SystemColors
.Control).GetCachedPenScope();
1129
using var bottomRightPen = (stockColor ?
SystemColors
.ControlDark : hls.Darker(0.5f)).GetCachedPenScope();
1327
? (SystemInformation.HighContrast ?
SystemColors
.GrayText :
SystemColors
.ControlDark)
1328
:
SystemColors
.ControlText;
1398
=> DrawFocusRectangle(graphics, rectangle,
SystemColors
.ControlText,
SystemColors
.Control);
1668
using Pen pen = new(
SystemColors
.WindowFrame, 1);
2004
TextRenderer.DrawTextInternal(dc, s, font, layoutRectangle,
SystemColors
.GrayText, quality, format);
2082
Color brushColor = backColor.GetBrightness() <= .5 ?
SystemColors
.ControlLight :
SystemColors
.ControlDark;
2212
Color brushColor = backColor.GetBrightness() <= .5 ?
SystemColors
.ControlLight :
SystemColors
.ControlDark;
System\Windows\Forms\Rendering\ControlPaint.HLSColor.cs (9)
29
_isSystemColors_Control = color.ToKnownColor() ==
SystemColors
.Control.ToKnownColor();
103
return
SystemColors
.ControlDark;
107
return
SystemColors
.ControlDarkDark;
111
ARGB dark =
SystemColors
.ControlDark;
112
ARGB darkDark =
SystemColors
.ControlDarkDark;
154
return
SystemColors
.ControlLight;
158
return
SystemColors
.ControlLightLight;
162
ARGB light =
SystemColors
.ControlLight;
163
ARGB lightLight =
SystemColors
.ControlLightLight;
System\Windows\Forms\Rendering\DrawItemEventArgs.cs (6)
32
: this(graphics, font, rect, index, state,
SystemColors
.WindowText,
SystemColors
.Window)
62
: this(hdc, font, rect, index, state,
SystemColors
.WindowText,
SystemColors
.Window)
115
=> (State & DrawItemState.Selected) == DrawItemState.Selected ?
SystemColors
.HighlightText : _foreColor;
118
=> (State & DrawItemState.Selected) == DrawItemState.Selected ?
SystemColors
.Highlight : _backColor;
System\Windows\Forms\Rendering\TextRenderer.cs (3)
552
return
SystemColors
.GrayText;
558
return ControlPaint.IsDarker(backColor,
SystemColors
.Control)
560
:
SystemColors
.ControlDark;
System\Windows\Forms\ToolTip\DrawToolTipEventArgs.cs (1)
101
ControlPaint.DrawBorder(Graphics, Bounds,
SystemColors
.WindowFrame, ButtonBorderStyle.Solid);
System\Windows\Forms\ToolTip\ToolTip.cs (4)
43
private Color _backColor =
SystemColors
.Info;
44
private Color _foreColor =
SystemColors
.InfoText;
773
if (BackColor !=
SystemColors
.Info)
778
if (ForeColor !=
SystemColors
.InfoText)
System\Windows\Forms\VisualStyles\VisualStyleInformation.cs (2)
183
:
SystemColors
.WindowFrame;
190
:
SystemColors
.ButtonHighlight;
System.Windows.Forms.Design (116)
System\ComponentModel\Design\ByteViewer.cs (2)
140
using (Brush brush = new SolidBrush(
SystemColors
.ControlLightLight))
151
using Pen pen = new(
SystemColors
.ControlDark);
System\ComponentModel\Design\CollectionEditor.CollectionEditorCollectionForm.cs (4)
579
Color backColor =
SystemColors
.Window;
580
Color textColor =
SystemColors
.WindowText;
583
backColor =
SystemColors
.Highlight;
584
textColor =
SystemColors
.HighlightText;
System\ComponentModel\Design\CollectionEditor.SplitButton.cs (1)
233
TextRenderer.DrawText(pevent, Text, Font, bounds,
SystemColors
.ControlText, formatFlags);
System\ComponentModel\Design\DesignerActionPanel.cs (10)
120
public Color ActiveLinkColor { get; } =
SystemColors
.HotTrack;
122
public Color BorderColor { get; } =
SystemColors
.ActiveBorder;
172
public Color GradientDarkColor { get; } =
SystemColors
.Control;
174
public Color GradientLightColor { get; } =
SystemColors
.Control;
178
public Color LinkColor { get; } =
SystemColors
.HotTrack;
180
public Color SeparatorColor { get; } =
SystemColors
.ControlDark;
182
public Color TitleBarColor { get; } =
SystemColors
.ActiveCaption;
184
public Color TitleBarTextColor { get; } =
SystemColors
.ActiveCaptionText;
186
public Color TitleBarUnselectedColor { get; } =
SystemColors
.InactiveCaption;
188
public Color LabelForeColor { get; } =
SystemColors
.ControlText;
System\ComponentModel\Design\DesignerActionPanel.EditorPropertyLine.cs (1)
112
ShowDropDown(listBox,
SystemColors
.ControlDark);
System\ComponentModel\Design\DesignerActionPanel.EditorPropertyLine.EditorButton.cs (1)
131
(Color OldColor, Color NewColor) map = new(Color.Black,
SystemColors
.WindowText);
System\ComponentModel\Design\DesignerActionPanel.EditorPropertyLine.FlyoutDialog.cs (1)
22
BackColor =
SystemColors
.Window;
System\ComponentModel\Design\DesignerActionPanel.TextBoxPropertyLine.cs (5)
35
ForeColor =
SystemColors
.WindowText,
165
_readOnlyTextBoxLabel.ForeColor =
SystemColors
.HighlightText;
166
_readOnlyTextBoxLabel.BackColor =
SystemColors
.Highlight;
171
_readOnlyTextBoxLabel.ForeColor =
SystemColors
.WindowText;
172
_readOnlyTextBoxLabel.BackColor =
SystemColors
.Window;
System\ComponentModel\Design\MultilineStringEditor.MultilineStringEditorUI.cs (2)
393
Color cw =
SystemColors
.Window;
394
Color ct =
SystemColors
.WindowText;
System\Drawing\Design\ColorEditor.ColorPalette.cs (8)
70
BackColor =
SystemColors
.Control;
386
SystemColors
.ControlText,
397
SystemColors
.ControlText,
398
SystemColors
.Control);
404
SystemColors
.Control, 2, ButtonBorderStyle.Inset,
405
SystemColors
.Control, 2, ButtonBorderStyle.Inset,
406
SystemColors
.Control, 2, ButtonBorderStyle.Inset,
407
SystemColors
.Control, 2, ButtonBorderStyle.Inset);
System\Drawing\Design\ColorEditor.ColorUI.cs (1)
73
private Color[] SystemColorValues => _systemColorConstants ??= GetConstants(typeof(
SystemColors
));
System\Drawing\Design\ContentAlignmentEditor.ContentUI.cs (2)
110
BackColor =
SystemColors
.Control;
111
ForeColor =
SystemColors
.ControlText;
System\Windows\Forms\Design\AnchorEditor.AnchorUI.cs (3)
177
BackColor =
SystemColors
.Window;
178
ForeColor =
SystemColors
.WindowText;
193
BackColor =
SystemColors
.Control;
System\Windows\Forms\Design\Behavior\MiniLockedBorderGlyph.cs (1)
53
pe.Graphics.FillRectangle(new SolidBrush(
SystemColors
.ControlText), bounds);
System\Windows\Forms\Design\BorderSidesEditor.BorderSidesEditorUI.cs (2)
94
_tableLayoutPanel.BackColor =
SystemColors
.Window;
152
_splitterLabel.BackColor =
SystemColors
.ControlDark;
System\Windows\Forms\Design\ComponentTray.cs (6)
144
styleColor =
SystemColors
.Info;
1421
styleColor =
SystemColors
.Info;
1443
selectionBorderBrush = new HatchBrush(HatchStyle.Percent50,
SystemColors
.HighlightText, Color.Transparent);
1447
selectionBorderBrush = new HatchBrush(HatchStyle.Percent50,
SystemColors
.ControlDarkDark, Color.Transparent);
1460
c.ForeColor =
SystemColors
.HighlightText;
1461
c.BackColor =
SystemColors
.Highlight;
System\Windows\Forms\Design\DataGridViewCellStyleBuilder.cs (1)
143
_cellStyleProperties.LineColor = Drawing.
SystemColors
.ScrollBar;
System\Windows\Forms\Design\DataGridViewColumnCollectionDialog.cs (1)
580
_propertyGrid1.LineColor =
SystemColors
.ScrollBar;
System\Windows\Forms\Design\DataGridViewColumnTypeEditor.Picker.cs (1)
34
BackColor =
SystemColors
.Control;
System\Windows\Forms\Design\DesignBindingPicker.cs (24)
143
BackColor =
SystemColors
.ControlDark,
151
BackColor =
SystemColors
.Window,
152
ForeColor =
SystemColors
.WindowText,
171
BackColor =
SystemColors
.Window,
172
ForeColor =
SystemColors
.WindowText,
183
BackColor =
SystemColors
.ControlDark,
190
BackColor =
SystemColors
.Window,
191
ForeColor =
SystemColors
.WindowText
237
BackColor =
SystemColors
.Window,
238
ForeColor =
SystemColors
.WindowText,
270
BackColor =
SystemColors
.ControlDark,
278
BackColor =
SystemColors
.Window,
279
ForeColor =
SystemColors
.WindowText,
296
BackColor =
SystemColors
.Window,
297
ForeColor =
SystemColors
.WindowText,
315
BackColor =
SystemColors
.ControlDark,
322
BackColor =
SystemColors
.Window,
323
ForeColor =
SystemColors
.WindowText
344
BackColor =
SystemColors
.Control;
708
dataSourceNode.ForeColor =
SystemColors
.GrayText;
1584
_helpTextCtrl.BackColor =
SystemColors
.Info;
1585
_helpTextCtrl.ForeColor =
SystemColors
.InfoText;
1589
_helpTextCtrl.BackColor =
SystemColors
.Window;
1590
_helpTextCtrl.ForeColor =
SystemColors
.WindowText;
System\Windows\Forms\Design\DesignerFrame.cs (1)
274
_splitter.BackColor =
SystemColors
.Control;
System\Windows\Forms\Design\DesignerUtils.cs (20)
22
private static SolidBrush s_hoverBrush = new(Color.FromArgb(alpha: 50,
SystemColors
.Highlight));
25
new(HatchStyle.Percent50,
SystemColors
.ControlDarkDark,
SystemColors
.ControlDarkDark);
28
PInvokeCore.CreateSolidBrush((COLORREF)(uint)ColorTranslator.ToWin32(
SystemColors
.Window));
30
PInvokeCore.CreateSolidBrush((COLORREF)(uint)ColorTranslator.ToWin32(
SystemColors
.ControlText));
32
PInvokeCore.CreatePen(PEN_STYLE.PS_SOLID, cWidth: 1, (COLORREF)(uint)ColorTranslator.ToWin32(
SystemColors
.ControlText));
34
PInvokeCore.CreatePen(PEN_STYLE.PS_SOLID, cWidth: 1, (COLORREF)(uint)ColorTranslator.ToWin32(
SystemColors
.Window));
122
g.FillRectangle(new SolidBrush(
SystemColors
.InactiveBorder), 0, 0, s_boxImageSize, s_boxImageSize);
123
g.DrawRectangle(new Pen(
SystemColors
.ControlDarkDark), 0, 0, s_boxImageSize - 1, s_boxImageSize - 1);
167
s_hoverBrush = new SolidBrush(Color.FromArgb(50,
SystemColors
.Highlight));
170
s_selectionBorderBrush = new HatchBrush(HatchStyle.Percent50,
SystemColors
.ControlDarkDark,
SystemColors
.ControlDarkDark);
173
s_grabHandleFillBrushPrimary = PInvokeCore.CreateSolidBrush((COLORREF)(uint)ColorTranslator.ToWin32(
SystemColors
.Window));
176
s_grabHandleFillBrush = PInvokeCore.CreateSolidBrush((COLORREF)(uint)ColorTranslator.ToWin32(
SystemColors
.ControlText));
179
s_grabHandlePenPrimary = PInvokeCore.CreatePen(PEN_STYLE.PS_SOLID, cWidth: 1, (COLORREF)(uint)ColorTranslator.ToWin32(
SystemColors
.ControlText));
182
s_grabHandlePen = PInvokeCore.CreatePen(PEN_STYLE.PS_SOLID, cWidth: 1, (COLORREF)(uint)ColorTranslator.ToWin32(
SystemColors
.Window));
228
Color color =
SystemColors
.ControlDarkDark;
231
color =
SystemColors
.ControlLight;
398
gDest.Clear(
SystemColors
.Control);
431
g.Clear(
SystemColors
.Control);
System\Windows\Forms\Design\DockEditor.DockUI.cs (3)
187
BackColor =
SystemColors
.Control;
188
ForeColor =
SystemColors
.ControlText;
295
BackColor =
SystemColors
.Control;
System\Windows\Forms\Design\DocumentDesigner.cs (2)
138
value =
SystemColors
.Control;
680
Control.BackColor =
SystemColors
.Control;
System\Windows\Forms\Design\MaskedTextBoxTextEditorDropDown.cs (1)
50
BackColor = Drawing.
SystemColors
.Control;
System\Windows\Forms\Design\OleDragDropHandler.cs (1)
342
Color backColor =
SystemColors
.Control;
System\Windows\Forms\Design\SelectionUIService.SelectionUIItem.cs (1)
138
Color borderColor =
SystemColors
.Control;
System\Windows\Forms\Design\ShortcutKeysEditor.cs (1)
30
BackColor =
SystemColors
.Control
System\Windows\Forms\Design\TabOrder.cs (4)
57
_highlightTextBrush = new SolidBrush(
SystemColors
.HighlightText);
58
_highlightPen = new Pen(
SystemColors
.Highlight);
276
textColor =
SystemColors
.Highlight;
282
textColor =
SystemColors
.HighlightText;
System\Windows\Forms\Design\ToolStripDropDownDesigner.cs (1)
393
BackColor =
SystemColors
.Window,
System\Windows\Forms\Design\ToolStripTemplateNode.cs (3)
879
ForeColor =
SystemColors
.WindowText
1815
DrawArrow(new ToolStripArrowRenderEventArgs(g, null, bounds, SystemInformation.HighContrast ? Color.Black :
SystemColors
.ControlText, ArrowDirection.Down));
2037
DrawArrow(new ToolStripArrowRenderEventArgs(g, splitButton, splitButton.DropDownButtonBounds,
SystemColors
.ControlText, ArrowDirection.Down));
System\Windows\Forms\Design\TreeNodeCollectionEditor.cs (1)
284
_propertyGrid1.LineColor =
SystemColors
.ScrollBar;
System.Windows.Forms.Tests (493)
NumericUpDownTests.cs (1)
90
State.Pen(1,
SystemColors
.Control, PEN_STYLE.PS_SOLID)),
System\Windows\Forms\ApplicationTests.cs (3)
166
Assert.False(
SystemColors
.UseAlternativeColorSet);
171
Assert.True(
SystemColors
.UseAlternativeColorSet);
176
Assert.False(
SystemColors
.UseAlternativeColorSet ^ systemColorMode == SystemColorMode.Dark);
System\Windows\Forms\ButtonRenderingTests.cs (16)
48
State.PenColor(
SystemColors
.ControlLightLight)),
51
State.PenColor(
SystemColors
.ControlLightLight)),
54
State.PenColor(
SystemColors
.ControlDarkDark)),
57
State.PenColor(
SystemColors
.ControlDarkDark)),
60
State.PenColor(
SystemColors
.Control)),
63
State.PenColor(
SystemColors
.Control)),
66
State.PenColor(
SystemColors
.ControlDark)),
69
State.PenColor(
SystemColors
.ControlDark)));
134
State.PenColor(
SystemColors
.ControlLightLight)),
137
State.PenColor(
SystemColors
.ControlLightLight)),
140
State.PenColor(
SystemColors
.ControlDarkDark)),
143
State.PenColor(
SystemColors
.ControlDarkDark)),
146
State.PenColor(
SystemColors
.Control)),
149
State.PenColor(
SystemColors
.Control)),
152
State.PenColor(
SystemColors
.ControlDark)),
155
State.PenColor(
SystemColors
.ControlDark)));
System\Windows\Forms\ComboBoxTests.cs (12)
34
Assert.Equal(
SystemColors
.Window, control.BackColor);
81
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
165
yield return new object[] { Color.Empty,
SystemColors
.Window };
188
yield return new object[] { Color.Empty,
SystemColors
.Window, 0 };
266
Assert.Equal(
SystemColors
.Window, control.BackColor);
288
Assert.Equal(
SystemColors
.Window, control.BackColor);
304
Assert.Equal(
SystemColors
.Window, control.BackColor);
1047
yield return new object[] { Color.Empty,
SystemColors
.WindowText };
1073
yield return new object[] { Color.Empty,
SystemColors
.WindowText, 0 };
1134
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
1156
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
1172
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
System\Windows\Forms\ControlPaintTests.cs (123)
299
yield return new object[] {
SystemColors
.ControlDarkDark, Color.FromArgb(255, 35, 35, 35) };
300
yield return new object[] {
SystemColors
.ControlDark, Color.FromArgb(255, 53, 53, 53) };
301
yield return new object[] {
SystemColors
.Control, Color.FromArgb(255, 133, 133, 133) };
302
yield return new object[] {
SystemColors
.ControlLight, Color.FromArgb(255, 75, 75, 75) };
303
yield return new object[] {
SystemColors
.ControlLightLight, Color.FromArgb(255, 85, 85, 85) };
332
yield return new object[] {
SystemColors
.ControlDarkDark, -1.5f, Color.FromArgb(255, 175, 175, 175) };
333
yield return new object[] {
SystemColors
.ControlDark, -1.5f, Color.FromArgb(255, 9, 9, 9) };
334
yield return new object[] {
SystemColors
.Control, -1.5f, Color.FromArgb(255, 242, 242, 242) };
335
yield return new object[] {
SystemColors
.ControlLight, -1.5f, Color.FromArgb(255, 121, 121, 121) };
336
yield return new object[] {
SystemColors
.ControlLightLight, -1.5f, Color.FromArgb(255, 169, 169, 169) };
352
yield return new object[] {
SystemColors
.ControlDarkDark, -1f, Color.FromArgb(255, 140, 140, 140) };
353
yield return new object[] {
SystemColors
.ControlDark, -1f, Color.FromArgb(255, 212, 212, 212) };
354
yield return new object[] {
SystemColors
.Control, -1f, Color.FromArgb(255, 215, 215, 215) };
355
yield return new object[] {
SystemColors
.ControlLight, -1f, Color.FromArgb(255, 45, 45, 45) };
356
yield return new object[] {
SystemColors
.ControlLightLight, -1f, Color.FromArgb(255, 84, 84, 84) };
372
yield return new object[] {
SystemColors
.ControlDarkDark, -0.5f, Color.FromArgb(255, 105, 105, 105) };
373
yield return new object[] {
SystemColors
.ControlDark, -0.5f, Color.FromArgb(255, 159, 159, 159) };
374
yield return new object[] {
SystemColors
.Control, -0.5f, Color.FromArgb(255, 187, 187, 187) };
375
yield return new object[] {
SystemColors
.ControlLight, -0.5f, Color.FromArgb(255, 226, 226, 226) };
376
yield return new object[] {
SystemColors
.ControlLightLight, -0.5f, Color.FromArgb(255, 255, 255, 255) };
392
yield return new object[] {
SystemColors
.ControlDarkDark, -0.25f, Color.FromArgb(255, 87, 87, 87) };
393
yield return new object[] {
SystemColors
.ControlDark, -0.25f, Color.FromArgb(255, 132, 132, 132) };
394
yield return new object[] {
SystemColors
.Control, -0.25f, Color.FromArgb(255, 173, 173, 173) };
395
yield return new object[] {
SystemColors
.ControlLight, -0.25f, Color.FromArgb(255, 188, 188, 188) };
396
yield return new object[] {
SystemColors
.ControlLightLight, -0.25f, Color.FromArgb(255, 212, 212, 212) };
412
yield return new object[] {
SystemColors
.ControlDarkDark, 0f, Color.FromArgb(255, 70, 70, 70) };
413
yield return new object[] {
SystemColors
.ControlDark, 0f, Color.FromArgb(255, 106, 106, 106) };
414
yield return new object[] {
SystemColors
.Control, 0f,
SystemColors
.ControlDark };
415
yield return new object[] {
SystemColors
.ControlLight, 0f, Color.FromArgb(255, 150, 150, 150) };
416
yield return new object[] {
SystemColors
.ControlLightLight, 0f, Color.FromArgb(255, 170, 170, 170) };
432
yield return new object[] {
SystemColors
.ControlDarkDark, 0.25f, Color.FromArgb(255, 53, 53, 53) };
433
yield return new object[] {
SystemColors
.ControlDark, 0.25f, Color.FromArgb(255, 79, 79, 79) };
434
yield return new object[] {
SystemColors
.Control, 0.25f, Color.FromArgb(255, 147, 147, 147) };
435
yield return new object[] {
SystemColors
.ControlLight, 0.25f, Color.FromArgb(255, 113, 113, 113) };
436
yield return new object[] {
SystemColors
.ControlLightLight, 0.25f, Color.FromArgb(255, 127, 127, 127) };
452
yield return new object[] {
SystemColors
.ControlDarkDark, 0.5f, Color.FromArgb(255, 35, 35, 35) };
453
yield return new object[] {
SystemColors
.ControlDark, 0.5f, Color.FromArgb(255, 53, 53, 53) };
454
yield return new object[] {
SystemColors
.Control, 0.5f, Color.FromArgb(255, 133, 133, 133) };
455
yield return new object[] {
SystemColors
.ControlLight, 0.5f, Color.FromArgb(255, 75, 75, 75) };
456
yield return new object[] {
SystemColors
.ControlLightLight, 0.5f, Color.FromArgb(255, 85, 85, 85) };
472
yield return new object[] {
SystemColors
.ControlDarkDark, 1f, Color.FromArgb(255, 0, 0, 0) };
473
yield return new object[] {
SystemColors
.ControlDark, 1f, Color.FromArgb(255, 0, 0, 0) };
474
yield return new object[] {
SystemColors
.Control, 1f,
SystemColors
.ControlDarkDark };
475
yield return new object[] {
SystemColors
.ControlLight, 1f, Color.FromArgb(255, 0, 0, 0) };
476
yield return new object[] {
SystemColors
.ControlLightLight, 1f, Color.FromArgb(255, 0, 0, 0) };
492
yield return new object[] {
SystemColors
.ControlDarkDark, 1.5f, Color.FromArgb(255, 221, 221, 221) };
493
yield return new object[] {
SystemColors
.ControlDark, 1.5f, Color.FromArgb(255, 203, 203, 203) };
494
yield return new object[] {
SystemColors
.Control, 1.5f, Color.FromArgb(255, 78, 78, 78) };
495
yield return new object[] {
SystemColors
.ControlLight, 1.5f, Color.FromArgb(255, 181, 181, 181) };
524
yield return new object[] {
SystemColors
.ControlDarkDark, Color.FromArgb(255, 0, 0, 0) };
525
yield return new object[] {
SystemColors
.ControlDark, Color.FromArgb(255, 0, 0, 0) };
526
yield return new object[] {
SystemColors
.Control,
SystemColors
.ControlDarkDark };
527
yield return new object[] {
SystemColors
.ControlLight, Color.FromArgb(255, 0, 0, 0) };
528
yield return new object[] {
SystemColors
.ControlLightLight, Color.FromArgb(255, 0, 0, 0) };
545
yield return new object[] { new Rectangle(1, 2, 3, 4),
SystemColors
.ControlLight, style };
546
yield return new object[] { new Rectangle(1, 2, 3, 4),
SystemColors
.Control, style };
547
yield return new object[] { new Rectangle(1, 2, 3, 4),
SystemColors
.ControlDark, style };
1683
yield return new object[] { new Rectangle(1, 2, 3, 4),
SystemColors
.ControlLight, style };
1684
yield return new object[] { new Rectangle(1, 2, 3, 4),
SystemColors
.Control, style };
1685
yield return new object[] { new Rectangle(1, 2, 3, 4),
SystemColors
.ControlDark, style };
1712
yield return new object[] { new Point(1, 2), new Point(2, 3),
SystemColors
.ControlLight };
1713
yield return new object[] { new Point(1, 2), new Point(2, 3),
SystemColors
.Control };
1714
yield return new object[] { new Point(1, 2), new Point(2, 3),
SystemColors
.ControlDark };
2063
yield return new object[] {
SystemColors
.ControlDarkDark, Color.FromArgb(255, 142, 142, 142) };
2064
yield return new object[] {
SystemColors
.ControlDark, Color.FromArgb(255, 183, 183, 183) };
2065
yield return new object[] {
SystemColors
.Control, Color.FromArgb(255, 241, 241, 241) };
2066
yield return new object[] {
SystemColors
.ControlLight, Color.FromArgb(255, 233, 233, 233) };
2067
yield return new object[] {
SystemColors
.ControlLightLight, Color.FromArgb(255, 255, 255, 255) };
2096
yield return new object[] {
SystemColors
.ControlDarkDark, -1.5f, Color.FromArgb(255, 249, 249, 249) };
2097
yield return new object[] {
SystemColors
.ControlDark, -1.5f, Color.FromArgb(255, 89, 89, 89) };
2098
yield return new object[] {
SystemColors
.Control, -1.5f, Color.FromArgb(255, 185, 185, 185) };
2099
yield return new object[] {
SystemColors
.ControlLight, -1.5f, Color.FromArgb(255, 207, 207, 207) };
2100
yield return new object[] {
SystemColors
.ControlLightLight, -1.5f, Color.FromArgb(255, 255, 255, 255) };
2116
yield return new object[] {
SystemColors
.ControlDarkDark, -1f, Color.FromArgb(255, 29, 29, 29) };
2117
yield return new object[] {
SystemColors
.ControlDark, -1f, Color.FromArgb(255, 112, 112, 112) };
2118
yield return new object[] {
SystemColors
.Control, -1f, Color.FromArgb(255, 199, 199, 199) };
2119
yield return new object[] {
SystemColors
.ControlLight, -1f, Color.FromArgb(255, 213, 213, 213) };
2120
yield return new object[] {
SystemColors
.ControlLightLight, -1f, Color.FromArgb(255, 255, 255, 255) };
2136
yield return new object[] {
SystemColors
.ControlDarkDark, -0.5f, Color.FromArgb(255, 68, 68, 68) };
2137
yield return new object[] {
SystemColors
.ControlDark, -0.5f, Color.FromArgb(255, 137, 137, 137) };
2138
yield return new object[] {
SystemColors
.Control, -0.5f, Color.FromArgb(255, 213, 213, 213) };
2139
yield return new object[] {
SystemColors
.ControlLight, -0.5f, Color.FromArgb(255, 221, 221, 221) };
2140
yield return new object[] {
SystemColors
.ControlLightLight, -0.5f, Color.FromArgb(255, 255, 255, 255) };
2156
yield return new object[] {
SystemColors
.ControlDarkDark, -0.25f, Color.FromArgb(255, 87, 87, 87) };
2157
yield return new object[] {
SystemColors
.ControlDark, -0.25f, Color.FromArgb(255, 148, 148, 148) };
2158
yield return new object[] {
SystemColors
.Control, -0.25f, Color.FromArgb(255, 220, 220, 220) };
2159
yield return new object[] {
SystemColors
.ControlLight, -0.25f, Color.FromArgb(255, 224, 224, 224) };
2160
yield return new object[] {
SystemColors
.ControlLightLight, -0.25f, Color.FromArgb(255, 255, 255, 255) };
2176
yield return new object[] {
SystemColors
.ControlDarkDark, 0f, Color.FromArgb(255, 105, 105, 105) };
2177
yield return new object[] {
SystemColors
.ControlDark, 0f, Color.FromArgb(255, 160, 160, 160) };
2178
yield return new object[] {
SystemColors
.Control, 0f,
SystemColors
.ControlLight };
2179
yield return new object[] {
SystemColors
.ControlLight, 0f, Color.FromArgb(255, 227, 227, 227) };
2180
yield return new object[] {
SystemColors
.ControlLightLight, 0f, Color.FromArgb(255, 255, 255, 255) };
2196
yield return new object[] {
SystemColors
.ControlDarkDark, 0.25f, Color.FromArgb(255, 123, 123, 123) };
2197
yield return new object[] {
SystemColors
.ControlDark, 0.25f, Color.FromArgb(255, 172, 172, 172) };
2198
yield return new object[] {
SystemColors
.Control, 0.25f, Color.FromArgb(255, 234, 234, 234) };
2199
yield return new object[] {
SystemColors
.ControlLight, 0.25f, Color.FromArgb(255, 230, 230, 230) };
2200
yield return new object[] {
SystemColors
.ControlLightLight, 0.25f, Color.FromArgb(255, 255, 255, 255) };
2216
yield return new object[] {
SystemColors
.ControlDarkDark, 0.5f, Color.FromArgb(255, 142, 142, 142) };
2217
yield return new object[] {
SystemColors
.ControlDark, 0.5f, Color.FromArgb(255, 183, 183, 183) };
2218
yield return new object[] {
SystemColors
.Control, 0.5f, Color.FromArgb(255, 241, 241, 241) };
2219
yield return new object[] {
SystemColors
.ControlLight, 0.5f, Color.FromArgb(255, 233, 233, 233) };
2220
yield return new object[] {
SystemColors
.ControlLightLight, 0.5f, Color.FromArgb(255, 255, 255, 255) };
2236
yield return new object[] {
SystemColors
.ControlDarkDark, 1f, Color.FromArgb(255, 180, 180, 180) };
2237
yield return new object[] {
SystemColors
.ControlDark, 1f, Color.FromArgb(255, 208, 208, 208) };
2238
yield return new object[] {
SystemColors
.Control, 1f,
SystemColors
.ControlLightLight };
2239
yield return new object[] {
SystemColors
.ControlLight, 1f, Color.FromArgb(255, 241, 241, 241) };
2240
yield return new object[] {
SystemColors
.ControlLightLight, 1f, Color.FromArgb(255, 255, 255, 255) };
2256
yield return new object[] {
SystemColors
.ControlDarkDark, 1.5f, Color.FromArgb(255, 217, 217, 217) };
2257
yield return new object[] {
SystemColors
.ControlDark, 1.5f, Color.FromArgb(255, 231, 231, 231) };
2258
yield return new object[] {
SystemColors
.Control, 1.5f, Color.FromArgb(255, 13, 13, 13) };
2259
yield return new object[] {
SystemColors
.ControlLight, 1.5f, Color.FromArgb(255, 247, 247, 247) };
2288
yield return new object[] {
SystemColors
.ControlDarkDark, Color.FromArgb(255, 180, 180, 180) };
2289
yield return new object[] {
SystemColors
.ControlDark, Color.FromArgb(255, 208, 208, 208) };
2290
yield return new object[] {
SystemColors
.Control,
SystemColors
.ControlLightLight };
2291
yield return new object[] {
SystemColors
.ControlLight, Color.FromArgb(255, 241, 241, 241) };
2292
yield return new object[] {
SystemColors
.ControlLightLight, Color.FromArgb(255, 255, 255, 255) };
System\Windows\Forms\ControlPaintTests.Rendering.cs (18)
101
ControlPaint.DrawBorder(graphics, bounds,
SystemColors
.Control, ButtonBorderStyle.Inset);
118
State.Pen(16, ControlPaint.DarkDark(
SystemColors
.Control), penStyle),
124
State.Pen(16, ControlPaint.DarkDark(
SystemColors
.Control), penStyle),
130
State.Pen(16, ControlPaint.LightLight(
SystemColors
.Control), penStyle),
136
State.Pen(16, ControlPaint.LightLight(
SystemColors
.Control), penStyle),
142
State.Pen(16, ControlPaint.Light(
SystemColors
.Control), penStyle),
148
State.Pen(16, ControlPaint.Light(
SystemColors
.Control), penStyle),
157
State.Pen(16,
SystemColors
.ControlLight, penStyle),
163
State.Pen(16,
SystemColors
.ControlLight, penStyle),
250
ControlPaint.DrawBorder(graphics, bounds,
SystemColors
.Control, ButtonBorderStyle.Outset);
269
State.Pen(16,
SystemColors
.ControlLightLight, penStyle),
275
State.Pen(16,
SystemColors
.ControlLightLight, penStyle),
281
State.Pen(16,
SystemColors
.ControlDarkDark, penStyle),
287
State.Pen(16,
SystemColors
.ControlDarkDark, penStyle),
293
State.Pen(16,
SystemColors
.Control, penStyle),
299
State.Pen(16,
SystemColors
.Control, penStyle),
305
State.Pen(16,
SystemColors
.ControlDark, penStyle),
311
State.Pen(16,
SystemColors
.ControlDark, penStyle),
System\Windows\Forms\ControlTests.cs (2)
481
Assert.Equal(
SystemColors
.Control, Control.DefaultBackColor);
487
Assert.Equal(
SystemColors
.ControlText, Control.DefaultForeColor);
System\Windows\Forms\DataGridViewTests.cs (3)
2338
BackColor =
SystemColors
.Info,
2340
SelectionBackColor =
SystemColors
.Highlight,
2341
SelectionForeColor =
SystemColors
.HighlightText,
System\Windows\Forms\DataGridViewTests.Rendering.cs (6)
57
State.Brush(
SystemColors
.ButtonShadow, BRUSH_STYLE.BS_SOLID),
88
State.Brush(
SystemColors
.ButtonHighlight, BRUSH_STYLE.BS_SOLID),
94
State.Pen(16,
SystemColors
.Desktop, penStyle),
123
BackColor =
SystemColors
.Info,
125
SelectionBackColor =
SystemColors
.Highlight,
126
SelectionForeColor =
SystemColors
.HighlightText,
System\Windows\Forms\DataGridViewTextBoxEditingControlTests.cs (41)
33
Assert.Equal(
SystemColors
.Window, control.BackColor);
78
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
546
yield return new object[] { new DataGridViewCellStyle(), null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, false, HorizontalAlignment.Left, false };
572
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, false, HorizontalAlignment.Center, false
581
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, true, HorizontalAlignment.Center, true
590
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, false, HorizontalAlignment.Left, false
599
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, true, HorizontalAlignment.Left, true
608
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, false, HorizontalAlignment.Right, false
617
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, true, HorizontalAlignment.Right, true
627
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, false, HorizontalAlignment.Center, false
636
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, true, HorizontalAlignment.Center, true
645
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, false, HorizontalAlignment.Left, false
654
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, true, HorizontalAlignment.Left, true
663
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, false, HorizontalAlignment.Right, false
672
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, true, HorizontalAlignment.Right, true
682
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, false, HorizontalAlignment.Center, false
691
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, true, HorizontalAlignment.Center, false
700
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, false, HorizontalAlignment.Left, false
709
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, true, HorizontalAlignment.Left, false
718
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, false, HorizontalAlignment.Right, false
727
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, true, HorizontalAlignment.Right, false
755
yield return new object[] { new DataGridViewCellStyle(), null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00), Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, false, HorizontalAlignment.Left, false };
764
yield return new object[] { customStyle, font, Color.Gray,
SystemColors
.Control, Color.Green, false, HorizontalAlignment.Left, false };
781
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00), Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, false, HorizontalAlignment.Center, false
790
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00), Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, true, HorizontalAlignment.Center, true
799
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00), Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, false, HorizontalAlignment.Left, false
808
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00), Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, true, HorizontalAlignment.Left, true
817
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00), Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, false, HorizontalAlignment.Right, false
826
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00), Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, true, HorizontalAlignment.Right, true
836
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00), Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, false, HorizontalAlignment.Center, false
845
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00), Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, true, HorizontalAlignment.Center, true
854
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00), Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, false, HorizontalAlignment.Left, false
863
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00), Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, true, HorizontalAlignment.Left, true
872
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00), Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, false, HorizontalAlignment.Right, false
881
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00), Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, true, HorizontalAlignment.Right, true
891
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00), Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, false, HorizontalAlignment.Center, false
900
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00), Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, true, HorizontalAlignment.Center, false
909
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00), Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, false, HorizontalAlignment.Left, false
918
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00), Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, true, HorizontalAlignment.Left, false
927
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00), Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, false, HorizontalAlignment.Right, false
936
null, Color.FromArgb(0xFF, 0x00, 0x00, 0x00), Color.FromArgb(0xFF, 0x00, 0x00, 0x00),
SystemColors
.WindowText, true, HorizontalAlignment.Right, false
System\Windows\Forms\DateTimePickerTests.cs (6)
31
Assert.Equal(
SystemColors
.Window, control.BackColor);
39
Assert.Equal(
SystemColors
.Window, control.CalendarMonthBackground);
40
Assert.Equal(
SystemColors
.ActiveCaption, control.CalendarTitleBackColor);
41
Assert.Equal(
SystemColors
.ActiveCaptionText, control.CalendarTitleForeColor);
42
Assert.Equal(
SystemColors
.GrayText, control.CalendarTrailingForeColor);
78
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
System\Windows\Forms\DomainUpDownTests.cs (2)
43
_sub.BackColor.Should().Be(
SystemColors
.Window);
100
_sub.ForeColor.Should().Be(
SystemColors
.WindowText);
System\Windows\Forms\DrawItemEventArgsTests.cs (12)
13
yield return new object[] { null, Rectangle.Empty, -2, DrawItemState.None - 1,
SystemColors
.HighlightText,
SystemColors
.Highlight };
14
yield return new object[] { SystemFonts.DefaultFont, new Rectangle(1, 2, 3, 4), -1, DrawItemState.None,
SystemColors
.WindowText,
SystemColors
.Window };
15
yield return new object[] { SystemFonts.DefaultFont, new Rectangle(-1, 2, -3, -4), 0, DrawItemState.Selected,
SystemColors
.HighlightText,
SystemColors
.Highlight };
16
yield return new object[] { SystemFonts.DefaultFont, new Rectangle(1, 2, 3, 4), 1, DrawItemState.Focus,
SystemColors
.WindowText,
SystemColors
.Window };
17
yield return new object[] { SystemFonts.DefaultFont, new Rectangle(1, 2, 3, 4), 1, DrawItemState.Focus | DrawItemState.NoFocusRect,
SystemColors
.WindowText,
SystemColors
.Window };
58
Assert.Equal((state & DrawItemState.Selected) == DrawItemState.Selected ?
SystemColors
.HighlightText : foreColor, e.ForeColor);
59
Assert.Equal((state & DrawItemState.Selected) == DrawItemState.Selected ?
SystemColors
.Highlight : backColor, e.BackColor);
System\Windows\Forms\FontDialogTests.cs (2)
168
yield return new object[] {
SystemColors
.ControlText,
SystemColors
.ControlText };
System\Windows\Forms\ListBoxTests.cs (18)
27
Assert.Equal(
SystemColors
.Window, control.BackColor);
73
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
349
yield return new object[] { Color.Empty,
SystemColors
.Window };
372
yield return new object[] { Color.Empty,
SystemColors
.Window, 0 };
430
Assert.Equal(
SystemColors
.Window, control.BackColor);
452
Assert.Equal(
SystemColors
.Window, control.BackColor);
468
Assert.Equal(
SystemColors
.Window, control.BackColor);
1240
yield return new object[] { Color.Empty,
SystemColors
.WindowText };
1266
yield return new object[] { Color.Empty,
SystemColors
.WindowText, 0 };
1327
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
1349
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
1365
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
5978
Assert.Equal(
SystemColors
.Window, control.BackColor);
5983
Assert.Equal(
SystemColors
.Window, control.BackColor);
5987
Assert.Equal(
SystemColors
.Window, control.BackColor);
5997
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
6002
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
6006
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
System\Windows\Forms\ListViewItemTests.cs (64)
16
Assert.Equal(
SystemColors
.Window, item.BackColor);
21
Assert.Equal(
SystemColors
.WindowText, item.ForeColor);
44
yield return new object[] { null, null, Color.Empty, Color.Empty, null, null, string.Empty,
SystemColors
.WindowText,
SystemColors
.Window, string.Empty };
45
yield return new object[] { Array.Empty<string>(), null, Color.Empty, Color.Empty, null, null, string.Empty,
SystemColors
.WindowText,
SystemColors
.Window, string.Empty };
46
yield return new object[] { new string[] { null }, string.Empty, Color.Empty, Color.Empty, null, new ListViewGroup(), string.Empty,
SystemColors
.WindowText,
SystemColors
.Window, string.Empty };
82
yield return new object[] { null, -1, Color.Empty, Color.Empty, null, null,
SystemColors
.WindowText,
SystemColors
.Window, string.Empty };
83
yield return new object[] { Array.Empty<string>(), 0, Color.Empty, Color.Empty, null, null,
SystemColors
.WindowText,
SystemColors
.Window, string.Empty };
84
yield return new object[] { new string[] { null }, 1, Color.Empty, Color.Empty, null, new ListViewGroup(),
SystemColors
.WindowText,
SystemColors
.Window, string.Empty };
120
yield return new object[] { null, null, Color.Empty, Color.Empty, null, string.Empty,
SystemColors
.WindowText,
SystemColors
.Window, string.Empty };
121
yield return new object[] { Array.Empty<string>(), null, Color.Empty, Color.Empty, null, string.Empty,
SystemColors
.WindowText,
SystemColors
.Window, string.Empty };
122
yield return new object[] { new string[] { null }, string.Empty, Color.Empty, Color.Empty, null, string.Empty,
SystemColors
.WindowText,
SystemColors
.Window, string.Empty };
158
yield return new object[] { null, -1, Color.Empty, Color.Empty, null,
SystemColors
.WindowText,
SystemColors
.Window, string.Empty };
159
yield return new object[] { Array.Empty<string>(), 0, Color.Empty, Color.Empty, null,
SystemColors
.WindowText,
SystemColors
.Window, string.Empty };
160
yield return new object[] { new string[] { null }, 1, Color.Empty, Color.Empty, null,
SystemColors
.WindowText,
SystemColors
.Window, string.Empty };
206
Assert.Equal(
SystemColors
.Window, item.BackColor);
211
Assert.Equal(
SystemColors
.WindowText, item.ForeColor);
243
Assert.Equal(
SystemColors
.Window, item.BackColor);
248
Assert.Equal(
SystemColors
.WindowText, item.ForeColor);
281
Assert.Equal(
SystemColors
.Window, item.BackColor);
286
Assert.Equal(
SystemColors
.WindowText, item.ForeColor);
319
Assert.Equal(
SystemColors
.Window, item.BackColor);
324
Assert.Equal(
SystemColors
.WindowText, item.ForeColor);
356
Assert.Equal(
SystemColors
.Window, item.BackColor);
361
Assert.Equal(
SystemColors
.WindowText, item.ForeColor);
394
Assert.Equal(
SystemColors
.Window, item.BackColor);
399
Assert.Equal(
SystemColors
.WindowText, item.ForeColor);
432
Assert.Equal(
SystemColors
.Window, item.BackColor);
437
Assert.Equal(
SystemColors
.WindowText, item.ForeColor);
469
Assert.Equal(
SystemColors
.Window, item.BackColor);
474
Assert.Equal(
SystemColors
.WindowText, item.ForeColor);
507
Assert.Equal(
SystemColors
.Window, item.BackColor);
512
Assert.Equal(
SystemColors
.WindowText, item.ForeColor);
545
Assert.Equal(
SystemColors
.Window, item.BackColor);
550
Assert.Equal(
SystemColors
.WindowText, item.ForeColor);
583
Assert.Equal(
SystemColors
.Window, item.BackColor);
588
Assert.Equal(
SystemColors
.WindowText, item.ForeColor);
620
Assert.Equal(
SystemColors
.Window, item.BackColor);
625
Assert.Equal(
SystemColors
.WindowText, item.ForeColor);
658
Assert.Equal(
SystemColors
.Window, item.BackColor);
663
Assert.Equal(
SystemColors
.WindowText, item.ForeColor);
696
Assert.Equal(
SystemColors
.Window, item.BackColor);
701
Assert.Equal(
SystemColors
.WindowText, item.ForeColor);
733
Assert.Equal(
SystemColors
.Window, item.BackColor);
738
Assert.Equal(
SystemColors
.WindowText, item.ForeColor);
772
Assert.Equal(
SystemColors
.Window, item.BackColor);
777
Assert.Equal(
SystemColors
.WindowText, item.ForeColor);
802
Assert.Equal(
SystemColors
.Window, item.BackColor);
807
Assert.Equal(
SystemColors
.WindowText, item.ForeColor);
849
yield return new object[] { Color.Empty,
SystemColors
.Window };
868
Assert.Equal(
SystemColors
.Window, item.BackColor);
904
yield return new object[] { Color.Empty,
SystemColors
.WindowText };
925
Assert.Equal(
SystemColors
.WindowText, item.ForeColor);
System\Windows\Forms\ListViewSubItemCollectionTests.cs (4)
258
yield return new object[] { null, Color.Empty, Color.Empty, null,
SystemColors
.WindowText,
SystemColors
.Window, string.Empty };
388
yield return new object[] { Color.Empty, Color.Empty, null,
SystemColors
.WindowText,
SystemColors
.Window };
System\Windows\Forms\ListViewSubItemTests.cs (25)
17
Assert.Equal(
SystemColors
.Window, subItem.BackColor);
20
Assert.Equal(
SystemColors
.WindowText, subItem.ForeColor);
44
Assert.Equal(
SystemColors
.Window, subItem.BackColor);
47
Assert.Equal(
SystemColors
.WindowText, subItem.ForeColor);
55
yield return new object[] { null, null, Color.Empty, Color.Empty, null,
SystemColors
.WindowText,
SystemColors
.Window, string.Empty };
94
Assert.Equal(
SystemColors
.Window, subItem.BackColor);
105
Assert.Equal(
SystemColors
.Window, subItem.BackColor);
109
Assert.Equal(
SystemColors
.Window, subItem.BackColor);
130
Assert.Equal(
SystemColors
.Window, subItem.BackColor);
136
yield return new object[] { Color.Empty,
SystemColors
.Window };
230
Assert.Equal(
SystemColors
.Window, subItem.BackColor);
343
Assert.Equal(
SystemColors
.WindowText, subItem.ForeColor);
354
Assert.Equal(
SystemColors
.WindowText, subItem.ForeColor);
358
Assert.Equal(
SystemColors
.WindowText, subItem.ForeColor);
379
Assert.Equal(
SystemColors
.WindowText, subItem.ForeColor);
384
yield return new object[] { Color.Empty,
SystemColors
.WindowText };
543
Assert.Equal(
SystemColors
.Window, subItem.BackColor);
545
Assert.Equal(
SystemColors
.WindowText, subItem.ForeColor);
548
Assert.Equal(
SystemColors
.Window, subItem.BackColor);
550
Assert.Equal(
SystemColors
.WindowText, subItem.ForeColor);
560
Assert.Equal(
SystemColors
.Window, subItem.BackColor);
562
Assert.Equal(
SystemColors
.WindowText, subItem.ForeColor);
565
Assert.Equal(
SystemColors
.Window, subItem.BackColor);
567
Assert.Equal(
SystemColors
.WindowText, subItem.ForeColor);
System\Windows\Forms\ListViewTests.cs (8)
33
Assert.Equal(
SystemColors
.Window, control.BackColor);
81
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
452
yield return new object[] { Color.Empty,
SystemColors
.Window };
475
yield return new object[] { Color.Empty,
SystemColors
.Window, 0 };
543
Assert.Equal(
SystemColors
.Window, control.BackColor);
1308
yield return new object[] { Color.Empty,
SystemColors
.WindowText };
1334
yield return new object[] { Color.Empty,
SystemColors
.WindowText, 0 };
1405
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
System\Windows\Forms\MdiClientTests.cs (1)
26
Assert.Equal(
SystemColors
.AppWorkspace, control.BackColor);
System\Windows\Forms\MonthCalendarTests.cs (11)
30
Assert.Equal(
SystemColors
.Window, control.BackColor);
83
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
131
Assert.Equal(
SystemColors
.ActiveCaption, control.TitleBackColor);
132
Assert.Equal(
SystemColors
.ActiveCaptionText, control.TitleForeColor);
137
Assert.Equal(
SystemColors
.GrayText, control.TrailingForeColor);
281
yield return new object[] { Color.Empty,
SystemColors
.Window };
304
yield return new object[] { Color.Empty,
SystemColors
.Window, 0 };
362
Assert.Equal(
SystemColors
.Window, control.BackColor);
921
yield return new object[] { Color.Empty,
SystemColors
.WindowText };
947
yield return new object[] { Color.Empty,
SystemColors
.WindowText, 0 };
1008
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
System\Windows\Forms\ProgressBarTests.cs (6)
63
Assert.Equal(
SystemColors
.Highlight, control.ForeColor);
633
Assert.Equal(
SystemColors
.Highlight, control.ForeColor);
649
Assert.Equal(
SystemColors
.Highlight, control.ForeColor);
2563
Assert.Equal(
SystemColors
.Highlight, control.ForeColor);
2568
Assert.Equal(
SystemColors
.Highlight, control.ForeColor);
2572
Assert.Equal(
SystemColors
.Highlight, control.ForeColor);
System\Windows\Forms\PropertyGridTests.cs (46)
56
Assert.Equal(
SystemColors
.ControlText, control.CategoryForeColor);
57
Assert.Equal(
SystemColors
.Control, control.CategorySplitterColor);
62
Assert.Equal(
SystemColors
.Control, control.CommandsBackColor);
63
Assert.Equal(
SystemColors
.ControlDark, control.CommandsBorderColor);
65
Assert.Equal(
SystemColors
.ControlText, control.CommandsForeColor);
87
Assert.Equal(
SystemColors
.GrayText, control.DisabledItemForeColor);
107
Assert.Equal(
SystemColors
.Control, control.HelpBackColor);
108
Assert.Equal(
SystemColors
.ControlText, control.HelpForeColor);
109
Assert.Equal(
SystemColors
.ControlDark, control.HelpBorderColor);
122
Assert.Equal(
SystemColors
.InactiveBorder, control.LineColor);
140
Assert.Equal(
SystemColors
.Highlight, control.SelectedItemWithFocusBackColor);
141
Assert.Equal(
SystemColors
.HighlightText, control.SelectedItemWithFocusForeColor);
162
Assert.Equal(
SystemColors
.Window, control.ViewBackColor);
163
Assert.Equal(
SystemColors
.ControlDark, control.ViewBorderColor);
164
Assert.Equal(
SystemColors
.WindowText, control.ViewForeColor);
761
Assert.Equal(
SystemColors
.ControlText, control.CategoryForeColor);
777
Assert.Equal(
SystemColors
.ControlText, control.CategoryForeColor);
839
Assert.Equal(
SystemColors
.Control, control.CategorySplitterColor);
855
Assert.Equal(
SystemColors
.Control, control.CategorySplitterColor);
1002
Assert.Equal(
SystemColors
.Control, control.CommandsBackColor);
1018
Assert.Equal(
SystemColors
.Control, control.CommandsBackColor);
1087
Assert.Equal(
SystemColors
.ControlDark, control.CommandsBorderColor);
1103
Assert.Equal(
SystemColors
.ControlDark, control.CommandsBorderColor);
1250
Assert.Equal(
SystemColors
.ControlText, control.CommandsForeColor);
1266
Assert.Equal(
SystemColors
.ControlText, control.CommandsForeColor);
1499
Assert.Equal(
SystemColors
.GrayText, control.DisabledItemForeColor);
1515
Assert.Equal(
SystemColors
.GrayText, control.DisabledItemForeColor);
1790
Assert.Equal(
SystemColors
.Control, control.HelpBackColor);
1806
Assert.Equal(
SystemColors
.Control, control.HelpBackColor);
1875
Assert.Equal(
SystemColors
.ControlDark, control.HelpBorderColor);
1891
Assert.Equal(
SystemColors
.ControlDark, control.HelpBorderColor);
1953
Assert.Equal(
SystemColors
.ControlText, control.HelpForeColor);
1969
Assert.Equal(
SystemColors
.ControlText, control.HelpForeColor);
2209
Assert.Equal(
SystemColors
.InactiveBorder, control.LineColor);
2225
Assert.Equal(
SystemColors
.InactiveBorder, control.LineColor);
2456
Assert.Equal(
SystemColors
.Highlight, control.SelectedItemWithFocusBackColor);
2472
Assert.Equal(
SystemColors
.Highlight, control.SelectedItemWithFocusBackColor);
2534
Assert.Equal(
SystemColors
.HighlightText, control.SelectedItemWithFocusForeColor);
2550
Assert.Equal(
SystemColors
.HighlightText, control.SelectedItemWithFocusForeColor);
3260
Assert.Equal(
SystemColors
.Window, control.ViewBackColor);
3276
Assert.Equal(
SystemColors
.Window, control.ViewBackColor);
3345
Assert.Equal(
SystemColors
.ControlDark, control.ViewBorderColor);
3361
Assert.Equal(
SystemColors
.ControlDark, control.ViewBorderColor);
3367
yield return new object[] { Color.Empty,
SystemColors
.ControlText };
3430
Assert.Equal(
SystemColors
.WindowText, control.ViewForeColor);
3446
Assert.Equal(
SystemColors
.WindowText, control.ViewForeColor);
System\Windows\Forms\RichTextBoxTests.cs (9)
37
Assert.Equal(
SystemColors
.Window, control.BackColor);
82
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
646
yield return new object[] { Color.Empty,
SystemColors
.Window };
727
Assert.Equal(
SystemColors
.Window, control.BackColor);
1677
yield return new object[] { Color.Empty,
SystemColors
.WindowText };
1703
yield return new object[] { Color.Empty,
SystemColors
.WindowText, 0 };
1803
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
3829
Assert.Equal(
SystemColors
.Window, control.SelectionBackColor);
3931
yield return new object[] { Color.Empty,
SystemColors
.Window };
System\Windows\Forms\TabControlTests.cs (8)
541
Assert.Equal(
SystemColors
.Control, control.BackColor);
546
Assert.Equal(
SystemColors
.Control, control.BackColor);
564
Assert.Equal(
SystemColors
.Control, control.BackColor);
572
Assert.Equal(
SystemColors
.Control, control.BackColor);
595
Assert.Equal(
SystemColors
.Control, control.BackColor);
600
Assert.Equal(
SystemColors
.Control, control.BackColor);
605
Assert.Equal(
SystemColors
.Control, control.BackColor);
611
Assert.Equal(
SystemColors
.Control, control.BackColor);
System\Windows\Forms\ToolStripButtonTests.Rendering.cs (4)
85
State.Brush(
SystemColors
.Highlight, BRUSH_STYLE.BS_SOLID)),
111
State.Brush(
SystemColors
.Highlight, BRUSH_STYLE.BS_SOLID)),
137
State.Brush(
SystemColors
.Highlight, BRUSH_STYLE.BS_SOLID)),
164
State.Brush(
SystemColors
.Highlight, BRUSH_STYLE.BS_SOLID)),
System\Windows\Forms\ToolStripRenderEventArgsTests.cs (6)
29
yield return new object[] { new ToolStrip(), new Rectangle(0, 0, 100, 25),
SystemColors
.Control };
31
yield return new object[] { new ToolStripDropDown(), new Rectangle(0, 0, 100, 25),
SystemColors
.Menu };
32
yield return new object[] { new MenuStrip(), new Rectangle(0, 0, 200, 24),
SystemColors
.MenuBar };
52
yield return new object[] { new ToolStrip(), new Rectangle(1, 2, 3, 4), Color.Empty,
SystemColors
.Control };
54
yield return new object[] { new ToolStripDropDown(), new Rectangle(1, 2, 3, 4), Color.Empty,
SystemColors
.Menu };
55
yield return new object[] { new MenuStrip(), new Rectangle(1, 2, 3, 4), Color.Empty,
SystemColors
.MenuBar };
System\Windows\Forms\ToolStripSeparatorTests.cs (1)
54
Assert.Equal(
SystemColors
.ControlDark, item.ForeColor);
System\Windows\Forms\ToolTipTests.cs (4)
21
Assert.Equal(
SystemColors
.Info, toolTip.BackColor);
27
Assert.Equal(
SystemColors
.InfoText, toolTip.ForeColor);
51
Assert.Equal(
SystemColors
.Info, toolTip.BackColor);
57
Assert.Equal(
SystemColors
.InfoText, toolTip.ForeColor);
System\Windows\Forms\TreeViewTests.cs (7)
25
Assert.Equal(
SystemColors
.Window, control.BackColor);
67
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
698
yield return new object[] { Color.Empty,
SystemColors
.Window };
721
yield return new object[] { Color.Empty,
SystemColors
.Window, 0 };
779
Assert.Equal(
SystemColors
.Window, control.BackColor);
1459
yield return new object[] { Color.Empty,
SystemColors
.WindowText };
1521
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
System\Windows\Forms\UpDownBaseTests.cs (7)
29
Assert.Equal(
SystemColors
.Window, control.BackColor);
87
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
510
yield return new object[] { Color.Empty,
SystemColors
.Window };
533
yield return new object[] { Color.Empty,
SystemColors
.Window, 1 };
590
Assert.Equal(
SystemColors
.Window, control.BackColor);
935
yield return new object[] { Color.Empty,
SystemColors
.WindowText };
1013
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
TextBoxBaseTests.cs (6)
378
Assert.Equal(
SystemColors
.Control, control.BackColor);
383
yield return new object[] { Color.Empty,
SystemColors
.Window };
429
Assert.Equal(
SystemColors
.Window, control.BackColor);
1161
yield return new object[] { Color.Empty,
SystemColors
.WindowText };
1187
yield return new object[] { Color.Empty,
SystemColors
.WindowText, 0 };
1248
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
TextBoxTests.cs (2)
32
Assert.Equal(
SystemColors
.Window, control.BackColor);
72
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
TrackBarTests.cs (9)
65
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
699
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
704
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
722
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
730
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
752
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
757
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
762
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
768
Assert.Equal(
SystemColors
.WindowText, control.ForeColor);
System.Windows.Forms.UI.IntegrationTests (21)
PropertyGridTests.cs (21)
107
_propertyGrid.CommandsBorderColor.Should().Be(
SystemColors
.ControlDark);
116
_propertyGrid.HelpBorderColor.Should().Be(
SystemColors
.ControlDark);
125
_propertyGrid.SelectedItemWithFocusBackColor.Should().Be(
SystemColors
.Highlight);
134
_propertyGrid.SelectedItemWithFocusForeColor.Should().Be(
SystemColors
.HighlightText);
143
_propertyGrid.DisabledItemForeColor.Should().Be(
SystemColors
.GrayText);
152
_propertyGrid.CategorySplitterColor.Should().Be(
SystemColors
.Control);
161
_propertyGrid.ForeColor.Should().Be(
SystemColors
.ControlText);
189
_propertyGrid.BackColor.Should().Be(
SystemColors
.Control);
208
_propertyGrid.CommandsBackColor.Should().Be(
SystemColors
.Control);
217
_propertyGrid.CommandsForeColor.Should().Be(
SystemColors
.ControlText);
249
_propertyGrid.HelpBackColor.Should().Be(
SystemColors
.Control);
258
_propertyGrid.HelpForeColor.Should().Be(
SystemColors
.ControlText);
267
_propertyGrid.LineColor.Should().Be(
SystemColors
.InactiveBorder);
338
_propertyGrid.ViewBackColor.Should().Be(
SystemColors
.Window);
347
_propertyGrid.ViewBorderColor.Should().Be(
SystemColors
.ControlDark);
356
_propertyGrid.ViewForeColor.Should().Be(
SystemColors
.WindowText);
365
_propertyGrid.CategoryForeColor.Should().Be(
SystemColors
.ControlText);
367
_propertyGrid.CategoryForeColor =
SystemColors
.MenuHighlight;
368
_propertyGrid.CategoryForeColor.Should().Be(
SystemColors
.MenuHighlight);
388
_propertyGrid.CommandsActiveLinkColor =
SystemColors
.ControlDark;
389
_propertyGrid.CommandsActiveLinkColor.Should().Be(
SystemColors
.ControlDark);
WinFormsControlsTest (13)
CustomComCtl32Button.cs (1)
95
Pen pen = new(
SystemColors
.ControlDarkDark, 1);
DataGridViewTest.Designer.cs (7)
57
dataGridViewCellStyle1.BackColor = System.Drawing.
SystemColors
.Control;
59
dataGridViewCellStyle1.ForeColor = System.Drawing.
SystemColors
.WindowText;
60
dataGridViewCellStyle1.SelectionBackColor = System.Drawing.
SystemColors
.Highlight;
61
dataGridViewCellStyle1.SelectionForeColor = System.Drawing.
SystemColors
.HighlightText;
75
dataGridViewCellStyle3.BackColor = System.Drawing.
SystemColors
.Info;
78
dataGridViewCellStyle3.SelectionBackColor = System.Drawing.
SystemColors
.Highlight;
79
dataGridViewCellStyle3.SelectionForeColor = System.Drawing.
SystemColors
.HighlightText;
Dialogs.Designer.cs (1)
52
this.propertyGrid1.CommandsBorderColor = System.Drawing.
SystemColors
.Control;
MessageBoxes.Designer.cs (1)
40
this.propertyGrid1.CommandsBorderColor = System.Drawing.
SystemColors
.Control;
MultipleControls.Designer.cs (2)
225
this.checkedListBox1.BackColor = System.Drawing.
SystemColors
.Window;
281
this.checkedListBox2.BackColor = System.Drawing.
SystemColors
.Window;
PropertyGrid.Designer.cs (1)
39
this.propertyGrid1.CommandsBorderColor = System.Drawing.
SystemColors
.Control;