al_ustr_insert_chr(3alleg5)

πŸ“¦
version 5.2.11.3 Β· 4 versions
, in debian trixie, ubuntu questing, ubuntu resolute, ubuntu stonking

✨ al_ustr_insert_chr β€” Allegro 5 API ✨

okay bestie, sit down, hydrate, and let me tell you about al_ustr_insert_chr from the Allegro 5 API πŸ’– this is a <3alleg5> manual page and honestly? she's a little icon. πŸŽ€


🌸 SYNOPSIS 🌸

#include <allegro5/allegro.h>

size_t al_ustr_insert_chr(ALLEGRO_USTR *us, int pos, int32_t c)

πŸ¦‹ DESCRIPTION πŸ¦‹

So the whole vibe here is: we're slipping one single code point into us, and it starts landing at the byte offset pos. πŸ’…

  • pos literally cannot be less than 0. Not negotiable, not even a little. πŸ™…β€β™€οΈ
  • and if pos is past the end of us? then the gap between where the string ends and where pos is gets padded with NUL ('\0') bytes. yes fr fr, she just fills the empty space with NULs like it's nothing. πŸ’€

Returns the number of bytes inserted β€” or 0 on error. 🫢


πŸ‘‘ SEE ALSO πŸ‘‘

  • al_ustr_insert(3alleg5)
  • al_ustr_insert_cstr(3alleg5)

and that's the whole page, bestie, you ate it. πŸ“ no cap. this was the Allegro reference manual, and the header up top was al_ustr_insert_chr(3alleg5) in case you forgot where you were. go forth and insert those code points responsibly, mwah πŸ’–βœ¨πŸ§š

πŸ“¦ where this page comes from