ControlPaint.DrawSelectionFrame 方法

定义

在指定的图形图面上,使用指定的内和外部尺寸以及指定的背景色绘制处于指定状态的标准选择框架。

public:
 static void DrawSelectionFrame(System::Drawing::Graphics ^ graphics, bool active, System::Drawing::Rectangle outsideRect, System::Drawing::Rectangle insideRect, System::Drawing::Color backColor);
public static void DrawSelectionFrame(System.Drawing.Graphics graphics, bool active, System.Drawing.Rectangle outsideRect, System.Drawing.Rectangle insideRect, System.Drawing.Color backColor);
static member DrawSelectionFrame : System.Drawing.Graphics * bool * System.Drawing.Rectangle * System.Drawing.Rectangle * System.Drawing.Color -> unit
Public Shared Sub DrawSelectionFrame (graphics As Graphics, active As Boolean, outsideRect As Rectangle, insideRect As Rectangle, backColor As Color)

参数

graphics
Graphics

Graphics 绘制的。

active
Boolean

true 绘制处于活动状态的选择帧;否则,为 false.

outsideRect
Rectangle

表示 Rectangle 所选框架的外部边界。

insideRect
Rectangle

表示 Rectangle 所选框架的内部边界。

backColor
Color

Color框架后面的背景。

注解

选择框架是在设计时围绕所选组件绘制的框架。

backColor 参数用于计算框架的填充颜色,以便它始终在背景中可见。

如果参数 active 设置为 true,则选择框将绘制为一组阴影标记,指示组件已激活;否则,选择框使用点状图案或无点绘制,具体取决于实现。

适用于