Class UTryllTextProvider¶
ClassList > UTryllTextProvider
#include <TryllTextProvider.h>
Inherits the following classes: UObject
Inherited by the following classes: UTryllStringTableTextProvider
Public Functions¶
| Type | Name |
|---|---|
| FString | GetCurrentLocale () const |
| bool | GetText (FName Table, const FString & Id, FString & OutText) const |
| virtual bool | GetTextForPreview (FName Table, const FString & Id, const FString & Locale, FString & OutText) const |
| virtual void | InvalidatePreviewCache () |
| virtual TArray< FString > | ListIds (FName Table) const |
| virtual TArray< FString > | ListLocales () const |
| virtual bool | OpenInEditor (FName Table, const FString & Id, FString & OutMessage) const |
| virtual bool | SupportsEditorPreview () const |
Public Static Functions¶
| Type | Name |
|---|---|
| void | BroadcastLocaleChanged () |
| FString | CurrentProviderLocale () |
| UTryllTextProvider * | Get () |
| bool | LocaleForLanguageChange (bool bSessionLocaleExplicit, FString & OutLocale) |
| FSimpleMulticastDelegate & | OnLocaleChanged () |
| FString | ResolveSessionLocale () |
Detailed Description¶
Game-owned lookup for Text IDs on a workflow. Tryll does not own a string table. The class is chosen in Project Settings → Tryll Client → Text Provider. None means prompts stay inline and the Tryll Locale field is the session language.
Public Functions Documentation¶
function GetCurrentLocale¶
BCP-47 tag of the game's current language. Empty = unset.
function GetText¶
Text for Id in Table, in the provider's current language, after the provider's own fallback. False when the ID is unknown.
function GetTextForPreview¶
inline virtual bool UTryllTextProvider::GetTextForPreview (
FName Table,
const FString & Id,
const FString & Locale,
FString & OutText
) const
Exact locale, no fallback. False when that locale has no entry.
function InvalidatePreviewCache¶
Drop cached preview data (table edits, recompiled translations).
function ListIds¶
function ListLocales¶
function OpenInEditor¶
inline virtual bool UTryllTextProvider::OpenInEditor (
FName Table,
const FString & Id,
FString & OutMessage
) const
Jump to the table entry in the editor. False with OutMessage when the table has no editor.
function SupportsEditorPreview¶
Editor preview. The string-table provider supports it. A Blueprint-only provider returns false and the details panel shows no preview.
Public Static Functions Documentation¶
function BroadcastLocaleChanged¶
function CurrentProviderLocale¶
The provider's current language, or empty when no provider is set.
function Get¶
The instance from the project settings class, or null when the class is None.
function LocaleForLanguageChange¶
static bool UTryllTextProvider::LocaleForLanguageChange (
bool bSessionLocaleExplicit,
FString & OutLocale
)
Session language to send after a language change. False (send nothing) when there is no provider or CreateSession was given an explicit locale. An empty provider language falls back to UTryllRuntimeSettings::Locale, never "".
function OnLocaleChanged¶
Raised after the game's language changed. Game and editor subsystems both listen.
function ResolveSessionLocale¶
Session language for an empty CreateSession locale: the provider's current language when one is set, otherwise UTryllRuntimeSettings::Locale.
The documentation for this class was generated from the following file C:/_tryll/_monorepo3/tryll/clients/unreal/Source/TryllClient/Public/TryllTextProvider.h