procedure TForm1.WPRichText1KeyDown(Sender: TObject; var Key: Word;
Shift: TShiftState);
begin
if Key=VK_RETURN then
begin
WPRichText1.InputString(#10);
Key := 0;
end;
end;
procedure TForm1.WPKeyPress(Sender: TObject; var Key: Char);
begin
if Key = #13 then
Key := #10;
end;
I can see that it captures the #13 and converts it to #10, but WP still treats it as a hard line break, creating new paragraphs instead of continuing the text within the same paragraph.