TTF_SetTextPosition(3)

TTF_SetTextPosition3

Set the position of a text object.

Usage

#include "SDL3_ttf/SDL_ttf.h"

bool TTF_SetTextPosition(TTF_Text *text, int x, int y);

Header file

Defined in SDL3_ttf/SDL_ttf.h

Overview

This can be used to position multiple text objects within a single wrapping text area.

This function may cause the internal text representation to be rebuilt.

Function parameters

text

the TTF_Text
to modify.

x

the x offset of the upper left corner of this text in pixels.

y

the y offset of the upper left corner of this text in pixels.

Thread safety

This function should be called on the thread that created the text.

Availability

This function is available since SDL_ttf 3.0.0.

From libsdl3-ttf-doc 3.2.2+ds-1 in Debian 13 (Trixie). Parsed by carta from the page's man source.