Implemented interface member:
75 references to Equals
System.Drawing.Common.Tests (1)
Helpers.cs (1)
122
if (!pixel.
Equals
(emptyColor))
System.Drawing.Primitives (1)
System\Drawing\Color.cs (1)
585
public override bool Equals([NotNullWhen(true)] object? obj) => obj is Color other &&
Equals
(other);
System.Windows.Forms (63)
System\Windows\Forms\Control.cs (7)
809
if (!value.
Equals
(Color.Empty) && !GetStyle(ControlStyles.SupportsTransparentBackColor) && value.A < 255)
816
if (!previous.
Equals
(BackColor))
2032
if (!previous.
Equals
(ForeColor))
2981
if (checkForeColor && !oldForeColor.
Equals
(ForeColor))
2986
if (checkBackColor && !oldBackColor.
Equals
(BackColor))
4191
if (!oldForeColor.
Equals
(ForeColor))
4196
if (!oldBackColor.
Equals
(BackColor))
System\Windows\Forms\Controls\Buttons\ButtonInternal\CheckBoxBaseAdapter.cs (1)
297
&& cacheCheckColor.
Equals
(checkColor)
System\Windows\Forms\Controls\Buttons\FlatButtonAppearance.cs (1)
72
if (value.
Equals
(Color.Transparent))
System\Windows\Forms\Controls\DataGridView\DataGridView.cs (4)
1020
if (!value.
Equals
(_backgroundColor))
1068
private bool ShouldSerializeBackgroundColor() => !BackgroundColor.
Equals
(s_defaultBackgroundColor);
2645
if (!value.
Equals
(GridPenColor))
2661
private bool ShouldSerializeGridColor() => !GridPenColor.
Equals
(DefaultGridColor);
System\Windows\Forms\Controls\DataGridView\DataGridViewCellStyle.cs (4)
113
if (!previous.
Equals
(value))
164
if (!previous.
Equals
(value))
313
if (!previous.
Equals
(value))
327
if (!previous.
Equals
(value))
System\Windows\Forms\Controls\DataGridView\DataGridViewLinkCell.cs (12)
63
if (!value.
Equals
(ActiveLinkColor))
85
if (!value.
Equals
(ActiveLinkColor))
96
return !ActiveLinkColor.
Equals
(SystemColors.HotTrack);
99
return !ActiveLinkColor.
Equals
(LinkUtilities.IEActiveLinkColor);
171
if (!value.
Equals
(LinkColor))
193
if (!value.
Equals
(LinkColor))
201
? !LinkColor.
Equals
(SystemColors.HotTrack)
202
: !LinkColor.
Equals
(LinkUtilities.IELinkColor);
308
if (value.
Equals
(VisitedLinkColor))
332
if (!value.
Equals
(VisitedLinkColor))
343
return !VisitedLinkColor.
Equals
(SystemColors.HotTrack);
346
return !VisitedLinkColor.
Equals
(LinkUtilities.IEVisitedLinkColor);
System\Windows\Forms\Controls\DataGridView\DataGridViewLinkColumn.cs (9)
40
if (ActiveLinkColor.
Equals
(value))
70
return !ActiveLinkColor.
Equals
(SystemColors.HotTrack);
73
return !ActiveLinkColor.
Equals
(LinkUtilities.IEActiveLinkColor);
151
if (LinkColor.
Equals
(value))
181
return !LinkColor.
Equals
(SystemColors.HotTrack);
184
return !LinkColor.
Equals
(LinkUtilities.IELinkColor);
331
if (VisitedLinkColor.
Equals
(value))
361
return !VisitedLinkColor.
Equals
(SystemColors.HotTrack);
364
return !VisitedLinkColor.
Equals
(LinkUtilities.IEVisitedLinkColor);
System\Windows\Forms\Controls\DateTimePicker\DateTimePicker.cs (10)
189
if (!value.
Equals
(_calendarForeColor))
249
if (!value.
Equals
(_calendarTitleBackColor))
272
if (!value.
Equals
(_calendarTitleForeColor))
295
if (!value.
Equals
(_calendarTrailingText))
318
if (!value.
Equals
(_calendarMonthBackground))
1357
return !CalendarForeColor.
Equals
(DefaultForeColor);
1373
return !_calendarTitleBackColor.
Equals
(DefaultTitleBackColor);
1381
return !_calendarTitleForeColor.
Equals
(DefaultTitleForeColor);
1389
return !_calendarTrailingText.
Equals
(DefaultTrailingForeColor);
1397
return !_calendarMonthBackground.
Equals
(DefaultMonthBackColor);
System\Windows\Forms\Controls\ImageList\ImageList.cs (1)
749
private bool ShouldSerializeTransparentColor() => !TransparentColor.
Equals
(Color.LightGray);
System\Windows\Forms\Controls\ImageList\ImageList.Original.cs (1)
42
Debug.Assert(customTransparentColor.
Equals
(Color.Transparent), "Specified a custom transparent color then told us to ignore it");
System\Windows\Forms\Controls\MonthCalendar\MonthCalendar.cs (3)
1907
=> !TrailingForeColor.
Equals
(s_trailingForeColor);
1910
=> !TitleForeColor.
Equals
(s_defaultTitleForeColor);
1913
=> !TitleBackColor.
Equals
(s_defaultTitleBackColor);
System\Windows\Forms\Controls\ToolStrips\ToolStripItem.cs (2)
527
if (!previous.
Equals
(BackColor))
881
if (!previous.
Equals
(ForeColor))
System\Windows\Forms\Controls\TreeView\TreeNode.cs (2)
215
if (!value.
Equals
(oldbk))
441
if (!value.
Equals
(oldfc))
System\Windows\Forms\Dialogs\CommonDialogs\ColorDialog.cs (1)
210
private bool ShouldSerializeColor() => !Color.
Equals
(Color.Black);
System\Windows\Forms\Form.cs (1)
5894
return !TransparencyKey.
Equals
(Color.Empty);
System\Windows\Forms\Printing\PrintPreviewControl.cs (2)
295
internal override bool ShouldSerializeBackColor() => !BackColor.
Equals
(SystemColors.AppWorkspace);
300
internal override bool ShouldSerializeForeColor() => !ForeColor.
Equals
(Color.White);
System\Windows\Forms\Rendering\ControlPaint.cs (2)
2084
if (t_frameBrushActive is null || !s_frameColorActive.
Equals
(brushColor))
2214
if (t_frameBrushSelected is null || !s_frameColorSelected.
Equals
(brushColor))
System.Windows.Forms.Design (10)
System\Drawing\Design\ColorEditor.ColorPalette.cs (4)
95
if (!value.
Equals
(_selectedColor))
135
if (GetColorFromCell(x, y).
Equals
(c))
205
if (SelectedColor.
Equals
(GetColorFromCell(x, y)))
381
if (color.
Equals
(SelectedColor) && !drawSelected)
System\Windows\Forms\Design\DataGridViewColumnCollectionDialog.cs (4)
375
if (defaultSrcColumn is null || !defaultSrcColumn.DefaultCellStyle.BackColor.
Equals
(srcColumn.DefaultCellStyle.BackColor))
385
if (defaultSrcColumn is null || !defaultSrcColumn.DefaultCellStyle.ForeColor.
Equals
(srcColumn.DefaultCellStyle.ForeColor))
400
if (defaultSrcColumn is null || !defaultSrcColumn.DefaultCellStyle.SelectionBackColor.
Equals
(srcColumn.DefaultCellStyle.SelectionBackColor))
405
if (defaultSrcColumn is null || !defaultSrcColumn.DefaultCellStyle.SelectionForeColor.
Equals
(srcColumn.DefaultCellStyle.SelectionForeColor))
System\Windows\Forms\Design\DesignerUtils.cs (1)
452
return !image.GetPixel(image.Width / 2, image.Height / 2).
Equals
(testColor);
System\Windows\Forms\Design\ImageListDesigner.cs (1)
81
private bool ShouldSerializeTransparentColor() => !TransparentColor.
Equals
(Color.LightGray);