Color definition problem

Scripter seems to be unaware of colors.

uses Classes, SysUtils;

Scriptfunction :
// Example of a flashing function
function PB2Blinker(InValue: variant; compIdx : integer) : variant;
    hour, minute, second, millisecond : integer;
    cl: TColor;
    lb: TLabel;
    DecodeTime(now, hour, minute, second, millisecond);
    if second mod 1 = 0 then
        cl := clRed
    else cl := clYellow;
    lb := PartScreenData.complist[compidx];
    lb.Color := cl;
    Result := InValue + ' Blinker';

Errormessage by Scripter :
Unknown identifier or variable is not declared : clRed

Do I have to define the colors by myself ?
Normally they are defined in Sysutils which is included.
Workung with Delphi XE8 and current version of scripter.

Gerhard Sachs

Hello Gerhard,

yes, you have to add colors yourself, they are not imported automatically by default. You can simply use:

Scripter.AddConstant('clRed', clRed);

Or in Your project: 

uses ap_Graphics;
This unit automaticaly defined colors constants.