.\" Automatically generated by Pandoc 3.6.1 .\" .TH "al_ustr_set_chr" "3" "" "Allegro reference manual" .SH NAME al_ustr_set_chr \- Allegro 5 API .SH SYNOPSIS .IP .EX #include \f[B]\f[R] size_t al_ustr_set_chr(ALLEGRO_USTR *us, int start_pos, int32_t c) .EE .SH DESCRIPTION Replace the code point beginning at byte offset \f[CR]start_pos\f[R] with \f[CR]c\f[R]. \f[CR]start_pos\f[R] cannot be less than 0. If \f[CR]start_pos\f[R] is past the end of \f[CR]us\f[R] then the space between the end of the string and \f[CR]start_pos\f[R] will be padded with NUL (\f[CR]\[aq]\[rs]0\[aq]\f[R]) bytes. If \f[CR]start_pos\f[R] is not the start of a valid code point, that is an error and the string will be unmodified. .PP On success, returns the number of bytes written, i.e.\ the offset to the following code point. On error, returns 0. .SH SEE ALSO al_ustr_replace_range(3)