ttfSetTextWrapWidth function
Set whether wrapping is enabled on a text object.
\param text the TTF_Text to modify. \param wrap_width the maximum width in pixels, 0 to wrap on newline characters. \returns true on success or false on failure; call SDL_GetError() for more information.
\threadsafety This function should be called on the thread that created the text.
\since This function is available since SDL_ttf 3.0.0.
\sa TTF_GetTextWrapWidth
extern SDL_DECLSPEC bool SDLCALL TTF_SetTextWrapWidth(TTF_Text *text, int wrap_width)
Implementation
bool ttfSetTextWrapWidth(Pointer<TtfText> text, int wrapWidth) {
final ttfSetTextWrapWidthLookupFunction = libSdl3Ttf.lookupFunction<
Uint8 Function(Pointer<TtfText> text, Int32 wrapWidth),
int Function(
Pointer<TtfText> text, int wrapWidth)>('TTF_SetTextWrapWidth');
return ttfSetTextWrapWidthLookupFunction(text, wrapWidth) == 1;
}