Macaw OS C reference

Function centertext

#include <macaw.h>
void centertext(const char *s, int x, int y, int colour);

Writes text centred on a point across, for titles and buttons.

Parameters

sconst char *
The text to write.
xint
Where the middle of the text goes, in pixels from the window's left edge.
yint
How far the text's top is from the window's top, in pixels.
colourint
The text's colour, from 0 to 255.

In Drawing, with cls, pset, pget, line, rect, rectfill, circ, circfill, tri, text, textwidth, clip, noclip, camera, box, shadowtext, textscaled, wraptext, wrapline.