Skip to content

MTY_WideToMulti

chrisd1100 edited this page Aug 25, 2022 · 1 revision

Convert a wide character string to its UTF-8 equivalent.

bool MTY_WideToMulti(
    const wchar_t * src,
    char *          dst,
    size_t          size
);

Parameters

src (const wchar_t *)

Source wide character string.

dst (char *)

Destination UTF-8 string.

size (size_t)

Size in bytes of dst.

Return value

bool

Returns true on success, false on failure. Call MTY_GetLog for details.

Even if a proper UTF-8 conversion fails, this function attempts to fill dst with a best effort conversion.

Platform support

Windows   macOS   Android   Linux   Web  

See also

Module: Memory

Clone this wiki locally