CodeCafeOpenShiftGame / PodEscape

Endless runner of a pod trying to escape from a project being deleted.
https://podescape.io
Apache License 2.0
29 stars 16 forks source link

use gettext to handle translations #79

Open Jibec opened 3 years ago

Jibec commented 3 years ago

as Fedora community member, I'll be pleased to host you on our translation platform it would make it faster for translators to contribute your project, and reduce the follow-up cost (people who want it will be notified when you update your pot file). You don't have to do anything else than:

have a nice day, thank you for the fun :)

rluders commented 3 years ago

Hey @Jibec

Thanks for your contribution. It will be a nice improvement to bring us more translations, and we do really appreciate it.

However, I'm struggling to run it:

image

Maybe @ernesgonzalez33 could give it a try as well? I'm wondering if I'm not doing something wrong.

Also, I do have one small observation, that since we are using the "locale" files to generate the dropdown menu that allows the user to select language since we don't have the en_US, right now, we don't have it as an option in our dropdown.

BTW, I think that it would be better to use the TRANSLATION_KEYS instead of normal texts for the translation keys. So, it can solve the en_US issue as well, since we gonna need to have an en_US.po file.

ernesgonzalez33 commented 3 years ago

Hi! @Jibec

I have the same problem as @rluders. How do we see the translations? It seems that the drop-down menu doesn't work

Jibec commented 3 years ago

as far as I understand the doc, you have to manually add the po file in the tool, the same way you did with csv file.

Jean-Baptiste

Jibec commented 3 years ago

i understand the requests and will work on it tomorrow :)

Jean-Baptiste

Jibec commented 3 years ago

If I revert translation keys:

Are you sure you want this?

I did fix the translation import using Godot Engine 3.3 stable from Flathub, but I have an import error preventing me to make sure english language is correctly displayed in the language button.

Here is the error: image

The tool to fix broken dependencies don't show any error, and the button to fix broken dependencies is greyed out.

What is weird is that I see the files when using the GNOME file browser, and access rights looks normal. But when in Godot, I can't see the file: image

I assume there is something obvious I'm missing. Any idea?

rluders commented 3 years ago

@Jibec I'm pretty sure that you are not using the Godot version that supports Mono, and that is why you are getting that missing messages.

If I revert translation keys:

it makes translator work more complex (no translation memory help from translations platform, require to check how it is translated in english) it makes dev work more complex (require to make sure there is no missing keys, and there is already) Are you sure you want this?

I'm not sure if there is another option. I mean, you could include the option to "en_US" directly to the dropbox by code, but... I'm not sure how it will work. It needs to be tested.