Inheritance #
- AudioServer
- CameraServer
- ClassDB
- DisplayServer
- EditorFileSystemDirectory
- EditorInterface
- EditorPaths
- EditorSelection
- EditorUndoRedoManager
- EditorVCSInterface
- Engine
- EngineDebugger
- FramebufferCacheRD
- GDExtensionManager
- Geometry2D
- Geometry3D
- IP
- Input
- InputMap
- JNISingleton
- JSONRPC
- JavaClassWrapper
- JavaScriptBridge
- MainLoop (1)
- Marshalls
- MovieWriter
- NativeMenu
- NavigationMeshGenerator
- NavigationServer2D
- NavigationServer3D
- Node (21)
- OS
- OpenXRExtensionWrapperExtension
- OpenXRInteractionProfileMetadata
- Performance
- PhysicsDirectBodyState2D (1)
- PhysicsDirectBodyState3D (1)
- PhysicsDirectSpaceState2D (1)
- PhysicsDirectSpaceState3D (1)
- PhysicsServer2D (1)
- PhysicsServer2DManager
- PhysicsServer3D (1)
- PhysicsServer3DManager
- PhysicsServer3DRendering
ServerHandler
- ProjectSettings
- RefCounted (121)
- RenderData (2)
- RenderSceneData (2)
- RenderingDevice
- RenderingServer
- ResourceLoader
- ResourceSaver
- ResourceUID
- ScriptLanguage (1)
- ShaderIncludeDB
- TextServerManager
- ThemeDB
- TileData
- Time
- TranslationServer
- TreeItem
- UndoRedo
- UniformSetCacheRD
- WorkerThreadPool
- XRServer
- XRVRS
- AESContext
- AStar2D
- AStar3D
- AStarGrid2D
- AudioEffectInstance (1)
- AudioSample
- AudioSamplePlayback
- AudioStreamPlayback (5)
- CameraFeed
- CharFXTransform
- ConfigFile
- Crypto
- DTLSServer
- DirAccess
- ENetConnection
- EditorContextMenuPlugin
- EditorDebuggerPlugin
- EditorDebuggerSession
- EditorExportPlatform (6)
- EditorExportPlugin
- EditorExportPreset
- EditorFeatureProfile
- EditorFileSystemImportFormatSupportQuery
- EditorInspectorPlugin
- EditorResourceConversionPlugin
- EditorResourcePreviewGenerator
- EditorResourceTooltipPlugin
- EditorSceneFormatImporter (4)
- EditorScenePostImport
- EditorScenePostImportPlugin
- EditorScript
- EditorTranslationParserPlugin
- EncodedObjectAsID
- EngineProfiler
- Expression
- FileAccess
- GLTFObjectModelProperty
- HMACContext
- HTTPClient
- HashingContext
- ImageFormatLoader (1)
- JavaClass
- JavaObject
- JavaScriptObject
- KinematicCollision2D
- KinematicCollision3D
- Lightmapper (1)
- MeshConvexDecompositionSettings
- MeshDataTool
- MultiplayerAPI (2)
- Mutex
- NavigationPathQueryParameters2D
- NavigationPathQueryParameters3D
- NavigationPathQueryResult2D
- NavigationPathQueryResult3D
- Node3DGizmo (1)
- OggPacketSequencePlayback
- OpenXRAPIExtension
- PCKPacker
- PackedDataContainerRef
- PacketPeer (8)
- PhysicsPointQueryParameters2D
- PhysicsPointQueryParameters3D
- PhysicsRayQueryParameters2D
- PhysicsRayQueryParameters3D
- PhysicsShapeQueryParameters2D
- PhysicsShapeQueryParameters3D
- PhysicsTestMotionParameters2D
- PhysicsTestMotionParameters3D
- PhysicsTestMotionResult2D
- PhysicsTestMotionResult3D
- RDAttachmentFormat
- RDFramebufferPass
- RDPipelineColorBlendState
- RDPipelineColorBlendStateAttachment
- RDPipelineDepthStencilState
- RDPipelineMultisampleState
- RDPipelineRasterizationState
- RDPipelineSpecializationConstant
- RDSamplerState
- RDShaderSource
- RDTextureFormat
- RDTextureView
- RDUniform
- RDVertexAttribute
- RandomNumberGenerator
- RegEx
- RegExMatch
- RenderSceneBuffers (2)
- RenderSceneBuffersConfiguration
- Resource (103)
- ResourceFormatLoader
- ResourceFormatSaver
- ResourceImporter (16)
- SceneState
- SceneTreeTimer
- Semaphore
- SkinReference
- StreamPeer (5)
- SurfaceTool
- TCPServer
- TLSOptions
- TextLine
- TextParagraph
- TextServer (1)
- Thread
- TranslationDomain
- TriangleMesh
- Tween
- Tweener (5)
- UDPServer
- UPNP
- UPNPDevice
- WeakRef
- WebRTCPeerConnection (1)
- XMLParser
- XRInterface (4)
- XRPose
- XRTracker (2)
- ZIPPacker
- ZIPReader
Table of contents
-
var pseudolocalization_accents_enabled: bool = true -
var pseudolocalization_double_vowels_enabled: bool = false -
var pseudolocalization_enabled: bool = false -
var pseudolocalization_expansion_ratio: float = 0.0 -
var pseudolocalization_fake_bidi_enabled: bool = false -
var pseudolocalization_override_enabled: bool = false -
var pseudolocalization_prefix: String = "[" -
var pseudolocalization_skip_placeholders_enabled: bool = true -
var pseudolocalization_suffix: String = "]" -
func add_translation(translation: Translation) -> void -
func clear() -> void -
const func get_translation_object(locale: String) -> Translation -
const func pseudolocalize(message: StringName) -> StringName -
func remove_translation(translation: Translation) -> void -
const func translate(context: StringName = &"") -> StringName -
const func translate_plural(context: StringName = &"") -> StringName
TranslationDomain #
is_refcounted, is_instantiable, core, not_builtin_classes
A self-contained collection of Translation resources.
TranslationDomain is a self-contained collection of Translation resources. Translations can be added to or removed from it.
If you're working with the main translation domain, it is more convenient to use the wrap methods on TranslationServer.
Members #
var pseudolocalization_accents_enabled: bool = true#
Replace all characters with their accented variants during pseudolocalization.
Note: Updating this property does not automatically update texts in the scene tree. Please propagate the MainLoop.NOTIFICATION_TRANSLATION_CHANGED notification manually after you have finished modifying pseudolocalization related options.
var pseudolocalization_double_vowels_enabled: bool = false#
Double vowels in strings during pseudolocalization to simulate the lengthening of text due to localization.
Note: Updating this property does not automatically update texts in the scene tree. Please propagate the MainLoop.NOTIFICATION_TRANSLATION_CHANGED notification manually after you have finished modifying pseudolocalization related options.
var pseudolocalization_enabled: bool = false#
If true, enables pseudolocalization for the project. This can be used to spot untranslatable strings or layout issues that may occur once the project is localized to languages that have longer strings than the source language.
Note: Updating this property does not automatically update texts in the scene tree. Please propagate the MainLoop.NOTIFICATION_TRANSLATION_CHANGED notification manually after you have finished modifying pseudolocalization related options.
var pseudolocalization_expansion_ratio: float = 0.0#
The expansion ratio to use during pseudolocalization. A value of 0.3 is sufficient for most practical purposes, and will increase the length of each string by 30%.
Note: Updating this property does not automatically update texts in the scene tree. Please propagate the MainLoop.NOTIFICATION_TRANSLATION_CHANGED notification manually after you have finished modifying pseudolocalization related options.
var pseudolocalization_fake_bidi_enabled: bool = false#
If true, emulate bidirectional (right-to-left) text when pseudolocalization is enabled. This can be used to spot issues with RTL layout and UI mirroring that will crop up if the project is localized to RTL languages such as Arabic or Hebrew.
Note: Updating this property does not automatically update texts in the scene tree. Please propagate the MainLoop.NOTIFICATION_TRANSLATION_CHANGED notification manually after you have finished modifying pseudolocalization related options.
var pseudolocalization_override_enabled: bool = false#
Replace all characters in the string with *. Useful for finding non-localizable strings.
Note: Updating this property does not automatically update texts in the scene tree. Please propagate the MainLoop.NOTIFICATION_TRANSLATION_CHANGED notification manually after you have finished modifying pseudolocalization related options.
var pseudolocalization_prefix: String = "["#
Prefix that will be prepended to the pseudolocalized string.
Note: Updating this property does not automatically update texts in the scene tree. Please propagate the MainLoop.NOTIFICATION_TRANSLATION_CHANGED notification manually after you have finished modifying pseudolocalization related options.
var pseudolocalization_skip_placeholders_enabled: bool = true#
Skip placeholders for string formatting like %s or %f during pseudolocalization. Useful to identify strings which need additional control characters to display correctly.
Note: Updating this property does not automatically update texts in the scene tree. Please propagate the MainLoop.NOTIFICATION_TRANSLATION_CHANGED notification manually after you have finished modifying pseudolocalization related options.
var pseudolocalization_suffix: String = "]"#
Suffix that will be appended to the pseudolocalized string.
Note: Updating this property does not automatically update texts in the scene tree. Please propagate the MainLoop.NOTIFICATION_TRANSLATION_CHANGED notification manually after you have finished modifying pseudolocalization related options.
Methods #
func add_translation(translation: Translation) -> void#
Adds a translation.
func clear() -> void#
Removes all translations.
const func get_translation_object(locale: String) -> Translation#
Returns the Translation instance that best matches locale. Returns null if there are no matches.
const func pseudolocalize(message: StringName) -> StringName#
Returns the pseudolocalized string based on the message passed in.
func remove_translation(translation: Translation) -> void#
Removes the given translation.
const func translate(context: StringName = &"") -> StringName#
Returns the current locale's translation for the given message and context.
const func translate_plural(context: StringName = &"") -> StringName#
Returns the current locale's translation for the given message, plural message and context.
The number n is the number or quantity of the plural object. It will be used to guide the translation system to fetch the correct plural form for the selected language.