TTF_GetFontSize(3)

πŸ’– NAME πŸ’–

TTF_GetFontSize β€” bestie, this one gets the size of a font. That's it. That's the whole job. πŸŽ€


✨ HEADER FILE ✨

Defined in SDL3_ttf/SDL_ttf.h β€” go say hi to it there, iykyk. πŸ¦‹

🌸 SYNOPSIS 🌸

#include "SDL3_ttf/SDL_ttf.h"

float TTF_GetFontSize(TTF_Font *font);

okay so it's literally one line and it returns a float. no cap. πŸ’…


🫢 FUNCTION PARAMETERS 🫢

  • font β€” the font you're trying to interrogate. the one you want the size of. that font. her. πŸ‘‘

😭 RETURN VALUE 😭

Returns the size of the font. and if it's giving nothing, you get 0.0f on failure. when that happens, call SDL_GetError() for more information β€” she will tell you what went wrong, fr fr. πŸ’€

πŸ”₯ THREAD SAFETY πŸ”₯

This function should be called on the thread that created the font. not a different thread. not your friend's thread. the same one. periodt. ⭐

🌈 AVAILABILITY 🌈

This function is available since SDL_ttf 3.0.0. so it's been iconic for a minute. ✨

πŸ‘‘ SEE ALSO πŸ‘‘

go read those next, bestie, they're the sibling functions and they ate. 🧚


and that's the whole page!! mwah πŸ’œ β€” written under the SDL_ttf era, version SDL_ttf 3.2.2, and yes this page is literally named TTF_GetFontSize(3). slay, bye!! πŸ“

πŸ“¦ where this page comes from