Mega Code Archive

 
Categories / Delphi / Graphic
 

Farklı çizgiler

Codec By GeNiUS ! genius@turkiye.com TForm1 = class(TForm) procedure FormCreate(Sender: TObject); procedure FormPaint(Sender: TObject); public DrawNow : Integer; end; var Form1: TForm1; procedure DrawPoint(x,y : Integer;lpData : LParam); stdcall; implementation {$R *.DFM} procedure DrawPoint(x,y : Integer;lpData : LParam); begin with TObject(lpData) as TForm1 do begin if DrawNow mod 4 = 0 then Canvas.Rectangle(x-2,y-2,x+3,y+3); Inc(DrawNow); end; end; procedure TForm1.FormCreate(Sender: TObject); begin DrawNow := 0; end; procedure TForm1.FormPaint(Sender: TObject); begin LineDDA(0,0,Width,Height,@DrawPoint,Integer(Self)); end; end.