Hyperlink support in paste

General TRichView support forum. Please post your questions here
Post Reply
martindholmes
Posts: 131
Joined: Mon Aug 29, 2005 12:03 pm

Hyperlink support in paste

Post by martindholmes »

Hi there,

I'm trying to figure out how I can preserve hyperlinks (meaning their href attribute) when a user is copy/pasting from another application such as a browser. I see how I can use OnReadHyperlink to process the url and other data in a link loaded from RTF, but is there a similar way to handle text which is pasted?

Cheers,
Martin
Sergey Tkachenko
Site Admin
Posts: 17559
Joined: Sat Aug 27, 2005 10:28 am
Contact:

Post by Sergey Tkachenko »

OnReadHyperlink is called in all cases: when reading, pasting or inserting RTF (And, by default, data from browser are copy-pasted in RTF format).

If you use RvHtmlImporter, hyperlinks are processed automatically (written in tags), if rvhtmloAutoHyperlinks is included in RvHtmlImporter.Options (default).
If not included, TRichView.OnReadHyperlink is used, just like for RTF.
Post Reply