144 references to SystemPens
System.Drawing (1)
System.Drawing.cs (1)
158[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Drawing.SystemPens))]
System.Drawing.Common.Tests (34)
System\Drawing\SystemPensTest.cs (34)
12yield return Pen(() => SystemPens.ActiveBorder, SystemColors.ActiveBorder); 13yield return Pen(() => SystemPens.ActiveCaption, SystemColors.ActiveCaption); 14yield return Pen(() => SystemPens.ActiveCaptionText, SystemColors.ActiveCaptionText); 15yield return Pen(() => SystemPens.AppWorkspace, SystemColors.AppWorkspace); 16yield return Pen(() => SystemPens.ButtonFace, SystemColors.ButtonFace); 17yield return Pen(() => SystemPens.ButtonHighlight, SystemColors.ButtonHighlight); 18yield return Pen(() => SystemPens.ButtonShadow, SystemColors.ButtonShadow); 19yield return Pen(() => SystemPens.Control, SystemColors.Control); 20yield return Pen(() => SystemPens.ControlDark, SystemColors.ControlDark); 21yield return Pen(() => SystemPens.ControlDarkDark, SystemColors.ControlDarkDark); 22yield return Pen(() => SystemPens.ControlLight, SystemColors.ControlLight); 23yield return Pen(() => SystemPens.ControlLightLight, SystemColors.ControlLightLight); 24yield return Pen(() => SystemPens.ControlText, SystemColors.ControlText); 25yield return Pen(() => SystemPens.Desktop, SystemColors.Desktop); 26yield return Pen(() => SystemPens.GradientActiveCaption, SystemColors.GradientActiveCaption); 27yield return Pen(() => SystemPens.GradientInactiveCaption, SystemColors.GradientInactiveCaption); 28yield return Pen(() => SystemPens.GrayText, SystemColors.GrayText); 29yield return Pen(() => SystemPens.Highlight, SystemColors.Highlight); 30yield return Pen(() => SystemPens.HighlightText, SystemColors.HighlightText); 31yield return Pen(() => SystemPens.HotTrack, SystemColors.HotTrack); 32yield return Pen(() => SystemPens.InactiveBorder, SystemColors.InactiveBorder); 33yield return Pen(() => SystemPens.InactiveCaption, SystemColors.InactiveCaption); 34yield return Pen(() => SystemPens.InactiveCaptionText, SystemColors.InactiveCaptionText); 35yield return Pen(() => SystemPens.Info, SystemColors.Info); 36yield return Pen(() => SystemPens.InfoText, SystemColors.InfoText); 37yield return Pen(() => SystemPens.Menu, SystemColors.Menu); 38yield return Pen(() => SystemPens.MenuBar, SystemColors.MenuBar); 39yield return Pen(() => SystemPens.MenuHighlight, SystemColors.MenuHighlight); 40yield return Pen(() => SystemPens.MenuText, SystemColors.MenuText); 41yield return Pen(() => SystemPens.ScrollBar, SystemColors.ScrollBar); 42yield return Pen(() => SystemPens.Window, SystemColors.Window); 43yield return Pen(() => SystemPens.WindowFrame, SystemColors.WindowFrame); 44yield return Pen(() => SystemPens.WindowText, SystemColors.WindowText); 86AssertExtensions.Throws<ArgumentException>(null, () => SystemPens.FromSystemColor(Color.Blue));
System.Windows.Forms (91)
System\Windows\Forms\Controls\ComboBox\ComboBox.FlatComboAdapter.cs (1)
88Pen innerPen = comboBox.Enabled ? borderPen : SystemPens.Control;
System\Windows\Forms\Controls\DataGridView\DataGridViewComboBoxCell.cs (9)
1987g.DrawRectangle(SystemPens.ControlLightLight, new Rectangle(valBounds.X, valBounds.Y, valBounds.Width - 1, valBounds.Height - 1)); 2094Pen pen = SystemInformation.HighContrast ? SystemPens.ControlLight : SystemPens.Control; 2114pen = SystemPens.ControlDarkDark; 2135pen = SystemPens.ControlLightLight; 2145pen = SystemPens.ControlDark; 2193g.DrawLine(SystemPens.ControlText, pt1.X, pt1.Y, pt2.X, pt2.Y); 2206g.DrawRectangle(SystemPens.ControlDark, dropRect); 2296g.DrawRectangle(SystemPens.ControlDark, valBounds);
System\Windows\Forms\Controls\ListBoxes\ListBox.cs (1)
2331g.DrawRectangle(SystemPens.Window, rect);
System\Windows\Forms\Controls\ListView\DrawListViewColumnHeaderEventArgs.cs (5)
107Graphics.DrawRectangle(SystemPens.ControlDarkDark, r); 113Graphics.DrawLine(SystemPens.ControlLightLight, r.X, r.Y, r.Right, r.Y); 114Graphics.DrawLine(SystemPens.ControlLightLight, r.X, r.Y, r.X, r.Bottom); 117Graphics.DrawLine(SystemPens.ControlDark, r.X + 1, r.Bottom, r.Right, r.Bottom); 118Graphics.DrawLine(SystemPens.ControlDark, r.Right, r.Y + 1, r.Right, r.Bottom);
System\Windows\Forms\Controls\ListView\ListView.cs (1)
6899g.DrawRectangle(SystemPens.Window, rect);
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\GridEntry.cs (1)
1858g.DrawRectangle(SystemPens.WindowText, rectPaint);
System\Windows\Forms\Controls\TextBox\MaskedTextBox.cs (1)
2914g.DrawRectangle(SystemPens.Window, rect);
System\Windows\Forms\Controls\TextBox\TextBox.cs (1)
830g.DrawRectangle(SystemPens.Window, rect);
System\Windows\Forms\Controls\ToolStrips\ToolStrip.cs (6)
3787g.DrawLines(SystemPens.ControlText, (ReadOnlySpan<Point>) 3794g.DrawLines(SystemPens.ControlText, (ReadOnlySpan<Point>) 3801g.DrawLines(SystemPens.ControlText, (ReadOnlySpan<Point>) 3814g.DrawLines(SystemPens.ControlText, (ReadOnlySpan<Point>) 3821g.DrawLines(SystemPens.ControlText, (ReadOnlySpan<Point>) 3828g.DrawLines(SystemPens.ControlText, (ReadOnlySpan<Point>)
System\Windows\Forms\Controls\ToolStrips\ToolStripHighContrastRenderer.cs (11)
100e.Graphics.DrawRectangle(SystemPens.ButtonHighlight, new Rectangle(0, 0, e.Item.Width - 1, e.Item.Height - 1)); 144g.DrawRectangle(SystemPens.ButtonHighlight, bounds.X, bounds.Y, bounds.Width - 1, bounds.Height - 1); 149g.DrawRectangle(SystemPens.HighlightText, dropDownRect); 181e.Graphics.DrawRectangle(SystemPens.ButtonHighlight, 0, 0, e.Item.Width - 1, e.Item.Height - 1); 190g.DrawRectangle(SystemPens.ControlLight, bounds.X, bounds.Y, bounds.Width - 1, bounds.Height - 1); 263g.DrawRectangle(SystemPens.ButtonHighlight, bounds.X, bounds.Y, bounds.Width - 1, bounds.Height - 1); 277g.DrawRectangle(SystemPens.ButtonShadow, bounds.X, bounds.Y, bounds.Width - 1, bounds.Height - 1); 341g.DrawRectangle(SystemPens.ButtonShadow, bounds); 347Pen foreColorPen = SystemPens.ButtonShadow; 420g.DrawRectangle(SystemPens.ControlLight, bounds.X, bounds.Y, bounds.Width - 1, bounds.Height - 1); 452g.DrawRectangle(SystemPens.ControlLight, bounds.X, bounds.Y, bounds.Width - 1, bounds.Height - 1);
System\Windows\Forms\Controls\ToolStrips\ToolStripMenuItem.cs (1)
712g.DrawRectangle(SystemPens.Control, 0, 0, image.Width - 1, image.Height - 1);
System\Windows\Forms\Controls\ToolStrips\ToolstripProfessionalRenderer.cs (5)
194g.DrawLine(SystemPens.ControlText, 199g.DrawLine(SystemPens.ButtonHighlight, 207g.DrawLine(SystemPens.ControlText, 212g.DrawLine(SystemPens.ButtonHighlight, 1075g.DrawRectangle(SystemPens.Highlight, bounds.X, bounds.Y, bounds.Width - 1, bounds.Height - 1);
System\Windows\Forms\Controls\ToolStrips\ToolStripSystemRenderer.cs (13)
251e.Graphics.DrawRectangle(SystemPens.ControlDark, bounds); 262e.Graphics.DrawLine(SystemPens.ButtonHighlight, 0, bounds.Bottom - 1, bounds.Width, bounds.Bottom - 1); 263e.Graphics.DrawLine(SystemPens.InactiveBorder, 0, bounds.Bottom - 2, bounds.Width, bounds.Bottom - 2); 267e.Graphics.DrawLine(SystemPens.ButtonHighlight, 0, bounds.Bottom - 1, bounds.Width, bounds.Bottom - 1); 268e.Graphics.DrawLine(SystemPens.ButtonShadow, 0, bounds.Bottom - 2, bounds.Width, bounds.Bottom - 2); 714Pen leftPen = (rightToLeft) ? SystemPens.ButtonHighlight : foreColorPen; 715Pen rightPen = (rightToLeft) ? foreColorPen : SystemPens.ButtonHighlight; 739g.DrawLine(SystemPens.ButtonHighlight, bounds.Left, startY, bounds.Right, startY); 749topPen = (state == ToolBarState.Hot) ? SystemPens.ButtonHighlight : SystemPens.ButtonShadow; 750bottomPen = (state == ToolBarState.Hot) ? SystemPens.ButtonShadow : SystemPens.ButtonHighlight; 766e.Graphics.DrawLine(SystemPens.ButtonHighlight, 0, 0, e.ToolStrip.Width, 0);
System\Windows\Forms\Controls\TreeView\TreeView.cs (1)
3155g.DrawRectangle(SystemPens.Window, rect);
System\Windows\Forms\Panels\TableLayoutPanel\TableLayoutPanel.cs (4)
443SystemPens.ControlDark, 450SystemPens.ControlDark, 459SystemPens.Window, 465SystemPens.Window,
System\Windows\Forms\Printing\PrintPreviewDialog.cs (1)
1144e.Graphics.DrawRectangle(SystemPens.ControlDark, rect);
System\Windows\Forms\Rendering\ControlPaint.cs (29)
1086Pen pen = SystemPens.ControlLight; 1389Pen pen = SystemPens.ControlDark; 2338g.DrawLine(SystemPens.ControlDark, x, y, right - 1, y); 2339g.DrawLine(SystemPens.ControlDark, x, y, x, bottom - 1); 2340g.DrawLine(SystemPens.Window, right - 1, y, right - 1, bottom - 1); 2341g.DrawLine(SystemPens.Window, x, bottom - 1, right - 1, bottom - 1); 2347g.DrawLine(SystemPens.Window, x, y, right - 1, y); 2348g.DrawLine(SystemPens.Window, x, y, x, bottom - 1); 2349g.DrawLine(SystemPens.ControlDark, right - 1, y, right - 1, bottom - 1); 2350g.DrawLine(SystemPens.ControlDark, x, bottom - 1, right - 1, bottom - 1); 2364g.DrawRectangle(SystemPens.ControlDark, bound); 2368g.DrawLine(SystemPens.Window, bound.X, bound.Y, bound.X + bound.Width - 1, bound.Y); 2369g.DrawLine(SystemPens.Window, bound.X, bound.Y, bound.X, bound.Y + bound.Height - 1); 2370g.DrawLine(SystemPens.ControlDark, bound.X + bound.Width - 1, bound.Y, bound.X + bound.Width - 1, bound.Y + bound.Height - 1); 2371g.DrawLine(SystemPens.ControlDark, bound.X, bound.Y + bound.Height - 1, bound.X + bound.Width - 1, bound.Y + bound.Height - 1); 2375g.DrawRectangle(SystemPens.Control, bound); 2379g.DrawLine(SystemPens.Window, bound.X, bound.Y, bound.X + bound.Width - 1, bound.Y); 2380g.DrawLine(SystemPens.Window, bound.X, bound.Y, bound.X, bound.Y + bound.Height - 1); 2382g.DrawLine(SystemPens.ControlDark, bound.X + bound.Width - 1, bound.Y, bound.X + bound.Width - 1, bound.Y + bound.Height - 1); 2383g.DrawLine(SystemPens.ControlDark, bound.X, bound.Y + bound.Height - 1, bound.X + bound.Width - 1, bound.Y + bound.Height - 1); 2387g.DrawLine(SystemPens.ControlDark, bound.X, bound.Y, bound.X + bound.Width - 1, bound.Y); 2388g.DrawLine(SystemPens.ControlDark, bound.X, bound.Y, bound.X, bound.Y + bound.Height - 1); 2389g.DrawLine(SystemPens.Window, bound.X + bound.Width - 1, bound.Y, bound.X + bound.Width - 1, bound.Y + bound.Height - 1); 2390g.DrawLine(SystemPens.Window, bound.X, bound.Y + bound.Height - 1, bound.X + bound.Width - 1, bound.Y + bound.Height - 1); 2395g.DrawRectangle(SystemPens.Control, bound); 2399g.DrawLine(SystemPens.ControlDark, bound.X, bound.Y, bound.X + bound.Width - 1, bound.Y); 2400g.DrawLine(SystemPens.ControlDark, bound.X, bound.Y, bound.X, bound.Y + bound.Height - 1); 2401g.DrawLine(SystemPens.Window, bound.X + bound.Width - 1, bound.Y, bound.X + bound.Width - 1, bound.Y + bound.Height - 1); 2402g.DrawLine(SystemPens.Window, bound.X, bound.Y + bound.Height - 1, bound.X + bound.Width - 1, bound.Y + bound.Height - 1);
System.Windows.Forms.Design (17)
System\ComponentModel\Design\CollectionEditor.CollectionEditorCollectionForm.cs (1)
599g.DrawRectangle(SystemPens.ControlText, baseVar.X, baseVar.Y, baseVar.Width - 1, baseVar.Height - 1);
System\ComponentModel\Design\CollectionEditor.SplitButton.cs (4)
207g.DrawLine(SystemPens.ButtonHighlight, bounds.Left + PushButtonWidth, 4, bounds.Left + PushButtonWidth, bounds.Bottom - 4); 208g.DrawLine(SystemPens.ButtonHighlight, bounds.Left + PushButtonWidth + 1, 4, bounds.Left + PushButtonWidth + 1, bounds.Bottom - 4); 214g.DrawLine(SystemPens.ButtonHighlight, bounds.Right - PushButtonWidth, 4, bounds.Right - PushButtonWidth, bounds.Bottom - 4); 215g.DrawLine(SystemPens.ButtonHighlight, bounds.Right - PushButtonWidth - 1, 4, bounds.Right - PushButtonWidth - 1, bounds.Bottom - 4);
System\ComponentModel\Design\DesignerActionPanel.EditorPropertyLine.cs (1)
297swatchGraphics.DrawRectangle(SystemPens.ControlDark, new Rectangle(0, 0, width - 1, height - 1));
System\ComponentModel\Design\DesignerActionPanel.TextBoxPropertyLine.cs (1)
292g.DrawRectangle(SystemPens.ControlDark, editRect);
System\Drawing\Design\ColorEditor.ColorUI.cs (1)
276graphics.DrawRectangle(SystemPens.WindowText, new Rectangle(die.Bounds.X + 2, die.Bounds.Y + 2, 22 - 1, die.Bounds.Height - 4 - 1));
System\Drawing\Design\CursorEditor.CursorUI.cs (1)
70e.Graphics.DrawRectangle(SystemPens.WindowText, new Rectangle(e.Bounds.X + 2, e.Bounds.Y + 2, 32 - 1, e.Bounds.Height - 4 - 1));
System\Drawing\Design\ImageEditor.cs (1)
179e.Graphics.DrawRectangle(SystemPens.WindowFrame, r);
System\Windows\Forms\Design\AnchorEditor.AnchorUI.cs (1)
271e.Graphics.DrawRectangle(SystemPens.WindowFrame, rc.X, rc.Y, rc.Width - 1, rc.Height - 1);
System\Windows\Forms\Design\Behavior\DragAssistanceManager.cs (1)
27private readonly Pen _edgePen = SystemPens.Highlight;
System\Windows\Forms\Design\DesignerUtils.cs (2)
190Pen pen = SystemPens.ControlDarkDark; 193pen = SystemPens.ControlLight;
System\Windows\Forms\Design\FlowLayoutPanelDesigner .cs (2)
439var pen = SystemPens.ControlText; 443pen = SystemPens.ControlLight;
System\Windows\Forms\Design\TabOrder.cs (1)
281pen = SystemPens.HighlightText;
System.Windows.Forms.Primitives (1)
System\Windows\Forms\GdiPlus\GdiPlusCache.cs (1)
32? SystemPens.FromSystemColor(color)