19 overrides of BackColor
System.Windows.Forms (19)
System\Windows\Forms\ActiveX\AxHost.cs (1)
254public override Color BackColor
System\Windows\Forms\Controls\Buttons\ButtonBase.cs (1)
154public override Color BackColor
System\Windows\Forms\Controls\ComboBox\ComboBox.cs (1)
256public override Color BackColor
System\Windows\Forms\Controls\DataGridView\DataGridView.cs (1)
991public override Color BackColor
System\Windows\Forms\Controls\DateTimePicker\DateTimePicker.cs (1)
128public override Color BackColor
System\Windows\Forms\Controls\ListBoxes\ListBox.cs (1)
153public override Color BackColor
System\Windows\Forms\Controls\ListView\ListView.cs (1)
346public override Color BackColor
System\Windows\Forms\Controls\MonthCalendar\MonthCalendar.cs (1)
196public override Color BackColor
System\Windows\Forms\Controls\PropertyGrid\PropertyGrid.cs (1)
313public override Color BackColor
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\PropertyGridView.cs (1)
149public override Color BackColor
System\Windows\Forms\Controls\TabControl\TabControl.cs (1)
170public override Color BackColor
System\Windows\Forms\Controls\TabControl\TabPage.cs (1)
98public override Color BackColor
System\Windows\Forms\Controls\TextBox\TextBoxBase.cs (1)
282public override Color BackColor
System\Windows\Forms\Controls\ToolStrips\ToolStripContentPanel.cs (1)
92public override Color BackColor
System\Windows\Forms\Controls\TreeView\TreeView.cs (1)
196public override Color BackColor
System\Windows\Forms\Controls\UpDown\UpDownBase.cs (1)
132public override Color BackColor
System\Windows\Forms\Controls\WebBrowser\WebBrowserBase.cs (1)
1242public override Color BackColor
System\Windows\Forms\Form.cs (1)
587public override Color BackColor
System\Windows\Forms\Scrolling\ScrollBar.cs (1)
76public override Color BackColor
210 writes to BackColor
Accessibility_Core_App (13)
CommonControl2.Designer.cs (1)
99this.progressBar1.BackColor = System.Drawing.Color.Lime;
ContainerControls.Designer.cs (3)
122this.flowLayoutPanel2.BackColor = System.Drawing.Color.White; 521this.flowLayoutPanel1.BackColor = System.Drawing.Color.White; 705this.flowLayoutPanel3.BackColor = System.Drawing.Color.White;
ContainerControls2.Designer.cs (9)
90this.splitContainer1.Panel1.BackColor = System.Drawing.Color.Silver; 96this.splitContainer1.Panel2.BackColor = System.Drawing.Color.Red; 137this.tableLayoutPanel1.BackColor = System.Drawing.Color.Red; 270this.flowLayoutPanel4.BackColor = System.Drawing.Color.Green; 289this.groupBox5.BackColor = System.Drawing.Color.Green; 312this.panel4.BackColor = System.Drawing.Color.Green; 337this.splitContainer2.Panel1.BackColor = System.Drawing.Color.Green; 341this.splitContainer2.Panel2.BackColor = System.Drawing.Color.Red; 402this.tableLayoutPanel2.BackColor = System.Drawing.Color.Green;
DesignSurface (11)
MainForm.cs (8)
153pnl.BackColor = Color.Aquamarine; 164l1.BackColor = Color.Coral; 165l2.BackColor = Color.LightGreen; 169sct.BackColor = Color.White; 196l1.BackColor = Color.Coral; 324splitContainer.BackColor = Color.Red; 333userControl.BackColor = Color.LightSkyBlue; 349splitter.BackColor = Color.Green;
MainForm.Designer.cs (1)
74this.splitContainer.Panel1.BackColor = System.Drawing.SystemColors.Window;
MainForm.MyScrollableControl.cs (1)
20BackColor = Color.Red;
MainForm.MyUserControl.cs (1)
23BackColor = Color.LightBlue;
DesignSurfaceExt (3)
DesignSurfaceExt.cs (3)
125ctrl.BackColor = Color.LightGray; 135ctrl.BackColor = Color.DarkGray; 145ctrl.BackColor = Color.White;
PresentationUI (11)
MS\Internal\Documents\Application\DocumentPropertiesDialog.Designer.cs (3)
482this._iconPictureBox.BackColor = System.Drawing.Color.Transparent; 522this._documentDetailBox.BackColor = System.Drawing.Color.Transparent; 646this._fileSystemBox.BackColor = System.Drawing.Color.Transparent;
MS\Internal\Documents\RMEnrollmentPage1.Designer.cs (1)
167_pictureBox.BackColor = System.Drawing.Color.SeaGreen;
MS\Internal\Documents\RMEnrollmentPage2.Designer.cs (3)
127this._pictureBox1.BackColor = System.Drawing.Color.SeaGreen; 180this._pictureBox2.BackColor = System.Drawing.Color.SeaGreen; 199this._pictureBox4.BackColor = System.Drawing.Color.SeaGreen;
MS\Internal\Documents\RMPublishingDialog.Designer.cs (1)
118this.groupBoxMainContent.BackColor = System.Drawing.Color.Transparent;
MS\Internal\Documents\SignatureSummaryDialog.Designer.cs (3)
137_columnHeaderPanel.BackColor = System.Drawing.SystemColors.Control; 164_listboxMainPanel.BackColor = System.Drawing.SystemColors.Info; 174_listboxItemPanel.BackColor = System.Drawing.SystemColors.GradientActiveCaption;
System.Windows.Forms (37)
System\Windows\Forms\ActiveX\AxHost.AxContainer.ExtenderProxy.cs (1)
136control.BackColor = GetColorFromOleColor(value);
System\Windows\Forms\ActiveX\AxHost.cs (1)
257set => base.BackColor = value;
System\Windows\Forms\Control.cs (1)
9027BackColor = Color.Empty;
System\Windows\Forms\Controls\Buttons\ButtonBase.cs (1)
177base.BackColor = value;
System\Windows\Forms\Controls\ComboBox\ComboBox.cs (1)
259set => base.BackColor = value;
System\Windows\Forms\Controls\DataGridView\DataGridView.cs (1)
994set => base.BackColor = value;
System\Windows\Forms\Controls\DataGridView\DataGridView.Methods.cs (1)
2702_editingPanel.BackColor = dgvese.CellStyle.BackColor;
System\Windows\Forms\Controls\DataGridView\DataGridViewComboBoxCell.cs (1)
1266DataGridView.EditingPanel.BackColor = dataGridViewCellStyle.SelectionBackColor;
System\Windows\Forms\Controls\DataGridView\DataGridViewComboBoxEditingControl.cs (1)
80_dataGridView!.EditingPanel.BackColor = opaqueBackColor;
System\Windows\Forms\Controls\DataGridView\DataGridViewTextBoxEditingControl.cs (1)
109_dataGridView.EditingPanel.BackColor = opaqueBackColor;
System\Windows\Forms\Controls\DateTimePicker\DateTimePicker.cs (1)
131set => base.BackColor = value;
System\Windows\Forms\Controls\ListBoxes\ListBox.cs (1)
166set => base.BackColor = value;
System\Windows\Forms\Controls\ListView\ListView.cs (1)
351base.BackColor = value;
System\Windows\Forms\Controls\MonthCalendar\MonthCalendar.cs (1)
207set => base.BackColor = value;
System\Windows\Forms\Controls\PropertyGrid\PropertyGrid.cs (5)
214_helpPane.BackColor = SystemColors.Control; 318base.BackColor = value; 430_commandsPane.BackColor = value; 431_commandsPane.Label.BackColor = value; 631set => _helpPane.BackColor = value;
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\CommandsPane.cs (1)
153Label.BackColor = background;
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\PropertyGridView.cs (1)
152set => base.BackColor = value;
System\Windows\Forms\Controls\TabControl\TabPage.cs (1)
134base.BackColor = value;
System\Windows\Forms\Controls\TextBox\TextBoxBase.cs (1)
299set => base.BackColor = value;
System\Windows\Forms\Controls\ToolStrips\StatusStrip.cs (1)
615BackColor = Color.Transparent;
System\Windows\Forms\Controls\ToolStrips\ToolStrip.cs (1)
369set => base.BackColor = value;
System\Windows\Forms\Controls\ToolStrips\ToolStripContainer.cs (1)
90set => base.BackColor = value;
System\Windows\Forms\Controls\ToolStrips\ToolStripContentPanel.cs (2)
103ParentInternal.BackColor = Color.Transparent; 106base.BackColor = value;
System\Windows\Forms\Controls\ToolStrips\ToolStripControlHost.cs (1)
59set => ControlInternal.BackColor = value;
System\Windows\Forms\Controls\TreeView\TreeView.cs (1)
201base.BackColor = value;
System\Windows\Forms\Controls\UpDown\UpDownBase.cs (1)
137base.BackColor = value; // Don't remove this or you will break serialization.
System\Windows\Forms\Controls\WebBrowser\WebBrowserBase.cs (1)
1245set => base.BackColor = value;
System\Windows\Forms\Design\ComponentEditorForm.cs (1)
194BackColor = SystemColors.ControlDark
System\Windows\Forms\Form.cs (1)
601set => base.BackColor = value;
System\Windows\Forms\MDI\MDIClient.cs (1)
36BackColor = SystemColors.AppWorkspace;
System\Windows\Forms\Printing\PrintPreviewControl.cs (1)
293public override void ResetBackColor() => BackColor = SystemColors.AppWorkspace;
System\Windows\Forms\Scrolling\ScrollBar.cs (1)
79set => base.BackColor = value;
System.Windows.Forms.Design (41)
System\ComponentModel\Design\DesignerActionPanel.MethodLine.cs (1)
23BackColor = Color.Transparent,
System\ComponentModel\Design\DesignerActionPanel.PanelHeaderLine.cs (2)
25BackColor = Color.Transparent, 33BackColor = Color.Transparent,
System\ComponentModel\Design\DesignerActionPanel.TextBoxPropertyLine.cs (4)
26BackColor = Color.Transparent, 34BackColor = Color.Transparent, 166_readOnlyTextBoxLabel.BackColor = SystemColors.Highlight; 172_readOnlyTextBoxLabel.BackColor = SystemColors.Window;
System\ComponentModel\Design\DesignerActionPanel.TextLine.cs (1)
22BackColor = Color.Transparent,
System\Drawing\Design\ColorEditor.ColorPalette.cs (1)
70BackColor = SystemColors.Control;
System\Drawing\Design\ContentAlignmentEditor.ContentUI.cs (1)
110BackColor = SystemColors.Control;
System\Windows\Forms\Design\AnchorEditor.AnchorUI.cs (2)
177BackColor = SystemColors.Window; 193BackColor = SystemColors.Control;
System\Windows\Forms\Design\BorderSidesEditor.BorderSidesEditorUI.cs (2)
94_tableLayoutPanel.BackColor = SystemColors.Window; 152_splitterLabel.BackColor = SystemColors.ControlDark;
System\Windows\Forms\Design\ComponentTray.cs (4)
156BackColor = styleColor; 1424BackColor = styleColor; 1428ctl.BackColor = styleColor; 1461c.BackColor = SystemColors.Highlight;
System\Windows\Forms\Design\DataGridViewColumnTypeEditor.Picker.cs (1)
34BackColor = SystemColors.Control;
System\Windows\Forms\Design\DesignBindingPicker.cs (13)
143BackColor = SystemColors.ControlDark, 151BackColor = SystemColors.Window, 171BackColor = SystemColors.Window, 183BackColor = SystemColors.ControlDark, 190BackColor = SystemColors.Window, 270BackColor = SystemColors.ControlDark, 278BackColor = SystemColors.Window, 296BackColor = SystemColors.Window, 315BackColor = SystemColors.ControlDark, 322BackColor = SystemColors.Window, 344BackColor = SystemColors.Control; 1584_helpTextCtrl.BackColor = SystemColors.Info; 1589_helpTextCtrl.BackColor = SystemColors.Window;
System\Windows\Forms\Design\DesignerFrame.cs (3)
45BackColor = color; 270_splitter.BackColor = color; 274_splitter.BackColor = SystemColors.Control;
System\Windows\Forms\Design\DockEditor.DockUI.cs (2)
187BackColor = SystemColors.Control; 295BackColor = SystemColors.Control;
System\Windows\Forms\Design\DocumentDesigner.cs (2)
141Control.BackColor = value; 680Control.BackColor = SystemColors.Control;
System\Windows\Forms\Design\MaskedTextBoxTextEditorDropDown.cs (1)
50BackColor = Drawing.SystemColors.Control;
System\Windows\Forms\Design\ShortcutKeysEditor.cs (1)
30BackColor = SystemColors.Control
System.Windows.Forms.Tests (87)
System\Windows\Forms\Control.ActiveXImplTests.cs (2)
20control.BackColor = Color.Bisque; 27control.BackColor = Color.Honeydew;
System\Windows\Forms\ControlTests.ControlCollection.cs (8)
654owner.BackColor = Color.Blue; 804owner.BackColor = Color.Blue; 957owner.BackColor = Color.Blue; 1030owner.BackColor = Color.Blue; 2357owner.BackColor = Color.Blue; 2501owner.BackColor = Color.Blue; 2633owner.BackColor = Color.Blue; 2697owner.BackColor = Color.Blue;
System\Windows\Forms\ControlTests.Handlers.cs (14)
180BackColor = Color.Yellow 184BackColor = Color.YellowGreen 2807child1.BackColor = backColor; 2809child2.BackColor = backColor; 2907child1.BackColor = backColor; 2909child2.BackColor = backColor; 2984child1.BackColor = Color.FromArgb(200, 50, 100, 150); 3276control.BackColor = Color.FromArgb(254, 255, 255, 255); 3707control.BackColor = Color.FromArgb(254, 255, 255, 255); 3860control.BackColor = backColor; 3986control.BackColor = backColor; 4032control.BackColor = backColor; 4117control.BackColor = backColor; 4227BackColor = Color.Red
System\Windows\Forms\ControlTests.Methods.cs (6)
4314otherControl.BackColor = Color.FromArgb(100, 50, 100, 150); 4598child1.BackColor = backColor; 4600child2.BackColor = backColor; 4698child1.BackColor = backColor; 4700child2.BackColor = backColor; 6386control.BackColor = Color.Black;
System\Windows\Forms\ControlTests.Properties.cs (37)
1231BackColor = value 1237control.BackColor = value; 1248BackColor = Color.YellowGreen 1251control.BackColor = value; 1256control.BackColor = value; 1275control.BackColor = value; 1280control.BackColor = value; 1295control.BackColor = value; 1302control.BackColor = value; 1315BackColor = Color.Yellow 1319BackColor = Color.YellowGreen 1325control.BackColor = value; 1332control.BackColor = value; 1358control.BackColor = value; 1366control.BackColor = value; 1388control.BackColor = Color.Red; 1393control.BackColor = Color.Red; 1398control.BackColor = Color.Empty; 1404control.BackColor = Color.Red; 1423control.BackColor = Color.Red; 1475control.BackColor = Color.Red; 1484control.BackColor = Color.Red; 1493control.BackColor = Color.Empty; 1505control.BackColor = Color.Red; 1519BackColor = Color.Yellow 1523BackColor = Color.YellowGreen 1555control.BackColor = Color.Red; 1564control.BackColor = Color.Red; 1573control.BackColor = Color.Empty; 1585control.BackColor = Color.Red; 1598Assert.Throws<ArgumentException>(() => control.BackColor = Color.FromArgb(254, 1, 2, 3)); 1608control.BackColor = Color.Red; 1624control.BackColor = Color.Red; 7061control.BackColor = Color.FromArgb(254, 255, 255, 255); 7546control.BackColor = Color.FromArgb(254, 255, 255, 255); 10957BackColor = Color.Green, 12493control.BackColor = Color.FromArgb(254, 255, 255, 255);
System\Windows\Forms\MdiClientTests.cs (8)
96BackColor = value 102control.BackColor = value; 121control.BackColor = Color.Red; 126control.BackColor = Color.Red; 131control.BackColor = Color.Empty; 137control.BackColor = Color.Red; 149control.BackColor = Color.Red; 165control.BackColor = Color.Red;
System\Windows\Forms\Printing\PrintPreviewControlTests.cs (2)
19control.BackColor = Color.Green; 36control.BackColor = Color.Green;
System\Windows\Forms\PropertyGridInternal\PropertyGridView.DropDownHolderTests.cs (1)
15propertyGridView.BackColor = Color.Green;
System\Windows\Forms\RichTextBoxTests.cs (2)
686control.BackColor = value; 694control.BackColor = value;
System\Windows\Forms\ScrollableControlTests.cs (4)
1540control.BackColor = backColor; 1689control.BackColor = backColor; 1739control.BackColor = backColor; 1833control.BackColor = backColor;
System\Windows\Forms\ToolStripContentPanelTests.cs (1)
636BackColor = Color.Blue
System\Windows\Forms\ToolStripControlHostTests.cs (2)
27BackColor = Color.Red, 546c.BackColor = Color.Red;
WindowsFormsIntegration (1)
System\Windows\Integration\WindowsFormsHostPropertyMap.cs (1)
86adapter.BackColor = wfColor;
WinFormsControlsTest (6)
Panels.Designer.cs (4)
50this.tableLayoutPanel1.BackColor = System.Drawing.Color.FromArgb((int)(byte)128, (int)(byte)255, (int)(byte)128); 57this.tableLayoutPanel2.BackColor = System.Drawing.Color.FromArgb((int)(byte)255, (int)(byte)255, (int)(byte)128); 65this.tableLayoutPanel3.BackColor = System.Drawing.Color.FromArgb((int)(byte)128, (int)(byte)255, (int)(byte)255); 84this.currentDPILabel1.BackColor = System.Drawing.Color.FromArgb((int)(byte)255, (int)(byte)128, (int)(byte)255);
Splitter.Designer.cs (2)
48this.splitContainer1.Panel1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128))))); 52this.splitContainer1.Panel2.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(128)))));
224 references to BackColor
DesignSurface (1)
MainForm.MyScrollableControl.cs (1)
35graphics.Clear(BackColor);
System.Windows.Forms (61)
System\Windows\Forms\ActiveX\AxHost.AxContainer.ExtenderProxy.cs (1)
131get => GetOleColorFromColor(GetControl()?.BackColor ?? default);
System\Windows\Forms\ActiveX\AxHost.cs (3)
256get => base.BackColor; 2105return GetOleColorFromColor(richParent.BackColor); 3329qaContainer.colorBack = GetOleColorFromColor(parent.BackColor);
System\Windows\Forms\Control.cs (15)
686if (ParentInternal is { } parent && parent.BackColor == BackColor) 694Color color = BackColor; 784c = parent.BackColor; 814Color previous = BackColor; 816if (!previous.Equals(BackColor)) 1614Color color = BackColor; 1630color = control.BackColor; 2775=> GetStyle(ControlStyles.SupportsTransparentBackColor) && BackColor.A < 255; 2960oldBackColor = BackColor; 2986if (checkBackColor && !oldBackColor.Equals(BackColor)) 4157Color oldBackColor = BackColor; 4196if (!oldBackColor.Equals(BackColor)) 5744PInvokeCore.SetBkColor(dc, (COLORREF)(uint)ColorTranslator.ToWin32(BackColor)); 8034PaintBackground(e, rectangle, BackColor, Point.Empty);
System\Windows\Forms\Controls\Buttons\ButtonBase.cs (1)
156get => base.BackColor;
System\Windows\Forms\Controls\ComboBox\ComboBox.cs (2)
258get => ShouldSerializeBackColor() ? base.BackColor : SystemColors.Window; 3454using var hbrush = new CreateBrushScope(ParentInternal?.BackColor ?? SystemColors.Control);
System\Windows\Forms\Controls\DataGridView\DataGridView.cs (1)
993get => base.BackColor;
System\Windows\Forms\Controls\DateTimePicker\DateTimePicker.cs (1)
130get => ShouldSerializeBackColor() ? base.BackColor : SystemColors.Window;
System\Windows\Forms\Controls\GroupBox\GroupBox.cs (2)
430Color textColor = Enabled ? ForeColor : TextRenderer.DisabledTextColor(BackColor); 664Color backColor = BackColor;
System\Windows\Forms\Controls\Labels\Label.cs (2)
991ControlPaint.DrawImageDisabled(g, image, loc.X, loc.Y, BackColor); 1306Color disabledTextForeColor = TextRenderer.DisabledTextColor(BackColor);
System\Windows\Forms\Controls\Labels\LinkLabel.cs (2)
1326ControlPaint.DrawFocusRectangle(g, Rectangle.Ceiling(focusRectangle), ForeColor, BackColor); 1332ControlPaint.DrawFocusRectangle(g, Rectangle.Ceiling(rect), ForeColor, BackColor);
System\Windows\Forms\Controls\ListBoxes\ListBox.cs (1)
159return base.BackColor;
System\Windows\Forms\Controls\ListView\ListView.cs (1)
348get => ShouldSerializeBackColor() ? base.BackColor : SystemColors.Window;
System\Windows\Forms\Controls\MonthCalendar\MonthCalendar.cs (1)
202return base.BackColor;
System\Windows\Forms\Controls\ProgressBar\ProgressBar.cs (3)
345PInvokeCore.SendMessage(this, PInvoke.PBM_SETBKCOLOR, 0, BackColor.ToWin32()); 604PInvokeCore.SendMessage(this, PInvoke.PBM_SETBKCOLOR, (WPARAM)0, (LPARAM)BackColor); 700PInvokeCore.SendMessage(this, PInvoke.PBM_SETBKCOLOR, 0, BackColor.ToWin32());
System\Windows\Forms\Controls\PropertyGrid\PropertyGrid.cs (5)
315get => base.BackColor; 427get => _commandsPane.BackColor; 630get => _helpPane.BackColor; 1974ControlPaint.DrawReversibleLine(new Point(rc.X + i, rc.Y), new Point(rc.X + i, rc.Y + rc.Height), targetControl.BackColor); 1981ControlPaint.DrawReversibleLine(new Point(rc.X, rc.Y + i), new Point(rc.X + rc.Width, rc.Y + i), targetControl.BackColor);
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\PropertyGridView.cs (1)
151get => base.BackColor;
System\Windows\Forms\Controls\TabControl\TabPage.cs (1)
102Color color = base.BackColor;
System\Windows\Forms\Controls\TextBox\TextBoxBase.cs (1)
288return base.BackColor;
System\Windows\Forms\Controls\ToolStrips\ToolStrip.cs (1)
368get => base.BackColor;
System\Windows\Forms\Controls\ToolStrips\ToolStripContainer.cs (1)
89get => base.BackColor;
System\Windows\Forms\Controls\ToolStrips\ToolStripContentPanel.cs (1)
94get => base.BackColor;
System\Windows\Forms\Controls\ToolStrips\ToolStripControlHost.cs (1)
58get => ControlInternal.BackColor;
System\Windows\Forms\Controls\ToolStrips\ToolStripItem.cs (1)
518return parent.BackColor;
System\Windows\Forms\Controls\TreeView\TreeView.cs (1)
198get => ShouldSerializeBackColor() ? base.BackColor : SystemColors.Window;
System\Windows\Forms\Controls\WebBrowser\WebBrowserBase.cs (1)
1244get => base.BackColor;
System\Windows\Forms\Layout\Containers\SplitContainer.cs (4)
1030using var brush = BackColor.GetCachedSolidBrushScope(); 1346if (BackColor == Color.Transparent) 1464ControlPaint.DrawFocusRectangle(g, r, ForeColor, BackColor); 1561using var solidBrush = BackColor.GetCachedSolidBrushScope();
System\Windows\Forms\MDI\MDIClient.cs (1)
318internal override bool ShouldSerializeBackColor() => BackColor != SystemColors.AppWorkspace;
System\Windows\Forms\Printing\PrintPreviewControl.cs (3)
295internal override bool ShouldSerializeBackColor() => !BackColor.Equals(SystemColors.AppWorkspace); 598brushColor = parent.BackColor; 746return (isHighContract && !ShouldSerializeBackColor()) ? SystemColors.ControlDarkDark : BackColor;
System\Windows\Forms\Scrolling\ScrollableControl.cs (1)
678BackColor,
System\Windows\Forms\Scrolling\ScrollBar.cs (1)
78get => base.BackColor;
System.Windows.Forms.Design (29)
System\Drawing\Design\ColorEditor.ColorPalette.cs (1)
360using var brush = BackColor.GetCachedSolidBrushScope();
System\Windows\Forms\Design\Behavior\DropSourceBehavior.cs (2)
937Color backColor = primaryParent is not null ? primaryParent.BackColor : Color.Empty; 1030using SolidBrush brush = new(primaryControl.BackColor);
System\Windows\Forms\Design\Behavior\ResizeBehavior.cs (1)
632Color backColor = targetControl.Parent is not null ? targetControl.Parent.BackColor : Color.Empty;
System\Windows\Forms\Design\ComponentTray.cs (1)
1210ControlPaint.DrawReversibleFrame(_mouseDragWorkspace, BackColor, FrameStyle.Dashed);
System\Windows\Forms\Design\DesignerUtils.cs (2)
396if (control.BackColor == Color.Transparent) 428if (control.BackColor == Color.Transparent)
System\Windows\Forms\Design\DocumentDesigner.cs (1)
131return Control.BackColor;
System\Windows\Forms\Design\FlowLayoutPanelDesigner .cs (1)
440var backColor = Control.BackColor;
System\Windows\Forms\Design\GroupBoxDesigner.cs (1)
82ControlPaint.DrawGrid(pe.Graphics, rectangle, GridSize, control.BackColor);
System\Windows\Forms\Design\OleDragDropHandler.cs (1)
345backColor = comp.BackColor;
System\Windows\Forms\Design\PanelDesigner.cs (3)
72Color penColor = Control.BackColor.GetBrightness() < .5 ? 73ControlPaint.Light(Control.BackColor) : 74ControlPaint.Dark(Control.BackColor);
System\Windows\Forms\Design\ParentControlDesigner.cs (2)
2005DesignerUtils.DrawFrame(_graphics, newRegion, _mouseDragFrame, Control.BackColor); 2042ControlPaint.DrawGrid(pe.Graphics, paintRect, GridSize, control.BackColor);
System\Windows\Forms\Design\PictureBoxDesigner.cs (3)
38if (ctl.BackColor.GetBrightness() < .5) 40penColor = ControlPaint.Light(ctl.BackColor); 44penColor = ControlPaint.Dark(ctl.BackColor);
System\Windows\Forms\Design\SelectionUIService.SelectionUIItem.cs (1)
142borderColor = parent.BackColor;
System\Windows\Forms\Design\SplitterDesigner.cs (1)
31Color penColor = control.BackColor.GetBrightness() < .5 ? Color.White : Color.Black;
System\Windows\Forms\Design\SplitterPanelDesigner.cs (4)
149Color penColor = control.BackColor.GetBrightness() < .5 ? ControlPaint.Light(control.BackColor) : ControlPaint.Dark(control.BackColor); 168using Pen pen = new(control.BackColor)
System\Windows\Forms\Design\TabOrder.cs (1)
215Color backColor = hoverParent.BackColor;
System\Windows\Forms\Design\ToolStripPanelDesigner.cs (3)
46Color penColor = Control.BackColor.GetBrightness() < .5 ? 47ControlPaint.Light(Control.BackColor) : 48ControlPaint.Dark(Control.BackColor);
System.Windows.Forms.Design.Tests (2)
System\ComponentModel\Design\ByteViewerTests.cs (1)
29Assert.Equal(Control.DefaultBackColor, control.BackColor);
System\Windows\Forms\Design\InheritedPropertyDescriptorTests.cs (1)
47InheritedPropertyDescriptor inheritedPropertyDescriptor = control.GetInheritedPropertyDescriptor(nameof(Control.BackColor));
System.Windows.Forms.Tests (127)
System\Windows\Forms\ContainerControlTests.cs (1)
35Assert.Equal(Control.DefaultBackColor, control.BackColor);
System\Windows\Forms\Control.ActiveXImplTests.cs (1)
32Assert.Equal(Color.Bisque, control.BackColor);
System\Windows\Forms\ControlTests.ControlCollection.cs (12)
575Assert.Equal(Control.DefaultBackColor, control.BackColor); 619Assert.Equal(Control.DefaultBackColor, control.BackColor); 655Assert.Equal(Control.DefaultBackColor, control.BackColor); 764Assert.Equal(Color.Blue, control.BackColor); 805Assert.Equal(Control.DefaultBackColor, control.BackColor); 923Assert.Equal(Color.Blue, control.BackColor); 2272Assert.Equal(Control.DefaultBackColor, control.BackColor); 2319Assert.Equal(Control.DefaultBackColor, control.BackColor); 2358Assert.Equal(Color.Blue, control.BackColor); 2463Assert.Equal(Control.DefaultBackColor, control.BackColor); 2502Assert.Equal(Color.Blue, control.BackColor); 2596Assert.Equal(Control.DefaultBackColor, control.BackColor);
System\Windows\Forms\ControlTests.cs (5)
24Assert.Equal(Control.DefaultBackColor, control.BackColor); 113Assert.Equal(Control.DefaultBackColor, control.BackColor); 209Assert.Equal(Control.DefaultBackColor, control.BackColor); 305Assert.Equal(Control.DefaultBackColor, control.BackColor); 401Assert.Equal(Control.DefaultBackColor, control.BackColor);
System\Windows\Forms\ControlTests.Methods.cs (3)
6383Assert.Equal(Control.DefaultBackColor, control.BackColor); 6388Assert.Equal(Control.DefaultBackColor, control.BackColor); 6392Assert.Equal(Control.DefaultBackColor, control.BackColor);
System\Windows\Forms\ControlTests.Properties.cs (64)
1233Assert.Equal(expected, control.BackColor); 1238Assert.Equal(expected, control.BackColor); 1252Assert.Equal(expected, control.BackColor); 1257Assert.Equal(expected, control.BackColor); 1276Assert.Equal(expected, control.BackColor); 1281Assert.Equal(expected, control.BackColor); 1296Assert.Equal(expected, control.BackColor); 1297Assert.Equal(expected, child1.BackColor); 1298Assert.Equal(expected, child2.BackColor); 1303Assert.Equal(expected, control.BackColor); 1304Assert.Equal(expected, child1.BackColor); 1305Assert.Equal(expected, child2.BackColor); 1326Assert.Equal(expected, control.BackColor); 1327Assert.Equal(Color.Yellow, child1.BackColor); 1328Assert.Equal(Color.YellowGreen, child2.BackColor); 1333Assert.Equal(expected, control.BackColor); 1334Assert.Equal(Color.Yellow, child1.BackColor); 1335Assert.Equal(Color.YellowGreen, child2.BackColor); 1359Assert.Equal(expected, control.BackColor); 1367Assert.Equal(expected, control.BackColor); 1389Assert.Equal(Color.Red, control.BackColor); 1394Assert.Equal(Color.Red, control.BackColor); 1399Assert.Equal(Control.DefaultBackColor, control.BackColor); 1405Assert.Equal(Color.Red, control.BackColor); 1424Assert.Equal(Color.Red, control.BackColor); 1476Assert.Equal(Color.Red, control.BackColor); 1477Assert.Equal(Color.Red, child1.BackColor); 1478Assert.Equal(Color.Red, child2.BackColor); 1485Assert.Equal(Color.Red, control.BackColor); 1486Assert.Equal(Color.Red, child1.BackColor); 1487Assert.Equal(Color.Red, child2.BackColor); 1494Assert.Equal(Control.DefaultBackColor, control.BackColor); 1495Assert.Equal(Control.DefaultBackColor, child1.BackColor); 1496Assert.Equal(Control.DefaultBackColor, child2.BackColor); 1506Assert.Equal(Color.Red, control.BackColor); 1507Assert.Equal(Color.Red, child1.BackColor); 1508Assert.Equal(Color.Red, child2.BackColor); 1556Assert.Equal(Color.Red, control.BackColor); 1557Assert.Equal(Color.Yellow, child1.BackColor); 1558Assert.Equal(Color.YellowGreen, child2.BackColor); 1565Assert.Equal(Color.Red, control.BackColor); 1566Assert.Equal(Color.Yellow, child1.BackColor); 1567Assert.Equal(Color.YellowGreen, child2.BackColor); 1574Assert.Equal(Control.DefaultBackColor, control.BackColor); 1575Assert.Equal(Color.Yellow, child1.BackColor); 1576Assert.Equal(Color.YellowGreen, child2.BackColor); 1586Assert.Equal(Color.Red, control.BackColor); 1587Assert.Equal(Color.Yellow, child1.BackColor); 1588Assert.Equal(Color.YellowGreen, child2.BackColor); 1604PropertyDescriptor property = TypeDescriptor.GetProperties(typeof(Control))[nameof(Control.BackColor)]; 1609Assert.Equal(Color.Red, control.BackColor); 1613Assert.Equal(Control.DefaultBackColor, control.BackColor); 1620PropertyDescriptor property = TypeDescriptor.GetProperties(typeof(Control))[nameof(Control.BackColor)]; 1625Assert.Equal(Color.Red, control.BackColor); 1629Assert.Equal(Control.DefaultBackColor, control.BackColor); 10811Assert.Equal(Color.Blue, control.BackColor); 10827Assert.Equal(Color.Blue, control.BackColor); 10843Assert.Equal(Color.Blue, control.BackColor); 10859Assert.Equal(Color.Red, control.BackColor); 10875Assert.Equal(Control.DefaultBackColor, control.BackColor); 10993Assert.Equal(Color.Green, control.BackColor); 11009Assert.Equal(Color.Green, control.BackColor); 11025Assert.Equal(Color.Green, control.BackColor); 11041Assert.Equal(Color.Green, control.BackColor);
System\Windows\Forms\DataGridViewTextBoxEditingControlTests.cs (1)
957Assert.Equal(expectedEditingPanelBackColor, dataGridView.EditingPanel.BackColor);
System\Windows\Forms\Design\ComponentEditorPageTests.cs (1)
30Assert.Equal(Control.DefaultBackColor, control.BackColor);
System\Windows\Forms\FlowLayoutPanelTests.cs (1)
29Assert.Equal(Control.DefaultBackColor, control.BackColor);
System\Windows\Forms\GroupBoxTests.cs (1)
27Assert.Equal(Control.DefaultBackColor, control.BackColor);
System\Windows\Forms\LabelTests.cs (1)
26Assert.Equal(Control.DefaultBackColor, control.BackColor);
System\Windows\Forms\ListControlTests.cs (1)
28Assert.Equal(Control.DefaultBackColor, control.BackColor);
System\Windows\Forms\MdiClientTests.cs (13)
26Assert.Equal(SystemColors.AppWorkspace, control.BackColor); 98Assert.Equal(expected, control.BackColor); 103Assert.Equal(expected, control.BackColor); 122Assert.Equal(Color.Red, control.BackColor); 127Assert.Equal(Color.Red, control.BackColor); 132Assert.Equal(Control.DefaultBackColor, control.BackColor); 138Assert.Equal(Color.Red, control.BackColor); 145PropertyDescriptor property = TypeDescriptor.GetProperties(typeof(MdiClient))[nameof(MdiClient.BackColor)]; 150Assert.Equal(Color.Red, control.BackColor); 154Assert.Equal(Control.DefaultBackColor, control.BackColor); 161PropertyDescriptor property = TypeDescriptor.GetProperties(typeof(MdiClient))[nameof(MdiClient.BackColor)]; 166Assert.Equal(Color.Red, control.BackColor); 170Assert.Equal(Control.DefaultBackColor, control.BackColor);
System\Windows\Forms\PanelTests.cs (1)
30Assert.Equal(Control.DefaultBackColor, control.BackColor);
System\Windows\Forms\PictureBoxTests.cs (1)
29Assert.Equal(Control.DefaultBackColor, control.BackColor);
System\Windows\Forms\ProgressBarTests.cs (1)
26Assert.Equal(Control.DefaultBackColor, control.BackColor);
System\Windows\Forms\RichTextBoxTests.cs (2)
687Assert.Equal(expected, control.BackColor); 695Assert.Equal(expected, control.BackColor);
System\Windows\Forms\ScrollableControlTests.cs (1)
30Assert.Equal(Control.DefaultBackColor, control.BackColor);
System\Windows\Forms\SplitterPanelTests.cs (1)
36Assert.Equal(Control.DefaultBackColor, control.BackColor);
System\Windows\Forms\SplitterTests.cs (1)
25Assert.Equal(Control.DefaultBackColor, control.BackColor);
System\Windows\Forms\StatusStripTests.cs (1)
1187Assert.Equal(Color.Transparent, grip.BackColor);
System\Windows\Forms\TableLayoutPanelTests.cs (1)
31Assert.Equal(Control.DefaultBackColor, control.BackColor);
System\Windows\Forms\ToolStripContentPanelTests.cs (2)
644Assert.Equal(Color.Blue, parent.BackColor); 650Assert.Equal(Color.Blue, parent.BackColor);
System\Windows\Forms\ToolStripControlHostTests.cs (7)
60Assert.Equal(c.BackColor, item.BackColor); 272Assert.Equal(expected, c.BackColor); 278Assert.Equal(expected, c.BackColor); 547Assert.Equal(Color.Red, c.BackColor); 4394Assert.Equal(Control.DefaultBackColor, c.BackColor); 4400Assert.Equal(Control.DefaultBackColor, c.BackColor); 4405Assert.Equal(Control.DefaultBackColor, c.BackColor);
System\Windows\Forms\ToolStripPanelTests.cs (1)
31Assert.Equal(Control.DefaultBackColor, control.BackColor);
System\Windows\Forms\UserControlTests.cs (1)
35Assert.Equal(Control.DefaultBackColor, control.BackColor);
TrackBarTests.cs (1)
27Assert.Equal(Control.DefaultBackColor, control.BackColor);
WindowsFormsIntegration (4)
System\Windows\Integration\ElementHost.cs (4)
927OnPropertyChanged("BackColor", this.BackColor); 1551if (control.BackColor != SD.Color.Empty && control.BackColor.A == 255) 1553return control.BackColor;