首页  编辑  

窗体背景渐变

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

var i: word;

 dy, y: real;

begin

 dy := clientheight / 256;

 y := 0;

 for i := 255 downto 0 do

 begin

   canvas.brush.color := $00000000 + i * $10000;

   canvas.fillrect(rect(0, round(y), clientwidth, round(y + dy)));

   y := y + dy;

 end;

end;