首页  编辑  

一个窗体的特效

Tags: /超级猛料/VCL/Form,窗体/窗体特效/   Date Created:

一个窗体的特效:

procedure TForm1.Button1Click(Sender: TObject);

var

 r:thandle;

 i:integer;

begin

 for i:=1 to trunc(width/1.414) do

 begin

   r:=CreateEllipticRgn(trunc(width/2)-i,trunc(height/2)-i,trunc(width/2)+i,trunc(height/2)+i);

   SetWindowRgn(handle,r,true);

   //Next one Line fixed by Aiming.

   Application.ProcessMessages;

   sleep(1);

 end;

end;