|
Muteki
EABI code execution on Besta® RTOS devices.
|
UTF-16 conversion utilities. More...
#include "common.h"Go to the source code of this file.
Typedefs | |
| typedef enum utf16_mb_encoding_e | utf16_mb_encoding_e |
| Supported encoding types. | |
Enumerations | |
| enum | utf16_mb_encoding_e { UTF16_MB_ENCODING_CP936 = 0x0001 , UTF16_MB_ENCODING_CP950 = 0x0002 , UTF16_MB_ENCODING_CP932 = 0x0004 , UTF16_MB_ENCODING_CP949 = 0x0008 , UTF16_MB_ENCODING_CP874 = 0x0010 , UTF16_MB_ENCODING_CP1252 = 0x1000 , UTF16_MB_ENCODING_UTF8 = 0x7fff , UTF16_MB_ENCODING_UTF16 = 0x8000 , UTF16_MB_ENCODING_DEFAULT = 0xffff } |
| Supported encoding types. More... | |
Functions | |
| UTF16 | ConvCharToUnicode (unsigned int src, unsigned short src_encoding) |
| Convert a multi-byte codepoint to UTF-16. | |
| UTF16 * | ConvStrToUnicode (const void *src, UTF16 *dst, unsigned short src_encoding) |
| Convert a multi-byte string to UTF-16. | |
UTF-16 conversion utilities.
Provides utility functions to convert strings of various types of encoding to UTF-16.
| enum utf16_mb_encoding_e |
Supported encoding types.
| Enumerator | |
|---|---|
| UTF16_MB_ENCODING_CP936 | Use CP936 (GB18030-based). Supported by both ConvStrToUnicode() and ConvCharToUnicode(). |
| UTF16_MB_ENCODING_CP950 | Use CP950 (BIG5-based). Supported by both ConvStrToUnicode() and ConvCharToUnicode(). |
| UTF16_MB_ENCODING_CP932 | Use CP932 (Shift-JIS-based). Supported by both ConvStrToUnicode() and ConvCharToUnicode(). |
| UTF16_MB_ENCODING_CP949 | Use CP949 (EUC-KR-based). Supported by both ConvStrToUnicode() and ConvCharToUnicode(). |
| UTF16_MB_ENCODING_CP874 | Use CP874 (TIS-620-based). Supported by ConvStrToUnicode() only. |
| UTF16_MB_ENCODING_CP1252 | Use CP1252 (ISO8859-1-based). Supported by ConvStrToUnicode() only.
|
| UTF16_MB_ENCODING_UTF8 | Use UTF-8. Supported by ConvStrToUnicode() only. |
| UTF16_MB_ENCODING_UTF16 | Use UTF-16. Supported by both ConvStrToUnicode() and ConvCharToUnicode(). |
| UTF16_MB_ENCODING_DEFAULT | Use default encoding. On BA742 this is hardcoded to be CP936. Supported by both ConvStrToUnicode() and ConvCharToUnicode(). |
|
extern |
Convert a multi-byte codepoint to UTF-16.
| src | Multi-byte codepoint. |
| src_encoding | Encoding type of the input codepoint. |
Convert a multi-byte string to UTF-16.
| [in] | src | Source multi-byte string. |
| [out] | dst | Converted UTF-16 string. |
| src_encoding | Encoding type of the input codepoint. |