Blender
V4.3
source
blender
blentranslation
BLT_lang.hh
Go to the documentation of this file.
1
/* SPDX-FileCopyrightText: 2011 Blender Authors
2
*
3
* SPDX-License-Identifier: GPL-2.0-or-later */
4
9
#pragma once
10
11
struct
EnumPropertyItem
;
12
13
/* Search the path directory to the locale files, this try all
14
* the case for Linux, Win and Mac.
15
* Also dynamically builds locales and locales' menu from "languages" text file.
16
*/
17
void
BLT_lang_init
();
18
19
/* Free languages and locales_menu arrays created by BLT_lang_init. */
20
void
BLT_lang_free
();
21
22
/* Set the current locale. */
23
void
BLT_lang_set
(
const
char
*);
24
/* Get the current locale ([partial] ISO code, e.g. `pt_BR`). */
25
const
char
*
BLT_lang_get
();
26
27
/* Get locale's elements (if relevant pointer is not NULL and element actually exists, e.g.
28
* if there is no variant, *variant and *language_variant will always be NULL).
29
* Non-null elements are always MEM_mallocN'ed, it's the caller's responsibility to free them.
30
* NOTE: Always available, even in non-WITH_INTERNATIONAL builds.
31
*/
41
void
BLT_lang_locale_explode
(
const
char
*locale,
42
char
**language,
43
char
**country,
44
char
**variant,
45
char
**language_country,
46
char
**language_variant);
47
48
/* Get EnumPropertyItem's for translations menu. */
49
const
EnumPropertyItem
*
BLT_lang_RNA_enum_properties
();
BLT_lang_locale_explode
void BLT_lang_locale_explode(const char *locale, char **language, char **country, char **variant, char **language_country, char **language_variant)
Definition
blt_lang.cc:301
BLT_lang_get
const char * BLT_lang_get()
Definition
blt_lang.cc:281
BLT_lang_RNA_enum_properties
const EnumPropertyItem * BLT_lang_RNA_enum_properties()
Definition
blt_lang.cc:173
BLT_lang_set
void BLT_lang_set(const char *)
Definition
blt_lang.cc:251
BLT_lang_init
void BLT_lang_init()
Definition
blt_lang.cc:182
BLT_lang_free
void BLT_lang_free()
Definition
blt_lang.cc:227
EnumPropertyItem
Definition
RNA_types.hh:497
Generated on Thu Feb 6 2025 07:36:39 for Blender by
doxygen
1.11.0