Skip to content

mdz_utf32_insertWchar_string_async

maxdz-gmbh edited this page Apr 29, 2021 · 5 revisions

Insert "wide"-characters string pWcharSource in string. Characters are converted to UTF-32 characters before isertion. Size grows on added UTF-32 characters count. Length grows on added symbols count.
String reserved area and pWcharSource->m_pData should not overlap.

mdz_bool mdz_utf32_insertWchar_string_async(
  struct mdz_Utf32* pUtf32,
  size_t nLeftPos,
  const void* pWcharSource,
  mdz_bool bReserve,
  struct mdz_asyncData* pAsyncData);

Synchronous version:
mdz_utf32_insertWchar_string(pUtf32, nLeftPos, pWcharSource, bReserve);

Parameter Description
pUtf32 pointer to string returned by mdz_utf32_create() or mdz_utf32_create_attached()
nLeftPos 0-based position to insert in symbols symbols. If nLeftPos == Length or -1, items are appended. nLeftPos > Length is not allowed
pWcharSource pointer to "wide"-characters string to insert. String is returned by mdz_wchar_create() or mdz_wchar_create_attached()
bReserve if mdz_true reserve capacity when there is not enough space for insertion, otherwise mdz_false
pAsyncData pointer to shared async data for asynchronous call, or NULL if call should be synchronous
Return Description
mdz_false if pUtf32 is NULL
mdz_false if bReserve == mdz_true and memory allocation failed (MDZ_ERROR_ALLOCATION)
mdz_false if bReserve == mdz_true and there is not enough capacity for inserted data, but m_pData is attached using mdz_utf32_attachData() (MDZ_ERROR_ATTACHED)
mdz_false if bReserve == mdz_false and there is not enough free Capacity in the string (MDZ_ERROR_CAPACITY)
mdz_false if string reserved area and pWcharSource->m_pData overlap (MDZ_ERROR_OVERLAP)
mdz_true if pWcharSource == NULL (MDZ_ERROR_SOURCE), or pWcharSource.Size == 0 (MDZ_ERROR_ZEROCOUNT), or nLeftPos > Length (MDZ_ERROR_BIGLEFT). No insertion is made
mdz_true insertion succeeded
mdz_utf32 API Reference is generated using mdzApiRefGenerator.

Init mdz_unicode library functions

mdz_utf8 functions

mdz_wchar functions

mdz_utf16 functions

mdz_utf32 functions

mdz_unicode API Reference is generated using mdzApiRefGenerator.
Clone this wiki locally