Page 1 of 1

Insert RTF from stream without line break

Posted: Sun Feb 07, 2021 5:07 pm
by mikesm
Hello,
how do i insert rich text into richviewedit without inserting a new line at the end of the text. I use the InsertRTFFromStreamEd function, there is a new line after the inserted content.
Thanks

Re: Insert RTF from stream without line break

Posted: Mon Mar 28, 2022 4:37 am
by DannyLe
Hi,
Has there been any updates regrading this post? I believe I am running into the same issue.
Thank you

Re: Insert RTF from stream without line break

Posted: Mon Mar 28, 2022 8:07 am
by Sergey Tkachenko
Current behavior: insert the ending line break when inserting RTF as an editing operation; ignore it overwise.
It is hard-coded.
If you want to change it, modify the line in RVRTFProps.pas:
from

Code: Select all

    TRVRTFReader(Reader).ProcessFinalPar := EditFlag;
to

Code: Select all

    TRVRTFReader(Reader).ProcessFinalPar := False;