Home |
Function RTFSetDefaultOpenFlags Function RTFSetCriticalErrorHandler Function RTFDefaultCriticalErrorHandler Function RTFSetCodePage |
Function RTFSetCodePageRTFSetCodePage can be used to supply translation tables for file names passed to and returned from RTFiles-32. If the function is never called, OEM code page 437 is assumed by default. void RTFSetCodePage(UINT CodePage, const wchar_t * Unicode, const char * UpperCase); ParametersCodePageNumeric name of the code page. UnicodePointer to an array of exactly 128 WORD values. This array must contain the Unicode translations of the 8-bit ASCII values in range 128..255. RTFiles-32 will translate ASCII character values above 127 to Unicode with: Unicode[(BYTE) c - 128]. UpperCasePointer to an array of exactly 128 char values. This array must contain the upper case repesentation of each 8-bit ASCII value in range 128..255. If there is no upper case translation for a character, the character itself should appear at its corresponding index. The translation tables installed through this function have no effect on how file names are stored on disk. On disk, short names are always stored using code page 437 while long file names are stored in Unicode. Merely file names used in the RTFiles-32 API and all higher level APIs (Win32, C/C++ run-time system) are affected. Through RTFSetCodePage, RTFiles-32 can support any ASCII code page. Function RTFSetCodePageOEM, and RTFSetCodePageANSI call RTFSetCodePage internally for code pages 437 and 1252, respectively. To use UTF-8 encoding, use function RTFSetCodePageUTF8. Function RTFDefaultCriticalErrorHandler
|