Good morning,

TL; DR: How to begin translating a GTK Application using po?

I'm looking forward to making translations for my application (
https://github.com/GustavoPeredo/font-downloader), I read the docs but
couldn't really understand how to begin translating a GTK application.

I'm following GNOME Builder's app template. Inside the 'po' folder I have
three files : "LINGUAS", "POTFILES" and "meson.build", by looking at some
other projects, I'm assuming that "LINGUAS" is the file that lists the
supported locales (de, en_GB, pt_BR etc...) and "POTFILES" is the file that
lists files that are going to have translations applied to.

By using gettext.py, I'm able to create a .pot file with all texts from my
window.py file (which has only one text) and apply translations depending
on LOCAL, BUT I'm not able to get the texts from glade.ui files nor apply
translations to them + the method I was using (which is similar to this
answer:
https://stackoverflow.com/questions/10094335/how-to-bind-a-text-domain-to-a-local-folder-for-gettext-under-gtk3/10540744#10540744)
is very different from Apostrophe's dev approach (and GNOME Builder's
default, as seen in the auto generated main.py file).

Here is what I want to do: Generate pot files according to "POTFILES"'s
files list, have these translations built by meson and use these pot files
in my python application, but I don't know how.

I'll be very thankful for resources on beginning translation in a GNOME
project, but merge requests and direct solutions are also welcome.

Thank you for your attention,
Gustavo.
_______________________________________________
gnome-i18n mailing list
gnome-i18n@gnome.org
https://mail.gnome.org/mailman/listinfo/gnome-i18n

Reply via email to