mirror of https://gitlab.com/basile.b/dexed.git
ddoc comments, ignore a line that starts with 'ditto'
and optionally a period.
This commit is contained in:
parent
5004840dde
commit
20ef73bb57
|
@ -337,6 +337,7 @@ end;
|
||||||
procedure TCEDcdWrapper.getDdocFromCursor(out aComment: string);
|
procedure TCEDcdWrapper.getDdocFromCursor(out aComment: string);
|
||||||
var
|
var
|
||||||
i: Integer;
|
i: Integer;
|
||||||
|
str: string;
|
||||||
begin
|
begin
|
||||||
if not fAvailable then exit;
|
if not fAvailable then exit;
|
||||||
if not fServerListening then exit;
|
if not fServerListening then exit;
|
||||||
|
@ -361,8 +362,12 @@ begin
|
||||||
fTempLines.LoadFromStream(fClient.Output);
|
fTempLines.LoadFromStream(fClient.Output);
|
||||||
if fTempLines.Count = 0 then
|
if fTempLines.Count = 0 then
|
||||||
updateServerlistening;
|
updateServerlistening;
|
||||||
for i := 0 to fTempLines.Count-1 do
|
for str in fTempLines do
|
||||||
aComment += ReplaceStr(fTempLines.Strings[i], '\n', LineEnding);
|
begin
|
||||||
|
if (length(str) < 9) and AnsiSameText(str[1..5], 'DITTO') then
|
||||||
|
continue;
|
||||||
|
aComment += ReplaceStr(str, '\n', LineEnding);
|
||||||
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TCEDcdWrapper.getDeclFromCursor(out aFilename: string; out aPosition: Integer);
|
procedure TCEDcdWrapper.getDeclFromCursor(out aFilename: string; out aPosition: Integer);
|
||||||
|
|
Loading…
Reference in New Issue