I'm using SelectCurrentLine to copy out some text from a RVF document.
However, if that line has different formatting like Regular font and then italics it only selects up until that change in formatting.
Is this an expected behavior? Is there a way to change this. In this application the format could be different on a per character basis.
Do I need to change anything in RichViewEdit to fix this? Thank you.
This is quite easy to test write a line of text with various formattings in RVF then call SelectCurrentLine and then update/refresh the RVF and you should be able to see this.
TCustomRichViewEdit.SelectCurrentLine
-
- Site Admin
- Posts: 17566
- Joined: Sat Aug 27, 2005 10:28 am
- Contact:
Re: TCustomRichViewEdit.SelectCurrentLine
Please give me step-by-step instructions how to reproduce this problem.
I tried to call RichViewEdit1.SelectCurrentLine in the ActionTest project. It selected the whole line, including bold and italic words.
I tried to call RichViewEdit1.SelectCurrentLine in the ActionTest project. It selected the whole line, including bold and italic words.
Re: TCustomRichViewEdit.SelectCurrentLine
To work around it I had to turn word wrap off reformat and then it works. Maybe try a different font and or color. I was trying several things. Im working with a .docs converted to rtf then loaded into Trichview. (So one of these steps could mess something up or maybe a setting) Sorry I cant share the document it is copyrighted.
-
- Site Admin
- Posts: 17566
- Joined: Sat Aug 27, 2005 10:28 am
- Contact:
Re: TCustomRichViewEdit.SelectCurrentLine
Maybe you can reproduce it in a small document, with only several lines of non-copyrighted text?
Because in my tests everything works as expected.
Because in my tests everything works as expected.
Re: TCustomRichViewEdit.SelectCurrentLine
It is odd, My guess is the document has bad rtf somehow.
I tried just editing down the document to a problem portion. First using WordPad, then MS Word and then RVF Demo App. But this fixes it. As best I could tell maybe some bad bookmark, or footnote links that were leftover in the RTF code.
I did find a work around via turning off WordWrap then Format when I needed to grab just that portion for converting to another format.
Thanks for the help.
I tried just editing down the document to a problem portion. First using WordPad, then MS Word and then RVF Demo App. But this fixes it. As best I could tell maybe some bad bookmark, or footnote links that were leftover in the RTF code.
I did find a work around via turning off WordWrap then Format when I needed to grab just that portion for converting to another format.
Thanks for the help.