Straight from the help files in Delphi 3 (and it looks the same in Delphi 6):
This example draws a red line (very slowly) when a button is pressed. Attach the following code to the button?¢_Ts OnClick event handler:
procedure TForm1.Button1Click(Sender: TObject);
var
W: Word;
begin
for W := 10 to 200 do
Canvas.Pixels[W, 10] := clRed;
end;
Bookmarks