CRenderTarget::DrawRectangle

绘制具有指定的尺寸和笔画样式的矩形边框。

void DrawRectangle(
   const CD2DRectF& rect,
   CD2DBrush* pBrush,
   FLOAT fStrokeWidth = 1.0,
   ID2D1StrokeStyle* strokeStyle = NULL
);

参数

  • rect
    要绘制的矩形的尺寸(以与设备无关的像素为单位)

  • pBrush
    用于绘制矩形笔画的画笔。

  • fStrokeWidth
    大于等于 0.0f 的指定该矩形笔画宽度的值。 笔划在矩形的边框上居中显示。

  • strokeStyle
    要绘制的笔画样式,或者为 NULL 以绘制实心笔画。

要求

标头: afxrendertarget.h

请参见

参考

CRenderTarget 类