IText provides simple conversion operators
that can convert character data in an IText object into a
null-terminated char array or an IString object. The
text is transcoded from Unicode data into char data. The framework assumes that you want the char
data to be encoded in the default encoding system for the current
host.
IText unicodeString("Hello World!");
const char* charData;
charData = unicodeString;
IText unicodeString("Hello World!");
char* modifiableCharData = new char[unicodeString.length()];
strcpy(modifiableCharData, unicodeString);
// Can modify the char data without affecting the underyling
IText storage
modifiableCharData[0] = `J';
const char* moreCharData;
// The underlying IText still contains "Hello World!"
moreCharData = unicodeString;