FabGL2 2.0.0
ESP32 Display Controller and Graphics Library for ESP-IDF
Loading...
Searching...
No Matches

◆ drawText() [2/2]

void drawText ( int X,
int Y,
char const * text,
bool wrap = false )

Draws a string at the specified position.

drawText() uses the font selected with selectFont() and the glyph options set with setGlyphOptions().

Parameters
XHorizontal position of the left side of the first character.
YVertical position of the top side of the first character.
textString to draw (indexes into the font glyph set).
wrapIf true, text wraps at the end of the line.

Example:

// Draw a 'Hello World!' at position 100, 100
Canvas.drawText(100, 100, "Hello World!");

Definition at line 401 of file canvas.cpp.