logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

textout_centre_ex - Writes a centered string on a bitmap. Allegro game programming library.

Description

       Like textout_ex(), but interprets the x coordinate as the centre rather than the left edge of the string.
       Example:

          /* Important texts go in the middle. */
          width = text_length("GAME OVER");
          textout_centre_ex(screen, font, "GAME OVER",
                            SCREEN_W / 2, SCREEN_H / 2,
                            makecol(255, 0, 0), makecol(0, 0, 0));

Name

       textout_centre_ex - Writes a centered string on a bitmap. Allegro game programming library.

See Also

textout_ex(3alleg4), textprintf_centre_ex(3alleg4)

Allegro                                           version 4.4.3                       textout_centre_ex(3alleg4)

Synopsis

#include<allegro.h>voidtextout_centre_ex(BITMAP*bmp,constFONT*f,constchar*s,intx,y,intcolor,intbg);

See Also