Man page - ttf_wasinit(3)

Packages contains this manual

Manual

TTF_WasInit

NAME
HEADER FILE
SYNOPSIS
DESCRIPTION
RETURN VALUE
THREAD SAFETY
AVAILABILITY
SEE ALSO

NAME

TTF_WasInit - Check if SDL_ttf is initialized.

HEADER FILE

Defined in SDL3_ttf/SDL_ttf.h

SYNOPSIS

#include "SDL3_ttf/SDL_ttf.h"

int TTF_WasInit(void);

DESCRIPTION

This reports the number of times the library has been initialized by a call to TTF_Init (), without a paired deinitialization request from

TTF_Quit ().

In short: if it’s greater than zero, the library is currently initialized and ready to work. If zero, it is not initialized.

Despite the return value being a signed integer, this function should not return a negative number.

RETURN VALUE

Returns the current number of initialization calls, that need to eventually be paired with this many calls to TTF_Quit ().

THREAD SAFETY

It is safe to call this function from any thread.

AVAILABILITY

This function is available since SDL_ttf 3.0.0.

SEE ALSO

β€’ (3), TTF_Init (3), β€’ (3), TTF_Quit (3)