Blender
V3.3
source
blender
blentranslation
BLT_lang.h
Go to the documentation of this file.
1
/* SPDX-License-Identifier: GPL-2.0-or-later
2
* Copyright 2011 Blender Foundation. All rights reserved. */
3
8
#pragma once
9
10
#ifdef __cplusplus
11
extern
"C"
{
12
#endif
13
14
/* Search the path directory to the locale files, this try all
15
* the case for Linux, Win and Mac.
16
* Also dynamically builds locales and locales' menu from "languages" text file.
17
*/
18
void
BLT_lang_init
(
void
);
19
20
/* Free languages and locales_menu arrays created by BLT_lang_init. */
21
void
BLT_lang_free
(
void
);
22
23
/* Set the current locale. */
24
void
BLT_lang_set
(
const
char
*);
25
/* Get the current locale ([partial] ISO code, e.g. es_ES). */
26
const
char
*
BLT_lang_get
(
void
);
27
28
/* Get locale's elements (if relevant pointer is not NULL and element actually exists, e.g.
29
* if there is no variant, *variant and *language_variant will always be NULL).
30
* Non-null elements are always MEM_mallocN'ed, it's the caller's responsibility to free them.
31
* NOTE: Always available, even in non-WITH_INTERNATIONAL builds.
32
*/
42
void
BLT_lang_locale_explode
(
const
char
*locale,
43
char
**language,
44
char
**country,
45
char
**variant,
46
char
**language_country,
47
char
**language_variant);
48
49
/* Get EnumPropertyItem's for translations menu. */
50
struct
EnumPropertyItem
*
BLT_lang_RNA_enum_properties
(
void
);
51
52
#ifdef __cplusplus
53
};
54
#endif
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.c:289
BLT_lang_get
const char * BLT_lang_get(void)
Definition:
blt_lang.c:269
BLT_lang_free
void BLT_lang_free(void)
Definition:
blt_lang.c:224
BLT_lang_RNA_enum_properties
struct EnumPropertyItem * BLT_lang_RNA_enum_properties(void)
Definition:
blt_lang.c:170
BLT_lang_init
void BLT_lang_init(void)
Definition:
blt_lang.c:179
BLT_lang_set
void BLT_lang_set(const char *)
Definition:
blt_lang.c:238
EnumPropertyItem
Definition:
RNA_types.h:452
Generated on Sat Jul 27 2024 14:57:55 for Blender by
doxygen
1.9.1