Navigation
API > API/Runtime > API/Runtime/Core > API/Runtime/Core/Internationalization
References
| Module | Core |
| Header | /Engine/Source/Runtime/Core/Public/Internationalization/TextLocalizationManager.h |
| Include | #include "Internationalization/TextLocalizationManager.h" |
Syntax
class FTextLocalizationManager
Remarks
Singleton class that manages display strings for FText.
Variables
| Type | Name | Description | |
|---|---|---|---|
| FTextLocalizationManager::FTextRevisionChangedEvent | OnTextRevisionChangedEvent |
Constructors
| Type | Name | Description | |
|---|---|---|---|
FTextLocalizationManager
(
const FTextLocalizationManager& |
Destructors
| Type | Name | Description | |
|---|---|---|---|
Functions
| Type | Name | Description | |
|---|---|---|---|
| void | |||
| void | ConfigureGameLocalizationPreviewLanguage
(
const FString& CultureName |
Configure the "preview language" setting used for the game localization preview. | |
| void | Disable the game localization preview. | ||
| void | |||
| void | EnableGameLocalizationPreview
(
const FString& CultureName |
Enable the game localization preview using the given language, or the native language if the culture name is empty. | |
| void | Enable the game localization preview using the current "preview language" setting, or the native culture if no "preview language" is set. | ||
| FTextConstDisplayStringPtr | FindDisplayString
(
const FTextKey& Namespace, |
Finds and returns the display string with the given namespace and key, if it exists. | |
| FTextLocalizationManager & | Get () |
Singleton accessor | |
| FString | Get the configured "preview language" setting used for the game localization preview (if any). | ||
| FTextConstDisplayStringPtr | GetDisplayString
(
const FTextKey& Namespace, |
Get the current display string for the given namespace and key, if any. | |
| int32 | GetLocalizationTargetPathId
(
FStringView InLocalizationTargetPath |
Given a localization target path, get the ID associated with it. | |
| TArray< FString > | GetLocalizedCultureNames
(
const ELocalizationLoadFlags InLoadFlags |
Get a list of culture names that we have localized resource data for (ELocalizationLoadFlags controls which resources should be checked). | |
| uint16 | GetLocalRevisionForTextId
(
const FTextId& InTextId |
Attempts to find a local revision history for the given text ID. | |
| bool | GetLocResID
(
const FTextKey& Namespace, |
If an entry exists for the specified namespace and key, returns true and provides the localization resource identifier from which it was loaded. | |
| FString | GetNativeCultureName
(
const ELocalizedTextSourceCategory InCategory |
Given a localization category, get the native culture for the category (if known). | |
| FString | Get the language that will be requested during localization initialization, based on the hierarchy of: command line -> configs -> OS default. | ||
| FString | Get the locale that will be requested during localization initialization, based on the hierarchy of: command line -> configs -> OS default. | ||
| uint16 | Returns the current text revision number. | ||
| void | GetTextRevisions
(
const FTextId& InTextId, |
Get both the global and local revision for the given text ID. | |
| void | HandleLocalizationTargetsMounted
(
TArrayView< const FString > LocalizationTargetPaths |
Called when paths containing additional localization target data (LocRes) are mounted, to allow the display strings to dynamically update without waiting for a refresh. | |
| void | HandleLocalizationTargetsUnmounted
(
TArrayView< const FString > LocalizationTargetPaths |
Called when paths containing additional localization target data (LocRes) are unmounted, to allow the display strings to be unloaded. | |
| bool | |||
| bool | Is the game localization preview enabled for a non-native language? | ||
| bool | Is the localization of this game currently locked? (ie, can it be edited in the UI?). | ||
| void | Notify that the game localization preview should no longer automatically enable itself under certain circumstances (such as changing the preview language via the UI) due to a state change (such as PIE ending). | ||
| void | Notify that the game localization preview should automatically enable itself under certain circumstances (such as changing the preview language via the UI) due to a state change (such as PIE starting). | ||
| void | Reloads resources for the current culture. The loading is async, see WaitUntilLoadingCompletes. | ||
| void | RegisterPolyglotTextData
(
const FPolyglotTextData& InPolyglotTextData, |
Register a polyglot text data with the text localization manager. | |
| void | RegisterPolyglotTextData
(
TArrayView< const FPolyglotTextData > InPolyglotTextDataArray, |
||
| void | RegisterTextSource
(
const TSharedRef< ILocalizedTextSource >& InLocalizedTextSource, |
Register a localized text source with the text localization manager. | |
| bool | True if we should force load game localization data. | ||
| bool | Should the game localization preview automatically enable itself under certain circumstances? | ||
| void | TearDown () |
||
| void | UpdateFromLocalizationResource
(
const FString& LocalizationResourceFilePath |
Updates display string entries and adds new display string entries based on localizations found in a specified localization resource. | |
| void | UpdateFromLocalizationResource
(
const FTextLocalizationResource& TextLocalizationResource |
||
| void | Wait for any current async tasks to finish. |
Operators
| Type | Name | Description | |
|---|---|---|---|
| FTextLocalizationManager & | operator=
(
const FTextLocalizationManager& |
||
| FTextLocalizationManager & |
Classes
| Type | Name | Description | |
|---|---|---|---|
| FTextRevisionChangedEvent | Event type for immediately reacting to changes in display strings for text. |
Typedefs
| Name | Description |
|---|---|
| FDisplayStringLookupTable | Manages the currently loaded or registered text localizations. |