154 references to ButtonBorderStyle
System.Windows.Forms (91)
System\Windows\Forms\Controls\DataGridView\DataGridViewButtonCell.cs (3)
750
(ButtonState == ButtonState.Normal) ?
ButtonBorderStyle
.Outset :
ButtonBorderStyle
.Inset);
816
ButtonBorderStyle
.Solid);
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\DropDownButton.DropDownButtonAdapter.cs (16)
25
c, 1,
ButtonBorderStyle
.Outset,
26
c, 1,
ButtonBorderStyle
.Outset,
27
c, 2,
ButtonBorderStyle
.Inset,
28
c, 2,
ButtonBorderStyle
.Inset);
42
c, 1,
ButtonBorderStyle
.Solid,
43
c, 1,
ButtonBorderStyle
.Solid,
44
Control.BackColor, 2,
ButtonBorderStyle
.Outset,
45
Control.BackColor, 2,
ButtonBorderStyle
.Outset);
54
c, 1,
ButtonBorderStyle
.Solid,
55
c, 1,
ButtonBorderStyle
.Solid,
56
c, 1,
ButtonBorderStyle
.None,
57
c, 1,
ButtonBorderStyle
.None);
81
c, 1,
ButtonBorderStyle
.None,
82
c, 1,
ButtonBorderStyle
.None,
83
c, 1,
ButtonBorderStyle
.Solid,
84
c, 1,
ButtonBorderStyle
.None);
System\Windows\Forms\Controls\PropertyGrid\PropertyGridToolStripButton.cs (4)
37
leftColor: Color.Black, leftWidth: 1, leftStyle:
ButtonBorderStyle
.Dashed,
38
topColor: Color.Black, topWidth: 1, topStyle:
ButtonBorderStyle
.Dashed,
39
rightColor: Color.Black, rightWidth: 1, rightStyle:
ButtonBorderStyle
.Dashed,
40
bottomColor: Color.Black, bottomWidth: 1, bottomStyle:
ButtonBorderStyle
.Dashed);
System\Windows\Forms\Rendering\ControlPaint.cs (67)
377
private static DashStyle BorderStyleToDashStyle(
ButtonBorderStyle
borderStyle)
381
case
ButtonBorderStyle
.Dotted:
383
case
ButtonBorderStyle
.Dashed:
385
case
ButtonBorderStyle
.Solid:
426
DrawBorder(graphics, bounds, Color.FromKnownColor(KnownColor.WindowFrame),
ButtonBorderStyle
.Solid);
553
public static void DrawBorder(Graphics graphics, Rectangle bounds, Color color,
ButtonBorderStyle
style)
559
case
ButtonBorderStyle
.None:
562
case
ButtonBorderStyle
.Dotted:
563
case
ButtonBorderStyle
.Dashed:
564
case
ButtonBorderStyle
.Solid:
567
case
ButtonBorderStyle
.Inset:
568
case
ButtonBorderStyle
.Outset:
582
Color leftColor, int leftWidth,
ButtonBorderStyle
leftStyle,
583
Color topColor, int topWidth,
ButtonBorderStyle
topStyle,
584
Color rightColor, int rightWidth,
ButtonBorderStyle
rightStyle,
585
Color bottomColor, int bottomWidth,
ButtonBorderStyle
bottomStyle)
601
Color leftColor, int leftWidth,
ButtonBorderStyle
leftStyle,
602
Color topColor, int topWidth,
ButtonBorderStyle
topStyle,
603
Color rightColor, int rightWidth,
ButtonBorderStyle
rightStyle,
604
Color bottomColor, int bottomWidth,
ButtonBorderStyle
bottomStyle)
742
case
ButtonBorderStyle
.None:
744
case
ButtonBorderStyle
.Dotted:
745
case
ButtonBorderStyle
.Dashed:
746
case
ButtonBorderStyle
.Solid:
748
if (!topColor.HasTransparency() && topStyle ==
ButtonBorderStyle
.Solid)
763
ButtonBorderStyle
.Dotted => DashStyle.Dot,
764
ButtonBorderStyle
.Dashed => DashStyle.Dash,
777
case
ButtonBorderStyle
.Inset:
778
case
ButtonBorderStyle
.Outset:
786
topStyle ==
ButtonBorderStyle
.Inset
801
case
ButtonBorderStyle
.None:
803
case
ButtonBorderStyle
.Dotted:
804
case
ButtonBorderStyle
.Dashed:
805
case
ButtonBorderStyle
.Solid:
807
if (!leftColor.HasTransparency() && leftStyle ==
ButtonBorderStyle
.Solid)
822
ButtonBorderStyle
.Dotted => DashStyle.Dot,
823
ButtonBorderStyle
.Dashed => DashStyle.Dash,
836
case
ButtonBorderStyle
.Inset:
837
case
ButtonBorderStyle
.Outset:
845
leftStyle ==
ButtonBorderStyle
.Inset
860
case
ButtonBorderStyle
.None:
862
case
ButtonBorderStyle
.Dotted:
863
case
ButtonBorderStyle
.Dashed:
864
case
ButtonBorderStyle
.Solid:
866
if (!bottomColor.HasTransparency() && bottomStyle ==
ButtonBorderStyle
.Solid)
886
ButtonBorderStyle
.Dotted => DashStyle.Dot,
887
ButtonBorderStyle
.Dashed => DashStyle.Dash,
905
case
ButtonBorderStyle
.Inset:
906
case
ButtonBorderStyle
.Outset:
914
bottomStyle !=
ButtonBorderStyle
.Inset
934
case
ButtonBorderStyle
.None:
936
case
ButtonBorderStyle
.Dotted:
937
case
ButtonBorderStyle
.Dashed:
938
case
ButtonBorderStyle
.Solid:
940
if (!rightColor.HasTransparency() && rightStyle ==
ButtonBorderStyle
.Solid)
960
ButtonBorderStyle
.Dotted => DashStyle.Dot,
961
ButtonBorderStyle
.Dashed => DashStyle.Dash,
979
case
ButtonBorderStyle
.Inset:
980
case
ButtonBorderStyle
.Outset:
988
rightStyle !=
ButtonBorderStyle
.Inset
1087
private static void DrawBorderComplex(Graphics graphics, Rectangle bounds, Color color,
ButtonBorderStyle
style)
1091
if (style ==
ButtonBorderStyle
.Inset)
1130
Debug.Assert(style ==
ButtonBorderStyle
.Outset, "Caller should have known how to use us.");
1176
ButtonBorderStyle
style =
ButtonBorderStyle
.Solid)
1180
if (color.HasTransparency() || style !=
ButtonBorderStyle
.Solid)
1188
if (style ==
ButtonBorderStyle
.Solid)
System\Windows\Forms\ToolTip\DrawToolTipEventArgs.cs (1)
101
ControlPaint.DrawBorder(Graphics, Bounds, SystemColors.WindowFrame,
ButtonBorderStyle
.Solid);
System.Windows.Forms.Design (5)
System\Drawing\Design\ColorEditor.ColorPalette.cs (5)
387
ButtonBorderStyle
.Solid);
404
SystemColors.Control, 2,
ButtonBorderStyle
.Inset,
405
SystemColors.Control, 2,
ButtonBorderStyle
.Inset,
406
SystemColors.Control, 2,
ButtonBorderStyle
.Inset,
407
SystemColors.Control, 2,
ButtonBorderStyle
.Inset);
System.Windows.Forms.Tests (58)
System\Windows\Forms\ControlPaintTests.cs (51)
542
foreach (
ButtonBorderStyle
style in new
ButtonBorderStyle
[] {
ButtonBorderStyle
.Dashed,
ButtonBorderStyle
.Dotted,
ButtonBorderStyle
.Inset,
ButtonBorderStyle
.None,
ButtonBorderStyle
.Outset,
ButtonBorderStyle
.Solid,
ButtonBorderStyle
.None - 1,
ButtonBorderStyle
.Outset + 1 })
561
public void ControlPaint_DrawBorder_GraphicsRectangleColorButtonBorderStyle_Success(Rectangle bounds, Color color,
ButtonBorderStyle
style)
572
[InvalidEnumData<
ButtonBorderStyle
>]
573
[InlineData(
ButtonBorderStyle
.None)]
574
public void ControlPaint_DrawBorder_GraphicsRectangleColorButtonBorderStyleInvalidStyle_Nop(
ButtonBorderStyle
style)
586
foreach (
ButtonBorderStyle
style in new
ButtonBorderStyle
[] {
ButtonBorderStyle
.Dashed,
ButtonBorderStyle
.Dotted,
ButtonBorderStyle
.Inset,
ButtonBorderStyle
.None,
ButtonBorderStyle
.Outset,
ButtonBorderStyle
.Solid,
ButtonBorderStyle
.None - 1,
ButtonBorderStyle
.Outset + 1 })
617
Color leftColor, int leftWidth,
ButtonBorderStyle
leftStyle,
618
Color topColor, int topWidth,
ButtonBorderStyle
topStyle,
619
Color rightColor, int rightWidth,
ButtonBorderStyle
rightStyle,
620
Color bottomColor, int bottomWidth,
ButtonBorderStyle
bottomStyle)
632
foreach (
ButtonBorderStyle
style in new
ButtonBorderStyle
[] {
ButtonBorderStyle
.Dashed,
ButtonBorderStyle
.Dotted,
ButtonBorderStyle
.Inset,
ButtonBorderStyle
.None,
ButtonBorderStyle
.Outset,
ButtonBorderStyle
.Solid,
ButtonBorderStyle
.None - 1,
ButtonBorderStyle
.Outset + 1 })
659
Color leftColor, int leftWidth,
ButtonBorderStyle
leftStyle,
660
Color topColor, int topWidth,
ButtonBorderStyle
topStyle,
661
Color rightColor, int rightWidth,
ButtonBorderStyle
rightStyle,
662
Color bottomColor, int bottomWidth,
ButtonBorderStyle
bottomStyle)
670
[InlineData(
ButtonBorderStyle
.Dashed)]
671
[InlineData(
ButtonBorderStyle
.Dotted)]
672
[InlineData(
ButtonBorderStyle
.Inset)]
673
[InlineData(
ButtonBorderStyle
.Outset)]
674
[InlineData(
ButtonBorderStyle
.Solid)]
675
public void ControlPaint_DrawBorder_NullGraphics_ThrowsArgumentNullException(
ButtonBorderStyle
style)
681
[EnumData<
ButtonBorderStyle
>]
682
[InvalidEnumData<
ButtonBorderStyle
>]
683
public void ControlPaint_DrawBorder_NullGraphicsComplex_ThrowsArgumentNullException(
ButtonBorderStyle
style)
System\Windows\Forms\ControlPaintTests.Rendering.cs (7)
24
ControlPaint.DrawBorder(graphics, bounds, Color.Blue,
ButtonBorderStyle
.Solid);
43
ControlPaint.DrawBorder(graphics, bounds, Color.Gray,
ButtonBorderStyle
.Inset);
103
ControlPaint.DrawBorder(graphics, bounds, SystemColors.Control,
ButtonBorderStyle
.Inset);
178
ControlPaint.DrawBorder(graphics, bounds, Color.PeachPuff,
ButtonBorderStyle
.Outset);
252
ControlPaint.DrawBorder(graphics, bounds, SystemColors.Control,
ButtonBorderStyle
.Outset);
326
ControlPaint.DrawBorder(graphics, bounds, Color.Green,
ButtonBorderStyle
.Dotted);
354
ControlPaint.DrawBorder(graphics, bounds, Color.Pink,
ButtonBorderStyle
.Dashed);