mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-20 17:49:27 +02:00
Correctly display pchar longer than high(string) nito several lines in TGDBWindow.WriteText method
git-svn-id: trunk@29755 -
This commit is contained in:
parent
da3ce1a6d5
commit
6887eb739a
@ -2579,7 +2579,10 @@ begin
|
||||
While assigned(p) and (p^<>#0) do
|
||||
begin
|
||||
pe:=strscan(p,#10);
|
||||
if pe<>nil then
|
||||
{ if pe-p is more than High(s), discard for this round }
|
||||
if (pe<>nil) and (pe-p > high(s)) then
|
||||
pe:=nil;
|
||||
if (pe<>nil) then
|
||||
pe^:=#0;
|
||||
s:=strpas(p);
|
||||
If IsError then
|
||||
@ -2590,16 +2593,16 @@ begin
|
||||
if pe<>nil then
|
||||
pe^:=#10;
|
||||
if pe=nil then
|
||||
p:=nil
|
||||
begin
|
||||
if strlen(p)<High(s) then
|
||||
p:=nil
|
||||
else
|
||||
p:=p+High(s);
|
||||
end
|
||||
else
|
||||
begin
|
||||
if pe-p > High(s) then
|
||||
p:=p+High(s)-1
|
||||
else
|
||||
begin
|
||||
p:=pe;
|
||||
inc(p);
|
||||
end;
|
||||
p:=pe;
|
||||
inc(p);
|
||||
end;
|
||||
end;
|
||||
DeskTop^.Unlock;
|
||||
@ -4390,7 +4393,7 @@ begin
|
||||
Message(W,evCommand,cmAddChar,pointer(ptrint(ord(Report^.AsciiChar))));
|
||||
ClearEvent(Event);
|
||||
end;
|
||||
|
||||
|
||||
cmSearchWindow+1..cmSearchWindow+99 :
|
||||
if (Event.Command-cmSearchWindow=Number) then
|
||||
ClearEvent(Event);
|
||||
|
Loading…
Reference in New Issue
Block a user