---
name: "TTF_SetFontHinting"
section: "3"
platform: "linux"
package: "libsdl3-ttf-doc"
version: "3.2.2+ds-1"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/TTF_SetFontHinting"
---

# TTF\_SetFontHinting(3)

Set a font's current hinter setting.

## NAME

TTF\_SetFontHinting - Set a font's current hinter setting.

## HEADER FILE

Defined in SDL3\_ttf/SDL\_ttf.h

## SYNOPSIS

```
#include "SDL3_ttf/SDL_ttf.h"
```

**void TTF\_SetFontHinting(TTF\_Font \*font, TTF\_HintingFlags hinting);**

## DESCRIPTION

This updates any  **TTF\_Text**\
  objects using this font, and clears already-generated glyphs, if any, from the cache.

The hinter setting is a single value:

•  **TTF\_HINTING\_NORMAL**

•  **TTF\_HINTING\_LIGHT**

•  **TTF\_HINTING\_MONO**

•  **TTF\_HINTING\_NONE**

•  **TTF\_HINTING\_LIGHT\_SUBPIXEL** (available in\
   SDL\_ttf 3.0.0 and later)

## FUNCTION PARAMETERS

- *font*

  the font to set a new hinter setting on.

- *hinting*

  the new hinter setting.

## THREAD SAFETY

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

## AVAILABILITY

This function is available since SDL\_ttf 3.0.0.

## SEE ALSO

**•**(3), [**TTF\_GetFontHinting**(3)](/TTF_GetFontHinting/3.md)
