sappend_UTF8¶
Category: string
GitHub: cute_string.h
Appends a UTF32 codepoint (as uint32_t
) encoded as UTF8 onto the string.
Parameters | Description |
---|---|
s | The string. Can be NULL . |
codepoint | An int codepoint in UTF32 form. |
Code Example¶
Example of suggested way to use this function within a loop.
Remarks¶
The UTF8 bytes are appended onto the string.
Each UTF32 codepoint represents a single character. Each character can be encoded from 1 to 4 bytes. Therefor, this function will push 1 to 4 bytes onto the string.
If an invalid codepoint is found the "replacement character" 0xFFFD will be appended instead, which looks like question mark inside of a dark diamond.