TranslationServerSingleton

Server that manages all translations.

Translations can be set to it and removed from it.

Members

Aliases

BaseClasses
alias BaseClasses = AliasSeq!(typeof(_GODOT_base), typeof(_GODOT_base).BaseClasses)
Undocumented in source.

Functions

addTranslation
void addTranslation(Translation translation)

Adds a Translation resource.

clear
void clear()

Clears the server from all translations.

getLoadedLocales
Array getLoadedLocales()

Returns an Array of all loaded locales of the game.

getLocale
String getLocale()

Returns the current locale of the game.

getLocaleName
String getLocaleName(String locale)

Returns a locale's language and its variant (e.g. "en_US" would return "English (United States)").

opAssign
typeof(null) opAssign(typeof(null) n)
opEquals
bool opEquals(TranslationServerSingleton other)
opEquals
bool opEquals(typeof(null) n)
removeTranslation
void removeTranslation(Translation translation)

Removes the given translation from the server.

setLocale
void setLocale(String locale)

Sets the locale of the game.

toHash
size_t toHash()
translate
String translate(String message)

Returns the current locale's translation for the given message (key).

Mixins

__anonymous
mixin baseCasts
Undocumented in source.

Static functions

_new
TranslationServerSingleton _new()

Construct a new instance of TranslationServerSingleton. Note: use memnew!TranslationServerSingleton instead.

Static variables

_classBindingInitialized
bool _classBindingInitialized;
Undocumented in source.

Structs

GDNativeClassBinding
struct GDNativeClassBinding
Undocumented in source.

Unions

__anonymous
union __anonymous
Undocumented in source.

Variables

_GODOT_internal_name
enum string _GODOT_internal_name;
Undocumented in source.

Mixed In Members

From mixin baseCasts

as
inout(To) as()
Undocumented in source. Be warned that the author may not have intended to support it.
as
inout(To) as()
Undocumented in source. Be warned that the author may not have intended to support it.
as
inout(ToRef) as()
Undocumented in source. Be warned that the author may not have intended to support it.
opCast
template opCast(To)
Undocumented in source.
opCast
template opCast(To)
Undocumented in source.
opCast
template opCast(ToRef)
Undocumented in source.
opCast
void* opCast()
Undocumented in source. Be warned that the author may not have intended to support it.
opCast
godot_object opCast()
Undocumented in source. Be warned that the author may not have intended to support it.
opCast
bool opCast()
Undocumented in source. Be warned that the author may not have intended to support it.

Meta