jvcllaz: Replace LineEndings in THMLParser demo by "paragraph mark" character.

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@6985 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
wp_xxyyzz
2019-05-31 14:42:26 +00:00
parent 1ab58715c4
commit 98332acbbc

View File

@ -193,15 +193,20 @@ begin
end;
end;
const
PARAGRAPH_MARK = #$E2#$81#$8B;
procedure TJvHTMLParserMainForm.TableKeyFound(Sender: TObject; Key, Results,
OriginalLine: string);
begin
Self.Tag := Self.Tag + 1;
DisplayMemo1.Lines.Add(Key + #13#10 + Results);
DisplayMemo1.Lines.Add(Key + LineEnding + Results);
if UpperCase(Key) = 'TR' then
CurNode := TreeView1.Items.AddChild(nil, 'TR')
else
else begin
Results := StringReplace(Results, LineEnding, PARAGRAPH_MARK, [rfReplaceAll]);
TreeView1.Items.AddChild(CurNode, Results);
end;
end;
procedure TJvHTMLParserMainForm.TableKeyFoundEx(Sender: TObject;
@ -211,13 +216,15 @@ var
i : integer;
begin
Self.Tag := Self.Tag + 1;
DisplayMemo1.Lines.Add(Key + #13#10 + Results);
DisplayMemo1.Lines.Add(Key + LineEnding + Results);
for i:=0 to Attributes.Count-1 do
DisplayMemo1.Lines.Add('Attributes=' + Attributes[i]);
if UpperCase(Key) = 'TR' then
CurNode := TreeView1.Items.AddChild(nil, 'TR')
else
else begin
Results := StringReplace(Results, LineEnding, PARAGRAPH_MARK, [rfReplaceAll]);
TreeView1.Items.AddChild(CurNode, Results);
end;
end;
procedure TJvHTMLParserMainForm.HTML2TextKeyFound(Sender: TObject; Key, Results,