Skip to content
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

Desktop and i18n work #559

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

mwilck
Copy link
Contributor

@mwilck mwilck commented Feb 13, 2020

This started out with me realizing that we had no translations in our .desktop file. I thought that's not ideal for a desktop program. I tried to figure out how to generate them and stumbled upon the recent move from intltool to gettext, and figured that the .po files haven't been updated for quite a while. It was a pretty rough ride because I'm not familiar with either waf or gettext.

Eventually I have come up with a way to rebuild the .po files from the current source, and optionally commit them in in git. (That's the big "update translations" commit. I've reviewed the de.po file and the results seemed reasonable to me). I also added some missing German translations.

Please have a look.

Re-introduce translatable strings, and use the phrases for
which we already have translations in existing .po files.
@ederag
Copy link
Collaborator

ederag commented Feb 13, 2020

Please hold on,
I have plenty of documentation for i18n, and plans.
This is work in progress.
We'll discuss that after v3.0.

Please do not even try to PR the first commit separately, it's good practice to keep the Exec line.
I'll find the reference if you wish.

The 'subst' rule is not necessary any more. Use a rule to create
i18n entries in the desktop file instead.
Add a waf configure-time option "--build-i18n". If this option is
given, waf will rebuilt the .pot template from po/POTFILES.in, and
will recreate all .po files.

This happens in the build/ subdirectory. By copying back the .po files
from build/po/ to po/, they can be updated in the source tree.
Use a string we already have lots of translations for.
Changes made using the --build-i18n option.
@mwilck mwilck force-pushed the desktop-and-i18n-work branch from 3c07199 to 7e587c4 Compare February 14, 2020 20:01
@mwilck
Copy link
Contributor Author

mwilck commented Feb 14, 2020

Pushed again with the removal of the Exec= lines reverted.

@ederag
Copy link
Collaborator

ederag commented Feb 18, 2020

Some commits look promising,
but that can not be merged right now, we'll discuss after v3.0,
thanks for your understanding !

@matthijskooijman
Copy link
Member

This started out with me realizing that we had no translations in our .desktop file.

Hm, while looking for something else, I noticed #497 earlier today, which seems to remove translations of the desktop file (without really mentioning this in the commit messages, so I'm not sure why). Maybe you @mwilck already know this, but otherwise it might be useful background (haven't looked at this PR at all yet, though).

@mwilck
Copy link
Contributor Author

mwilck commented May 13, 2020

I noticed that the translations were gone, and I made this PR to add them back. I found it strange to create a 3.0 release with a desktop file without any translations.

I'm definitely not an i18n expert. Things have changed a lot in this area, you find notes everywhere that tools that were previously used are now deprecated and out of support. I fiddled around with this for a day or two until the results looked ok-ish to me. Obviously I couldn't review all translations. After @ederag's last comment (Feb 18), I didn't bother any more.

@ederag has made some changes to the waf code after this PR that prevent merging it directly. I guess it's fixable with some mechanic changes (variable renames), but it's been 3 months, I've forgotten most of the stuff I did here.

@mwilck
Copy link
Contributor Author

mwilck commented May 13, 2020

... and no, I don't have slightest idea why these translations had been removed.

This was referenced Nov 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants