Incorporating RVF into an XML file

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

Incorporating RVF into an XML file

Post by martindholmes »

I've found myself in a situation where I need to save RVF code (text, not binary) to an XML file which is encoded in UTF-8. I'm wondering what the nature of RVF code is. As a string, is it ASCII or ANSI? In other words, does it ever contain characters between 128 and 255?

The TRichViewEdit which is the source of the RVF code is using Unicode, and all styles are Unicode.

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

Post by Sergey Tkachenko »

Normally, RVF may use characters between 128 and 255, even in text mode (rvfoSaveBinary is excluded from RVFOptions).
But if all text is Unicode, it will be stored as hexadecimal string, all character codes < 128.
So the only places where characters with codes >= 128 may still occur are:
- tags, if rvoTagsArePChars is in options; but usually tags are used to store hypertext targets, with all character codes < 128
- names of non-text items (usually empty)
- names of checkpoints.
Post Reply