WinAPI: CreateSolidBrush 建立实心画刷

//声明:
CreateSolidBrush(
  p1: COLORREF {颜色值}
): HBRUSH;     {返回画刷句柄}

//举例: procedure TForm1.FormPaint(Sender: TObject); var BrushHandle: HBRUSH; begin BrushHandle := CreateSolidBrush(clYellow); FillRect(Canvas.Handle, ClientRect, BrushHandle); DeleteObject(BrushHandle); end;
//效果图:

原文地址:https://www.cnblogs.com/del/p/1066566.html