This commit is contained in:
Basile Burg 2015-03-15 01:09:09 +01:00
parent b947838d7a
commit 03ce7716f9
2 changed files with 4 additions and 4 deletions

View File

@ -311,7 +311,7 @@ begin
fClient.Parameters.Clear; fClient.Parameters.Clear;
fClient.Parameters.Add('-d'); fClient.Parameters.Add('-d');
fClient.Parameters.Add('-c'); fClient.Parameters.Add('-c');
fClient.Parameters.Add(intToStr(fDoc.MouseStart -1)); fClient.Parameters.Add(intToStr(fDoc.MouseStart - 1));
fClient.Parameters.Add(fDoc.tempFilename); fClient.Parameters.Add(fDoc.tempFilename);
fClient.Execute; fClient.Execute;
// //

View File

@ -366,7 +366,7 @@ procedure TCEEditorWidget.getSymbolLoc;
var var
srcpos, i, sum: Integer; srcpos, i, sum: Integer;
fname: string; fname: string;
lel: byte; len: byte;
begin begin
if not DcdWrapper.available then exit; if not DcdWrapper.available then exit;
// //
@ -378,11 +378,11 @@ begin
// note: SelStart only matches srcpos if the target file has the same line ending // note: SelStart only matches srcpos if the target file has the same line ending
// as the operating system: the pos has to be found manually. // as the operating system: the pos has to be found manually.
sum := 0; sum := 0;
lel := getLineEndingLength(fDoc.fileName); len := getLineEndingLength(fDoc.fileName);
for i := 0 to fDoc.Lines.Count-1 do for i := 0 to fDoc.Lines.Count-1 do
begin begin
sum += length(fDoc.Lines.Strings[i]); sum += length(fDoc.Lines.Strings[i]);
sum += lel; sum += len;
//TODO-cenhancement: find declaration, determine column accurately. //TODO-cenhancement: find declaration, determine column accurately.
if sum >= srcpos then if sum >= srcpos then
begin begin