fix, dd files highlighter, used D HL but this not d code.

+ avoid content to be lexed to retrieve module name
This commit is contained in:
Basile Burg 2015-06-20 02:53:38 +02:00
parent fed331360c
commit 5e06daf09e
1 changed files with 3 additions and 3 deletions

View File

@ -722,9 +722,9 @@ end;
procedure TCESynMemo.identifierToD2Syn; procedure TCESynMemo.identifierToD2Syn;
begin begin
fIdentifier := GetWordAtRowCol(LogicalCaretXY); fIdentifier := GetWordAtRowCol(LogicalCaretXY);
if fIsDSource then if Highlighter = D2Syn then
D2Syn.CurrentIdentifier := fIdentifier D2Syn.CurrentIdentifier := fIdentifier
else if fIsTxtFile then else if Highlighter = TxtSyn then
TxtSyn.CurrIdent := fIdentifier; TxtSyn.CurrIdent := fIdentifier;
end; end;
@ -741,7 +741,7 @@ var
ext: string; ext: string;
begin begin
ext := extractFileExt(aFilename); ext := extractFileExt(aFilename);
if dExtList.IndexOf(ext) = -1 then if (dExtList.IndexOf(ext) = -1) or (ext = '.dd') then
Highlighter := TxtSyn; Highlighter := TxtSyn;
Lines.LoadFromFile(aFilename); Lines.LoadFromFile(aFilename);
fFilename := aFilename; fFilename := aFilename;