//声明: Rectangle( DC: HDC; {设备环境句柄} X1, Y1, X2, Y2: Integer {两个点的坐标} ): BOOL; //举例: procedure TForm1.FormPaint(Sender: TObject); const x1 = 20; y1 = 20; x2 = 200; y2 = 100; begin Rectangle(Canvas.Handle, x1,y1, x2,y2); end; //效果图:
![r_829a.png](https://i-blog.csdnimg.cn/blog_migrate/f3de336078c9839ae71adc05714362c2.png)
//声明: Rectangle( DC: HDC; {设备环境句柄} X1, Y1, X2, Y2: Integer {两个点的坐标} ): BOOL; //举例: procedure TForm1.FormPaint(Sender: TObject); const x1 = 20; y1 = 20; x2 = 200; y2 = 100; begin Rectangle(Canvas.Handle, x1,y1, x2,y2); end; //效果图:
转载于:https://www.cnblogs.com/del/archive/2008/02/09/1066314.html