help-Tcolor :
the low three bytes represent RGB color intensities for blue, green, and red, respectively. The value $00FF0000 represents full-intensity, pure blue, $0000FF00 is pure green, and $000000FF is pure red. $00000000 is black and $00FFFFFF is white.
the low three bytes represent RGB color intensities for blue, green, and red, respectively. The value $00FF0000 represents full-intensity, pure blue, $0000FF00 is pure green, and $000000FF is pure red. $00000000 is black and $00FFFFFF is white.
时间上的如下:
在窗口上放一个Label和一个Timer,在OnTimer事件里加下面代码(蓝色渐变)procedure TForm1.Timer1Timer(Sender: TObject);
begin
if nB > 255 then
nB := 0;
Label1.Color := RGB(0, 0, nB);
Inc(nB);
Perform(CM_INVALIDATE, 1, 0);
Application.ProcessMessages;
end;Timer控件的Interval 设的小一点儿明显;
nB是一个窗口级的全局Integer变量,初始值设为0;
其他颜色渐变在RGB里做相应调整。
i must go , bye-bye