parent
ed11a1ca8f
commit
505a537c09
|
|
@ -481,6 +481,7 @@ type TTslSynHighLighter = class(TSynHighLighter)
|
||||||
end
|
end
|
||||||
if pos(vi,jsfh) then
|
if pos(vi,jsfh) then
|
||||||
begin
|
begin
|
||||||
|
if ttk then
|
||||||
SetJsToken(tokens,ttk,idx-1);
|
SetJsToken(tokens,ttk,idx-1);
|
||||||
end
|
end
|
||||||
if vi="[" then
|
if vi="[" then
|
||||||
|
|
@ -593,6 +594,7 @@ type TTslSynHighLighter = class(TSynHighLighter)
|
||||||
end
|
end
|
||||||
idx++;
|
idx++;
|
||||||
end
|
end
|
||||||
|
if ttk then
|
||||||
SetJsToken(tokens,ttk,idx-1);
|
SetJsToken(tokens,ttk,idx-1);
|
||||||
end else
|
end else
|
||||||
if cst="'" or cst='"' then
|
if cst="'" or cst='"' then
|
||||||
|
|
@ -668,6 +670,7 @@ type TTslSynHighLighter = class(TSynHighLighter)
|
||||||
end else
|
end else
|
||||||
if FSynBranch="tsl" and vi="?" then
|
if FSynBranch="tsl" and vi="?" then
|
||||||
begin
|
begin
|
||||||
|
if ttk then
|
||||||
SetTToken(tokens,ttk,idx-1);
|
SetTToken(tokens,ttk,idx-1);
|
||||||
if idx<e and s[idx+1]=">" then
|
if idx<e and s[idx+1]=">" then
|
||||||
begin
|
begin
|
||||||
|
|
@ -685,6 +688,7 @@ type TTslSynHighLighter = class(TSynHighLighter)
|
||||||
end else
|
end else
|
||||||
if vi ="'" then
|
if vi ="'" then
|
||||||
begin
|
begin
|
||||||
|
if ttk then
|
||||||
SetTToken(tokens,ttk,idx-1);
|
SetTToken(tokens,ttk,idx-1);
|
||||||
SetTToken(tokens,"'",idx,"'");
|
SetTToken(tokens,"'",idx,"'");
|
||||||
if idx=e then return "'";
|
if idx=e then return "'";
|
||||||
|
|
@ -707,6 +711,7 @@ type TTslSynHighLighter = class(TSynHighLighter)
|
||||||
end else
|
end else
|
||||||
if vi = '"' then
|
if vi = '"' then
|
||||||
begin
|
begin
|
||||||
|
if ttk then
|
||||||
SetTToken(tokens,ttk,idx-1);
|
SetTToken(tokens,ttk,idx-1);
|
||||||
SetTToken(tokens,'"',idx,'"');
|
SetTToken(tokens,'"',idx,'"');
|
||||||
if idx=e then return '"';
|
if idx=e then return '"';
|
||||||
|
|
@ -729,12 +734,14 @@ type TTslSynHighLighter = class(TSynHighLighter)
|
||||||
end else
|
end else
|
||||||
if vi="{" then
|
if vi="{" then
|
||||||
begin
|
begin
|
||||||
|
if ttk then
|
||||||
SetTToken(tokens,ttk,idx-1);
|
SetTToken(tokens,ttk,idx-1);
|
||||||
SetTToken(tokens,'{',idx,'{');
|
SetTToken(tokens,'{',idx,'{');
|
||||||
return ParserTokenLines(s,idx+1,e,'{',tokens);
|
return ParserTokenLines(s,idx+1,e,'{',tokens);
|
||||||
end else
|
end else
|
||||||
if vi="/" then
|
if vi="/" then
|
||||||
begin
|
begin
|
||||||
|
if ttk then
|
||||||
SetTToken(tokens,ttk,idx-1);
|
SetTToken(tokens,ttk,idx-1);
|
||||||
if idx=e then
|
if idx=e then
|
||||||
begin
|
begin
|
||||||
|
|
@ -753,6 +760,7 @@ type TTslSynHighLighter = class(TSynHighLighter)
|
||||||
end else
|
end else
|
||||||
if vi="#" then
|
if vi="#" then
|
||||||
begin
|
begin
|
||||||
|
if ttk then
|
||||||
SetTToken(tokens,ttk,idx-1);
|
SetTToken(tokens,ttk,idx-1);
|
||||||
if idx=e then
|
if idx=e then
|
||||||
begin
|
begin
|
||||||
|
|
@ -771,6 +779,7 @@ type TTslSynHighLighter = class(TSynHighLighter)
|
||||||
end else
|
end else
|
||||||
if vi="(" then
|
if vi="(" then
|
||||||
begin
|
begin
|
||||||
|
if ttk then
|
||||||
SetTToken(tokens,ttk,idx-1);
|
SetTToken(tokens,ttk,idx-1);
|
||||||
if idx=e then
|
if idx=e then
|
||||||
begin
|
begin
|
||||||
|
|
@ -792,6 +801,7 @@ type TTslSynHighLighter = class(TSynHighLighter)
|
||||||
end else
|
end else
|
||||||
if vi="%" then
|
if vi="%" then
|
||||||
begin
|
begin
|
||||||
|
if ttk then
|
||||||
SetTToken(tokens,ttk,idx-1);
|
SetTToken(tokens,ttk,idx-1);
|
||||||
idx++;
|
idx++;
|
||||||
if idx<=e then
|
if idx<=e then
|
||||||
|
|
@ -832,6 +842,7 @@ type TTslSynHighLighter = class(TSynHighLighter)
|
||||||
end else
|
end else
|
||||||
if vi="<" then
|
if vi="<" then
|
||||||
begin
|
begin
|
||||||
|
if ttk then
|
||||||
SetTToken(tokens,ttk,idx-1);
|
SetTToken(tokens,ttk,idx-1);
|
||||||
if (idx+6<=e) and s[idx+1]="?" and lowercase(s[idx+2:idx+6])="tslx>" then
|
if (idx+6<=e) and s[idx+1]="?" and lowercase(s[idx+2:idx+6])="tslx>" then
|
||||||
begin
|
begin
|
||||||
|
|
@ -852,6 +863,7 @@ type TTslSynHighLighter = class(TSynHighLighter)
|
||||||
end else
|
end else
|
||||||
if pos(vi,"`~@#$^&*)+-;,.?:[]|\\=><%/") then
|
if pos(vi,"`~@#$^&*)+-;,.?:[]|\\=><%/") then
|
||||||
begin
|
begin
|
||||||
|
if ttk then
|
||||||
SetTToken(tokens,ttk,idx-1);
|
SetTToken(tokens,ttk,idx-1);
|
||||||
if vi=")" then
|
if vi=")" then
|
||||||
begin
|
begin
|
||||||
|
|
@ -878,6 +890,7 @@ type TTslSynHighLighter = class(TSynHighLighter)
|
||||||
end
|
end
|
||||||
idx++;
|
idx++;
|
||||||
end
|
end
|
||||||
|
if ttk then
|
||||||
SetTToken(tokens,ttk,idx-1);
|
SetTToken(tokens,ttk,idx-1);
|
||||||
end else
|
end else
|
||||||
if cst="'" or cst='"' then
|
if cst="'" or cst='"' then
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue