1 override of ForeColor
System.Windows.Forms (1)
System\Windows\Forms\Controls\ToolStrips\ToolStripControlHost.cs (1)
213public override Color ForeColor
38 writes to ForeColor
System.Windows.Forms (4)
System\Windows\Forms\Controls\ToolStrips\ToolStripItem.cs (1)
3377public virtual void ResetForeColor() => ForeColor = Color.Empty;
System\Windows\Forms\Controls\ToolStrips\ToolStripMenuItem.cs (1)
507menuItem.ForeColor = ForeColor;
System\Windows\Forms\Controls\ToolStrips\ToolStripSeparator.cs (1)
18ForeColor = SystemColors.ControlDark;
System\Windows\Forms\Controls\ToolStrips\ToolStripSplitButton.cs (1)
231_splitButtonButton.ForeColor = ForeColor;
System.Windows.Forms.Design (4)
System\Windows\Forms\Design\ToolStripTemplateNode.cs (4)
1911item.ForeColor = _defaultBorderColor; 1941item.ForeColor = _defaultBorderColor; 1950item.ForeColor = _defaultBorderColor; 1958item.ForeColor = _defaultBorderColor;
System.Windows.Forms.Tests (30)
System\Windows\Forms\ToolStripButtonTests.cs (3)
1278ForeColor = Color.Red, 1369ForeColor = Color.Red, 1468ForeColor = Color.Red,
System\Windows\Forms\ToolStripItemTests.cs (18)
3267ForeColor = value 3272item.ForeColor = value; 3286item.ForeColor = value; 3291item.ForeColor = value; 3313item.ForeColor = value; 3321item.ForeColor = value; 3339item.ForeColor = value; 3344item.ForeColor = value; 3375item.ForeColor = value; 3383item.ForeColor = value; 3405item.ForeColor = Color.Red; 3410item.ForeColor = Color.Red; 3415item.ForeColor = Color.Empty; 3421item.ForeColor = Color.Red; 3433item.ForeColor = Color.Red; 3449item.ForeColor = Color.Red; 12600item.ForeColor = Color.Red; 14149item.ForeColor = Color.Black;
System\Windows\Forms\ToolStripMenuItemTests.cs (1)
287ForeColor = Color.Blue,
System\Windows\Forms\ToolStripSeparatorTests.cs (8)
339ForeColor = value 344item.ForeColor = value; 362item.ForeColor = Color.Red; 367item.ForeColor = Color.Red; 372item.ForeColor = Color.Empty; 378item.ForeColor = Color.Red; 390item.ForeColor = Color.Red; 406item.ForeColor = Color.Red;
66 references to ForeColor
System.Windows.Forms (12)
System\Windows\Forms\Controls\ToolStrips\ToolStripButton.cs (1)
221renderer.DrawItemText(new ToolStripItemTextRenderEventArgs(e.Graphics, this, Text, InternalLayout.TextRectangle, ForeColor, Font, InternalLayout.TextFormat));
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDownButton.cs (1)
193renderer.DrawItemText(new ToolStripItemTextRenderEventArgs(g, this, Text, InternalLayout.TextRectangle, ForeColor, Font, InternalLayout.TextFormat));
System\Windows\Forms\Controls\ToolStrips\ToolStripItem.cs (2)
879Color previous = ForeColor; 881if (!previous.Equals(ForeColor))
System\Windows\Forms\Controls\ToolStrips\ToolStripLabel.cs (1)
356Color textColor = ForeColor;
System\Windows\Forms\Controls\ToolStrips\ToolStripMenuItem.cs (2)
507menuItem.ForeColor = ForeColor; 958textColor = ForeColor;
System\Windows\Forms\Controls\ToolStrips\ToolstripProfessionalRenderer.cs (1)
717e.DefaultTextColor = e.Item.ForeColor;
System\Windows\Forms\Controls\ToolStrips\ToolStripSeparator.cs (1)
304internal override bool ShouldSerializeForeColor() => ForeColor != SystemColors.ControlDark;
System\Windows\Forms\Controls\ToolStrips\ToolStripSplitButton.cs (2)
231_splitButtonButton.ForeColor = ForeColor; 528renderer.DrawItemText(new ToolStripItemTextRenderEventArgs(g, this, SplitButtonButton.Text, SplitButtonButtonLayout.TextRectangle, ForeColor, Font, SplitButtonButtonLayout.TextFormat));
System\Windows\Forms\Controls\ToolStrips\ToolStripSystemRenderer.cs (1)
704using var foreColorPen = item.ForeColor.GetCachedPenScope();
System.Windows.Forms.Tests (54)
System\Windows\Forms\ToolStripButtonTests.cs (6)
57Assert.Equal(Control.DefaultForeColor, item.ForeColor); 138Assert.Equal(Control.DefaultForeColor, item.ForeColor); 225Assert.Equal(Control.DefaultForeColor, item.ForeColor); 315Assert.Equal(Control.DefaultForeColor, item.ForeColor); 403Assert.Equal(Control.DefaultForeColor, item.ForeColor); 501Assert.Equal(Control.DefaultForeColor, item.ForeColor);
System\Windows\Forms\ToolStripDropDownItemTests.cs (4)
55Assert.Equal(Control.DefaultForeColor, item.ForeColor); 144Assert.Equal(Control.DefaultForeColor, item.ForeColor); 243Assert.Equal(Control.DefaultForeColor, item.ForeColor); 351Assert.Equal(Control.DefaultForeColor, item.ForeColor);
System\Windows\Forms\ToolStripItemTests.cs (28)
56Assert.Equal(Control.DefaultForeColor, item.ForeColor); 141Assert.Equal(Control.DefaultForeColor, item.ForeColor); 236Assert.Equal(Control.DefaultForeColor, item.ForeColor); 3244Assert.Equal(Control.DefaultForeColor, item.ForeColor); 3258Assert.Equal(Color.Red, item.ForeColor); 3269Assert.Equal(expected, item.ForeColor); 3273Assert.Equal(expected, item.ForeColor); 3287Assert.Equal(expected, item.ForeColor); 3292Assert.Equal(expected, item.ForeColor); 3314Assert.Equal(expected, item.ForeColor); 3322Assert.Equal(expected, item.ForeColor); 3340Assert.Equal(expected, item.ForeColor); 3345Assert.Equal(expected, item.ForeColor); 3376Assert.Equal(expected, item.ForeColor); 3384Assert.Equal(expected, item.ForeColor); 3406Assert.Equal(Color.Red, item.ForeColor); 3411Assert.Equal(Color.Red, item.ForeColor); 3416Assert.Equal(Control.DefaultForeColor, item.ForeColor); 3422Assert.Equal(Color.Red, item.ForeColor); 3429PropertyDescriptor property = TypeDescriptor.GetProperties(typeof(ToolStripItem))[nameof(ToolStripItem.ForeColor)]; 3434Assert.Equal(Color.Red, item.ForeColor); 3438Assert.Equal(Control.DefaultForeColor, item.ForeColor); 3445PropertyDescriptor property = TypeDescriptor.GetProperties(typeof(ToolStripItem))[nameof(ToolStripItem.ForeColor)]; 3450Assert.Equal(Color.Red, item.ForeColor); 3454Assert.Equal(Control.DefaultForeColor, item.ForeColor); 14146Assert.Equal(Control.DefaultForeColor, item.ForeColor); 14151Assert.Equal(Control.DefaultForeColor, item.ForeColor); 14155Assert.Equal(Control.DefaultForeColor, item.ForeColor);
System\Windows\Forms\ToolStripMenuItemTests.cs (3)
59Assert.Equal(Control.DefaultForeColor, item.ForeColor); 332clone.ForeColor.Should().Be(original.ForeColor);
System\Windows\Forms\ToolStripSeparatorTests.cs (13)
54Assert.Equal(SystemColors.ControlDark, item.ForeColor); 341Assert.Equal(expected, item.ForeColor); 345Assert.Equal(expected, item.ForeColor); 363Assert.Equal(Color.Red, item.ForeColor); 368Assert.Equal(Color.Red, item.ForeColor); 373Assert.Equal(Control.DefaultForeColor, item.ForeColor); 379Assert.Equal(Color.Red, item.ForeColor); 386PropertyDescriptor property = TypeDescriptor.GetProperties(typeof(ToolStripSeparator))[nameof(ToolStripSeparator.ForeColor)]; 391Assert.Equal(Color.Red, item.ForeColor); 395Assert.Equal(Control.DefaultForeColor, item.ForeColor); 402PropertyDescriptor property = TypeDescriptor.GetProperties(typeof(ToolStripSeparator))[nameof(ToolStripSeparator.ForeColor)]; 407Assert.Equal(Color.Red, item.ForeColor); 411Assert.Equal(Control.DefaultForeColor, item.ForeColor);