Page 1 of 1

Copy to Clipboard kills last tabulator

Posted: Thu Jan 11, 2007 6:10 pm
by Kern
I have a TRichViewEdit with a TAB set for example at 4 cm and containing the following text

a<TAB>b
c<TAB>d
e<TAB>f

If I select this text, copy it to Clipboart (TrichViewEdit.Copy) and then paste it in WinWord the tabwidth of the first 2 lines is correct but the last line contains no TAB and uses the standard tabwidth.
This appears also at the last line of a text with less or more lines.

Is this a bug in TCustomRVData.SaveRTFToStream?

Thanks
Patrik

Posted: Fri Jan 12, 2007 6:45 am
by Sergey Tkachenko
This problem must be fixed in the latest TRichView version

Posted: Fri Jan 12, 2007 9:52 am
by Kern
Sergey Tkachenko wrote:This problem must be fixed in the latest TRichView version
Hi Sergey

What do you mean with
must be fixed
? Whe have the last version (1.9.24) and the problem is still there. Do you have a solution meanwhile?

Thanks
Patrik

Posted: Fri Jan 12, 2007 10:58 am
by Sergey Tkachenko
It is fixed in newer version (available for registered users). This new version is still beta and cannot be used for compiling release versions of applications.
Quick fix:
CRVData.pas, find the line

Code: Select all

    if (Level=0) and (StartItem<>EndItem) and IsParaStart(EndItem) and (GetItemStyle(EndItem)>=0) and (Items[EndItem]='') then
and change it to

Code: Select all

    if (Level=0) then