7 references to DrawCaptionButton
System.Windows.Forms (1)
System\Windows\Forms\Controls\ToolStrips\ToolStripMenuItem.cs (1)
711
ControlPaint.
DrawCaptionButton
(g, new Rectangle(Point.Empty, image.Size), (CaptionButton)buttonToUse, ButtonState.Flat);
System.Windows.Forms.Tests (6)
System\Windows\Forms\ControlPaintTests.cs (6)
911
ControlPaint.
DrawCaptionButton
(graphics, rectangle, button, state);
914
ControlPaint.
DrawCaptionButton
(graphics, rectangle, button, state);
934
Assert.Throws<ArgumentNullException>("graphics", () => ControlPaint.
DrawCaptionButton
(null, new Rectangle(1, 2, 3, 4), CaptionButton.Close, state));
948
Assert.Throws<ArgumentException>(() => ControlPaint.
DrawCaptionButton
(graphics, new Rectangle(0, 0, width, height), CaptionButton.Close, state));
959
Assert.Throws<ArgumentOutOfRangeException>("width", () => ControlPaint.
DrawCaptionButton
(graphics, new Rectangle(0, 0, -3, 4), CaptionButton.Close, state));
970
Assert.Throws<ArgumentOutOfRangeException>("height", () => ControlPaint.
DrawCaptionButton
(graphics, new Rectangle(0, 0, 3, -4), CaptionButton.Close, state));