36 writes to ForeColor
System.Windows.Forms (35)
System\Windows\Forms\Controls\DataGridView\DataGridView.cs (4)
1553ForeColor = DefaultForeBrush.Color, 2002defaultCellStyleTmp.ForeColor = SystemInformation.HighContrast ? DefaultForeBrush.Color : base.ForeColor; 2066ForeColor = SystemInformation.HighContrast ? DefaultForeBrush.Color : base.ForeColor, 2103ForeColor = DefaultForeBrush.Color,
System\Windows\Forms\Controls\DataGridView\DataGridView.Methods.cs (7)
44DefaultCellStyle.ForeColor = onSurface; 48ColumnHeadersDefaultCellStyle.ForeColor = headerFg; 55RowHeadersDefaultCellStyle.ForeColor = headerFg; 2864inheritedCellStyle.ForeColor = cellStyle.ForeColor; 2868inheritedCellStyle.ForeColor = columnHeadersStyle.ForeColor; 2872inheritedCellStyle.ForeColor = dataGridViewStyle.ForeColor; 15180DefaultCellStyle.ForeColor = base.ForeColor;
System\Windows\Forms\Controls\DataGridView\DataGridViewCell.cs (7)
1895inheritedCellStyleTmp.ForeColor = Color.Empty; 1959inheritedCellStyleTmp.ForeColor = cellStyle.ForeColor; 1963inheritedCellStyleTmp.ForeColor = rowStyle.ForeColor; 1968inheritedCellStyleTmp.ForeColor = DataGridView.RowsDefaultCellStyle.ForeColor; 1972inheritedCellStyleTmp.ForeColor = DataGridView.AlternatingRowsDefaultCellStyle.ForeColor; 1976inheritedCellStyleTmp.ForeColor = columnStyle.ForeColor; 1980inheritedCellStyleTmp.ForeColor = dataGridViewStyle.ForeColor;
System\Windows\Forms\Controls\DataGridView\DataGridViewCellStyle.cs (2)
47ForeColor = dataGridViewCellStyle.ForeColor; 406ForeColor = dataGridViewCellStyle.ForeColor;
System\Windows\Forms\Controls\DataGridView\DataGridViewColumn.cs (2)
458inheritedCellStyleTmp.ForeColor = columnStyle.ForeColor; 462inheritedCellStyleTmp.ForeColor = dataGridViewStyle.ForeColor;
System\Windows\Forms\Controls\DataGridView\DataGridViewColumnHeaderCell.cs (3)
316inheritedCellStyleTmp.ForeColor = cellStyle.ForeColor; 320inheritedCellStyleTmp.ForeColor = columnHeadersStyle.ForeColor; 324inheritedCellStyleTmp.ForeColor = dataGridViewStyle.ForeColor;
System\Windows\Forms\Controls\DataGridView\DataGridViewRow.cs (7)
630inheritedCellStyle.ForeColor = cellStyle.ForeColor; 634inheritedCellStyle.ForeColor = rowHeadersStyle.ForeColor; 638inheritedCellStyle.ForeColor = dataGridViewStyle.ForeColor; 832inheritedRowStyle.ForeColor = rowStyle.ForeColor; 836inheritedRowStyle.ForeColor = rowsDefaultCellStyle.ForeColor; 840inheritedRowStyle.ForeColor = alternatingRowsDefaultCellStyle.ForeColor; 844inheritedRowStyle.ForeColor = dataGridViewStyle.ForeColor;
System\Windows\Forms\Controls\DataGridView\DataGridViewRowHeaderCell.cs (3)
341inheritedCellStyleTmp.ForeColor = cellStyle.ForeColor; 345inheritedCellStyleTmp.ForeColor = rowHeadersStyle.ForeColor; 349inheritedCellStyleTmp.ForeColor = dataGridViewStyle.ForeColor;
System.Windows.Forms.Design (1)
System\Windows\Forms\Design\DataGridViewColumnCollectionDialog.cs (1)
385destColumn.DefaultCellStyle.ForeColor = srcColumn.DefaultCellStyle.ForeColor;
87 references to ForeColor
System.Windows.Forms (84)
System\Windows\Forms\Controls\DataGridView\DataGridView.cs (2)
1984|| _defaultCellStyle.ForeColor == Color.Empty 2000if (_defaultCellStyle.ForeColor == Color.Empty)
System\Windows\Forms\Controls\DataGridView\DataGridView.Methods.cs (6)
2862if (cellStyle is not null && !cellStyle.ForeColor.IsEmpty) 2864inheritedCellStyle.ForeColor = cellStyle.ForeColor; 2866else if (!columnHeadersStyle.ForeColor.IsEmpty) 2868inheritedCellStyle.ForeColor = columnHeadersStyle.ForeColor; 2872inheritedCellStyle.ForeColor = dataGridViewStyle.ForeColor; 15178if (_dataGridViewState1[State1_AmbientForeColor] && DefaultCellStyle.ForeColor != base.ForeColor)
System\Windows\Forms\Controls\DataGridView\DataGridViewButtonCell.cs (8)
668Color foreBrushColor = cellSelected ? cellStyle.SelectionForeColor : cellStyle.ForeColor; 772cellStyle.ForeColor, 804cellStyle.ForeColor, 825cellStyle.ForeColor, 840cellStyle.ForeColor, 887ControlPaint.DrawFocusRectangle(g, Rectangle.Inflate(valBounds, -1, -1), Color.Empty, cellStyle.ForeColor); 896cellStyle.ForeColor, 951cellStyle.ForeColor);
System\Windows\Forms\Controls\DataGridView\DataGridViewButtonColumn.cs (1)
215!defaultCellStyle.ForeColor.IsEmpty ||
System\Windows\Forms\Controls\DataGridView\DataGridViewCell.cs (12)
1957if (cellStyle is not null && !cellStyle.ForeColor.IsEmpty) 1959inheritedCellStyleTmp.ForeColor = cellStyle.ForeColor; 1961else if (rowStyle is not null && !rowStyle.ForeColor.IsEmpty) 1963inheritedCellStyleTmp.ForeColor = rowStyle.ForeColor; 1965else if (!DataGridView.RowsDefaultCellStyle.ForeColor.IsEmpty && 1966(rowIndex % 2 == 0 || DataGridView.AlternatingRowsDefaultCellStyle.ForeColor.IsEmpty)) 1968inheritedCellStyleTmp.ForeColor = DataGridView.RowsDefaultCellStyle.ForeColor; 1970else if (rowIndex % 2 == 1 && !DataGridView.AlternatingRowsDefaultCellStyle.ForeColor.IsEmpty) 1972inheritedCellStyleTmp.ForeColor = DataGridView.AlternatingRowsDefaultCellStyle.ForeColor; 1974else if (columnStyle is not null && !columnStyle.ForeColor.IsEmpty) 1976inheritedCellStyleTmp.ForeColor = columnStyle.ForeColor; 1980inheritedCellStyleTmp.ForeColor = dataGridViewStyle.ForeColor;
System\Windows\Forms\Controls\DataGridView\DataGridViewCellStyle.cs (8)
47ForeColor = dataGridViewCellStyle.ForeColor; 404if (!dataGridViewCellStyle.ForeColor.IsEmpty) 406ForeColor = dataGridViewCellStyle.ForeColor; 492dgvcs.ForeColor != ForeColor || 519hash.Add(ForeColor); 574if (ForeColor != Color.Empty) 581sb.Append($" ForeColor={ForeColor}");
System\Windows\Forms\Controls\DataGridView\DataGridViewCheckBoxCell.cs (5)
1151ControlPaint.DrawFocusRectangle(g, valBounds, cellStyle.BackColor, cellStyle.ForeColor); 1295foreBrushColor = cellSelected ? cellStyle.SelectionForeColor : cellStyle.ForeColor; 1417cellStyle.ForeColor, 1466cellStyle.ForeColor, 1513cellStyle.ForeColor,
System\Windows\Forms\Controls\DataGridView\DataGridViewCheckBoxColumn.cs (1)
301!defaultCellStyle.ForeColor.IsEmpty ||
System\Windows\Forms\Controls\DataGridView\DataGridViewColumn.cs (4)
216!defaultCellStyle.ForeColor.IsEmpty || 456if (columnStyle is not null && !columnStyle.ForeColor.IsEmpty) 458inheritedCellStyleTmp.ForeColor = columnStyle.ForeColor; 462inheritedCellStyleTmp.ForeColor = dataGridViewStyle.ForeColor;
System\Windows\Forms\Controls\DataGridView\DataGridViewColumnHeaderCell.cs (6)
314if (cellStyle is not null && !cellStyle.ForeColor.IsEmpty) 316inheritedCellStyleTmp.ForeColor = cellStyle.ForeColor; 318else if (!columnHeadersStyle.ForeColor.IsEmpty) 320inheritedCellStyleTmp.ForeColor = columnHeadersStyle.ForeColor; 324inheritedCellStyleTmp.ForeColor = dataGridViewStyle.ForeColor; 915textColor = cellSelected ? cellStyle.SelectionForeColor : cellStyle.ForeColor;
System\Windows\Forms\Controls\DataGridView\DataGridViewComboBoxCell.cs (4)
2263ControlPaint.DrawFocusRectangle(g, focusBounds, Color.Empty, cellStyle.ForeColor); 2274ControlPaint.DrawFocusRectangle(g, focusBounds, Color.Empty, cellStyle.ForeColor); 2279ControlPaint.DrawFocusRectangle(g, textBounds, Color.Empty, cellStyle.ForeColor); 2329textColor = cellSelected ? cellStyle.SelectionForeColor : cellStyle.ForeColor;
System\Windows\Forms\Controls\DataGridView\DataGridViewComboBoxEditingControl.cs (1)
86ForeColor = dataGridViewCellStyle.ForeColor;
System\Windows\Forms\Controls\DataGridView\DataGridViewImageColumn.cs (1)
277!defaultCellStyle.ForeColor.IsEmpty ||
System\Windows\Forms\Controls\DataGridView\DataGridViewRow.cs (13)
628if (cellStyle is not null && !cellStyle.ForeColor.IsEmpty) 630inheritedCellStyle.ForeColor = cellStyle.ForeColor; 632else if (!rowHeadersStyle.ForeColor.IsEmpty) 634inheritedCellStyle.ForeColor = rowHeadersStyle.ForeColor; 638inheritedCellStyle.ForeColor = dataGridViewStyle.ForeColor; 830if (rowStyle is not null && !rowStyle.ForeColor.IsEmpty) 832inheritedRowStyle.ForeColor = rowStyle.ForeColor; 834else if (!rowsDefaultCellStyle.ForeColor.IsEmpty && (rowIndex % 2 == 0 || alternatingRowsDefaultCellStyle.ForeColor.IsEmpty)) 836inheritedRowStyle.ForeColor = rowsDefaultCellStyle.ForeColor; 838else if (rowIndex % 2 == 1 && !alternatingRowsDefaultCellStyle.ForeColor.IsEmpty) 840inheritedRowStyle.ForeColor = alternatingRowsDefaultCellStyle.ForeColor; 844inheritedRowStyle.ForeColor = dataGridViewStyle.ForeColor;
System\Windows\Forms\Controls\DataGridView\DataGridViewRowHeaderCell.cs (8)
339if (cellStyle is not null && !cellStyle.ForeColor.IsEmpty) 341inheritedCellStyleTmp.ForeColor = cellStyle.ForeColor; 343else if (!rowHeadersStyle.ForeColor.IsEmpty) 345inheritedCellStyleTmp.ForeColor = rowHeadersStyle.ForeColor; 349inheritedCellStyleTmp.ForeColor = dataGridViewStyle.ForeColor; 824iconColor = cellSelected ? cellStyle.SelectionForeColor : cellStyle.ForeColor; 884textColor = cellSelected ? cellStyle.SelectionForeColor : cellStyle.ForeColor; 982iconColor = cellSelected ? cellStyle.SelectionForeColor : cellStyle.ForeColor;
System\Windows\Forms\Controls\DataGridView\DataGridViewTextBoxCell.cs (2)
713ControlPaint.DrawFocusRectangle(graphics, valBounds, Color.Empty, cellStyle.ForeColor); 749cellSelected ? cellStyle.SelectionForeColor : cellStyle.ForeColor,
System\Windows\Forms\Controls\DataGridView\DataGridViewTextBoxEditingControl.cs (1)
112ForeColor = dataGridViewCellStyle.ForeColor;
System\Windows\Forms\Controls\DataGridView\DataGridViewTopLeftHeaderCell.cs (1)
315textColor = cellSelected ? cellStyle.SelectionForeColor : cellStyle.ForeColor;
System.Windows.Forms.Design (3)
System\Windows\Forms\Design\DataGridViewColumnCollectionDialog.cs (3)
383if (defaultSrcColumn is null || !defaultSrcColumn.DefaultCellStyle.ForeColor.Equals(srcColumn.DefaultCellStyle.ForeColor)) 385destColumn.DefaultCellStyle.ForeColor = srcColumn.DefaultCellStyle.ForeColor;