* fix highlight for 'i:=1to'

This commit is contained in:
pierre 2001-09-04 22:58:58 +00:00
parent 19bda8da46
commit c1f6cc5dbf

View File

@ -2149,7 +2149,6 @@ var
if C in WhiteSpaceChars then CC:=ccWhiteSpace else
if C in TabChars then CC:=ccTab else
if C in HashChars then CC:=ccHash else
if C in AlphaChars then CC:=ccAlpha else
if C in NumberChars then CC:=ccNumber else
if (LastCC=ccNumber) and (C in RealNumberChars) then
begin
@ -2158,11 +2157,17 @@ var
if (LineText[X+1]='.') then
cc:=ccSymbol
else
CC:=ccRealNumber
cc:=ccRealNumber;
end
else {'E','e'}
begin
if (LineText[X+1]in ['+','-','0'..'9']) then
cc:=ccRealNumber
else
cc:=ccrealnumber;
cc:=ccAlpha
end;
end else
if C in AlphaChars then CC:=ccAlpha else
CC:=ccSymbol;
GetCharClass:=CC;
end;
@ -2190,7 +2195,8 @@ var
case SClass of
ccWhiteSpace : C:=coWhiteSpaceColor;
ccTab : C:=coTabColor;
ccNumber :
ccNumber,
ccRealNumber :
if copy(WordS,1,1)='$' then
C:=coHexNumberColor
else
@ -2223,7 +2229,7 @@ var
FirstCC:=CC;
if ( (CC<>LastCC) and
(
((FirstCC=ccNumber) and (CC<>ccRealNumber)) or
((FirstCC=ccNumber) and (CC<>ccRealNumber) {and (CC<>ccNumber)}) or
(((CC<>ccAlpha) or (LastCC<>ccNumber) ) and
( (CC<>ccNumber) or (LastCC<>ccAlpha) ) and
( (CC<>ccNumber) or (LastCC<>ccHash) ) and
@ -2239,9 +2245,6 @@ var
if length(SymbolConcat)>=High(SymbolConcat) then
Delete(SymbolConcat,1,1);
SymbolConcat:=SymbolConcat+C;
end;
case CC of
ccSymbol :
if IsCommentSuffix and (InComment) then
Inc(EX) else
if IsStringSuffix and (InString) then
@ -2249,11 +2252,15 @@ var
if IsDirectiveSuffix and (InDirective) then
Inc(EX);
end;
if CC=ccRealNumber then
Inc(EX);
if (C='$') and (MatchedSymbol=false) and (IsDirectivePrefix=false) then
CC:=ccNumber;
if CC<>ccSymbol then SymbolConcat:='';
FormatWord(LastCC,ClassStart,EX);
ClassStart:=EX+1;
if ClassStart=X then
FirstCC:=CC;
case CC of
ccAlpha : ;
ccNumber :
@ -6930,7 +6937,10 @@ end;
END.
{
$Log$
Revision 1.3 2001-08-12 00:06:49 pierre
Revision 1.4 2001-09-04 22:58:58 pierre
* fix highlight for 'i:=1to'
Revision 1.3 2001/08/12 00:06:49 pierre
* better clipboard handling for files with tabs
Revision 1.2 2001/08/05 02:01:48 peter