1uszprintf(3)                    Allegro manual                    uszprintf(3)
2
3
4

NAME

6       uszprintf - Writes formatted data into a buffer, specifying size. Alle‐
7       gro game programming library.
8

SYNOPSIS

10       #include <allegro.h>
11
12
13       int uszprintf(char *buf, int size, const char *format, ...);
14

DESCRIPTION

16       This function writes formatted  data  into  the  output  buffer,  whose
17       length  in  bytes  is specified by `size' and which is guaranteed to be
18       NULL terminated. Example:
19
20          char buffer[10];
21          int player_score;
22          ...
23          uszprintf(buffer, sizeof(buffer), "Your score is: %d", player_score);
24

RETURN VALUE

26       Returns the number of characters that would have been  written  without
27       eventual truncation (like with usprintf), not including the terminating
28       null character.
29
30

SEE ALSO

32       uconvert(3), usprintf(3), uvszprintf(3), exgui(3)
33
34
35
36Allegro                          version 4.4.3                    uszprintf(3)
Impressum