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

# SDL\_HINT\_PREFERRED\_LOCALES(3)

Override for SDL\_GetPreferredLocales ().

## NAME

SDL\_HINT\_PREFERRED\_LOCALES - Override for  **SDL\_GetPreferredLocales** ().

## HEADER FILE

Defined in SDL3/SDL\_hints.h

## SYNOPSIS

```
#include "SDL3/SDL.h"
```

**#define SDL\_HINT\_PREFERRED\_LOCALES** *SDL\_PREFERRED\_LOCALES"*

## DESCRIPTION

If set, this will be favored over anything the OS might report for the user's preferred locales. Changing this hint at runtime will not generate a

**SDL\_EVENT\_LOCALE\_CHANGED**\
  event (but if you can change the hint, you can push your own event, if you want).

The format of this hint is a comma-separated list of language and locale, combined with an underscore, as is a common format: "en\_GB". Locale is optional: "en". So you might have a list like this: "en\_GB,jp,es\_PT"

This hint can be set anytime.

## AVAILABILITY

This hint is available since SDL 3.2.0.
