-
-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
🌎 Translation Support #118
base: godot-4.x
Are you sure you want to change the base?
Conversation
texture_picker.texture_changed.connect(_set_icon_path) | ||
script_picker.script_path_changed.connect(_set_script_path) | ||
id_generation_enabled.toggled.connect(_set_id_generation) | ||
class_name_edit.text_changed.connect(_set_class_name) | ||
|
||
func _translate(): | ||
icon_label.text = TranslationManager.translate("ui.property_editor.icon_label.text") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In Godot 3 we could simply use the tr()
function available in GDScript. Could we do that instead of this custom translation mamager? Godot 4 supports .pot files in the project settings.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I will take a better look at this, I thought that was only applied to the project, not to addons.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, I ran some tests here and as I suspected the TranslationServer is not available in the EditorPlugin so we can't inject POT files.
Some refs:
godotengine/godot-proposals#6885
godotengine/godot-proposals#1262
I actually took the idea of the custom tr manager from the reference you gave in #65:
I just want to add here that godot seams to be partially auto translating some words... |
Description
Adding translation support to Pandora. The Script will get the editor's language and always fallback to English.
Addressed issues
Draft Tasks
The languages listed above are languages I can speak and am able to quickly translate as soon as all strings are mapped. Once this is merged you can raise a PR to add your language if missing.