Skip to content

Widechar_to_UTF8_Ex

Widechar_to_UTF8 converts a UCS2 string into UTF-8

Prototype

void Widechar_to_UTF8_Ex(
    const IGR_UCS2* source,
    IGR_LONG sourceLen,
    char* buffer,
    IGR_LONG bufferSize
)

Parameters

source: Pointer to IGR_UCS2

Contains a NULL terminated UCS2 string.

sourceLen: IGR_LONG

Indicate the size of the buffer pointed to by source, in bytes.

buffer: Pointer to char

Pointer to a buffer that will hold the converted text.

bufferSize: IGR_LONG

Indicates the size of the buffer, the system will copy up to this size including the NULL.

Return value

Success: IGR_LONG

Returns IGR_OK.

Failure: IGR_LONG

Returns one of the possible IGR_E error codes.