29 references to Graphics
PresentationUI (1)
MS\Internal\Documents\SignatureSummaryDialog.cs (1)
595
DrawListBoxSummaryItem(e.
Graphics
,
System.Windows.Forms (9)
System\Windows\Forms\Controls\ListBoxes\CheckedListBox.cs (5)
565
ControlPaint.DrawCheckBox(e.
Graphics
, box, state);
682
e.
Graphics
.DrawString(text, font, brush, stringBounds, format);
710
ControlPaint.DrawBlackWhiteFocusRectangle(e.
Graphics
, textBounds, backColor);
734
ControlPaint.DrawFocusRectangle(e.
Graphics
, emptyRectangle, foreColor, backColor);
741
e.
Graphics
.FillRectangle(brush, emptyRectangle);
System\Windows\Forms\Rendering\DrawItemEventArgs.cs (4)
12
/// <see cref="
Graphics
"/> object with which the drawing should be done.
151
/// For internal use to improve performance. DO NOT use this method if you modify the <see cref="
Graphics
"/>
161
IntPtr IDeviceContext.GetHdc() =>
Graphics
?.GetHdc() ?? IntPtr.Zero;
163
void IDeviceContext.ReleaseHdc() =>
Graphics
?.ReleaseHdc();
System.Windows.Forms.Design (14)
System\ComponentModel\Design\CollectionEditor.CollectionEditorCollectionForm.cs (1)
559
Graphics g = e.
Graphics
;
System\Drawing\Design\ColorEditor.ColorUI.cs (1)
272
Graphics graphics = die.
Graphics
;
System\Drawing\Design\CursorEditor.CursorUI.cs (4)
69
e.
Graphics
.FillRectangle(SystemBrushes.Control, new Rectangle(e.Bounds.X + 2, e.Bounds.Y + 2, 32, e.Bounds.Height - 4));
70
e.
Graphics
.DrawRectangle(SystemPens.WindowText, new Rectangle(e.Bounds.X + 2, e.Bounds.Y + 2, 32 - 1, e.Bounds.Height - 4 - 1));
72
cursor.DrawStretched(e.
Graphics
, new Rectangle(e.Bounds.X + 2, e.Bounds.Y + 2, 32, e.Bounds.Height - 4));
73
e.
Graphics
.DrawString(text, font, brushText, e.Bounds.X + 36, e.Bounds.Y + (e.Bounds.Height - font.Height) / 2);
System\Windows\Forms\Design\DataGridViewColumnCollectionDialog.cs (8)
983
e.
Graphics
.DrawImage(listBoxItem!.ToolboxBitmap!,
1004
int textWidth = Size.Ceiling(e.
Graphics
.MeasureString(columnName, e.Font!, new SizeF(bounds.Width, bounds.Height))).Width;
1008
e.
Graphics
.FillRectangle(selectedBrush, focusRectangle);
1011
e.
Graphics
.DrawString(columnName, e.Font!, foreBrush, focusRectangle);
1018
ControlPaint.DrawFocusRectangle(e.
Graphics
, focusRectangle, e.ForeColor, e.BackColor);
1021
e.
Graphics
.FillRectangle(backBrush, new Rectangle(focusRectangle.Right + 1, e.Bounds.Y, e.Bounds.Width - focusRectangle.Right - 1, e.Bounds.Height));
1025
e.
Graphics
.FillRectangle(backBrush, new Rectangle(bounds.X, e.Bounds.Y, e.Bounds.Width - bounds.X, e.Bounds.Height));
1027
e.
Graphics
.DrawString(columnName, e.Font!, foreBrush, bounds);
System.Windows.Forms.Tests (3)
System\Windows\Forms\AccessibleObjects\ComboBox.ComboBoxItemAccessibleObjectTests.cs (1)
497
e.
Graphics
.DrawString(
System\Windows\Forms\DrawItemEventArgsTests.cs (2)
27
Assert.Equal(graphics, e.
Graphics
);
53
Assert.Equal(graphics, e.
Graphics
);
WinFormsControlsTest (2)
ComboBoxesWithScrollBars.cs (1)
138
e.
Graphics
.DrawString(
ListBoxes.cs (1)
46
e.
Graphics
.DrawString(listBox.Items[e.Index].ToString(),