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
Incorporating RVF into an XML file
-
- Site Admin
- Posts: 17557
- Joined: Sat Aug 27, 2005 10:28 am
- Contact:
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.
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.