PropertyNameLocalizationPaths
PropertyNameLocalizationPaths
#Overview
name: PropertyNameLocalizationPaths
The value of this variable can be defined or overridden in .ini config files. 1
.ini config file referencing this setting variable.
It is referenced in 3
C++ source files.
#Summary
#Usage in the C++ source code
The purpose of PropertyNameLocalizationPaths is to specify the file system paths where property name localization data is stored in Unreal Engine 5. This setting is crucial for the internationalization and localization system of the engine.
This setting variable is primarily used by the Localization Dashboard module in the Editor and the Core module of Unreal Engine. It’s particularly relevant for the internationalization subsystem.
The value of this variable is set in two ways:
- Primarily, it’s read from the GEditorIni configuration file under the “Internationalization” section with the key “PropertyNameLocalizationPaths”.
- If the configuration is not available or ready, a default hardcoded path “../../../Engine/Content/Localization/PropertyNames” is used.
This variable interacts with other localization-related variables such as EditorLocalizationPaths, GameLocalizationPaths, and ToolTipLocalizationPaths. They are all part of the broader localization system in Unreal Engine.
Developers should be aware that:
- This setting is crucial for proper localization of property names in the editor.
- If not set correctly, it may lead to missing or incorrect property name translations.
- The paths are relative to the engine’s root directory.
Best practices when using this variable include:
- Ensure the paths specified actually exist and contain the correct localization data.
- Keep the localization files organized according to the engine’s expected structure.
- Use the Localization Dashboard in the editor to manage these paths rather than modifying configuration files directly.
- When packaging a game, ensure that necessary localization paths are included in the build.
- Regularly update and maintain localization files in the specified paths to keep translations current.
#Setting Variables
#References In INI files
Location: <Workspace>/Engine/Config/BaseEditor.ini:16, section: [Internationalization]
- INI Section:
Internationalization
- Raw value:
../../../Engine/Content/Localization/PropertyNames
- Is Array:
True
#References in C++ code
#Callsites
This variable is referenced in the following C++ source code:
#Loc: <Workspace>/Engine/Source/Editor/LocalizationDashboard/Private/LocalizationTargetDetailCustomization.cpp:119
Scope (from outer to inner):
file
namespace anonymous
lambda-function
Source code excerpt:
Array.Emplace(ELocalizationTargetLoadingPolicy::Editor, TEXT("Internationalization"), TEXT("LocalizationPaths"), TEXT("Editor"), GEditorIni);
Array.Emplace(ELocalizationTargetLoadingPolicy::Game, TEXT("Internationalization"), TEXT("LocalizationPaths"), TEXT("Game"), GGameIni);
Array.Emplace(ELocalizationTargetLoadingPolicy::PropertyNames, TEXT("Internationalization"), TEXT("PropertyNameLocalizationPaths"), TEXT("Editor"), GEditorIni);
Array.Emplace(ELocalizationTargetLoadingPolicy::ToolTips, TEXT("Internationalization"), TEXT("ToolTipLocalizationPaths"), TEXT("Editor"), GEditorIni);
return Array;
}();
}
FLocalizationTargetDetailCustomization::FLocalizationTargetDetailCustomization()
#Loc: <Workspace>/Engine/Source/Runtime/Core/Private/Misc/Paths.cpp:47
Scope: file
Source code excerpt:
TArray<FString> EditorLocalizationPaths;
TArray<FString> CookedEditorLocalizationPaths;
TArray<FString> PropertyNameLocalizationPaths;
TArray<FString> ToolTipLocalizationPaths;
TArray<FString> GameLocalizationPaths;
TArray<FString> RestrictedFolderNames;
TArray<FString> RestrictedSlashedFolderNames;
FString RelativePathToRoot;
#Loc: <Workspace>/Engine/Source/Runtime/Core/Private/Misc/Paths.cpp:685
Scope (from outer to inner):
file
function const TArray<FString>& FPaths::GetPropertyNameLocalizationPaths
Source code excerpt:
if(GConfig && GConfig->IsReadyForUse())
{
GConfig->GetArray( TEXT("Internationalization"), TEXT("PropertyNameLocalizationPaths"), StaticData.PropertyNameLocalizationPaths, GEditorIni );
if(!StaticData.PropertyNameLocalizationPaths.Num())
{
UE_LOG(LogInit, Warning, TEXT("No paths for property name localization data were specifed in the editor configuration."));
}
StaticData.bPropertyNameLocalizationPathsInitialized = true;
}
else
{
StaticData.PropertyNameLocalizationPaths.AddUnique(TEXT("../../../Engine/Content/Localization/PropertyNames")); // Hardcoded convention.
}
}
return StaticData.PropertyNameLocalizationPaths;
}
const TArray<FString>& FPaths::GetToolTipLocalizationPaths()
{
FStaticData& StaticData = TLazySingleton<FStaticData>::Get();