Opened 15 years ago

Closed 15 years ago

#6875 closed patch (fixed)

Patches with updated Swedish translations and scripts to simplify XML translation

Reported by: Stefan Asserhäll <stefan.asserhall@…> Owned by: Janne Grunau
Priority: trivial Milestone: 0.22
Component: Translations Version: head
Severity: low Keywords:
Cc: Ticket locked: no

Description

Here are two patches with updated Swedish translations, including four generic scripts to simplify XML translation. I did this because I found that a lot of strings were not translated in the GUI. It seems that no translation has ever been done for <value> tags in the XML files.

The script "lupdate.sh" extracts strings for translation from all XML files and runs lupdate, and "lrelease.pl" deposits the translated strings back into the XML files after the translation and runs lrelease. The second script has a verbose flag (-v) and can take one or more languages as parameters.

The workflow becomes (with Swedish as example language):

cd mythtv/i18n
./lupdate.sh
linguist mythfrontend_sv.ts
./lrelease.pl -v sv

cd mythplugins
./lupdate.sh
linguist myth*/i18n/*_sv.ts
./lrelease.pl -v sv

The patch also includes i18n directories for some mythplugins that didn't have them, and fixes som missing tr() in the source code.

I hope this can be useful for other translators, as well. I could add this information to the wiki, if you'd like.

Attachments (3)

myth-translation-patch.tar.gz (205.1 KB) - added by Stefan Asserhäll <stefan.asserhall@…> 15 years ago.
Translation patch for MythTV
myth-translation-patch.tar.2.gz (168.6 KB) - added by Stefan Asserhäll <stefan.asserhall@…> 15 years ago.
Updated and split patch
mythbrowser-translations-090822.diff (19.0 KB) - added by Stefan Asserhäll <stefan.asserhall@…> 15 years ago.
Additional patch for mythbrowser with some strings I missed before

Download all attachments as: .zip

Change History (15)

Changed 15 years ago by Stefan Asserhäll <stefan.asserhall@…>

Translation patch for MythTV

comment:1 Changed 15 years ago by stuartm

Hi Stefan, this is what the themestringtool in svn is for and I will be running it when changes to the themes have settled down in a week or two. It writes the strings to i18n/themestrings.h rather than cluttering up the xml.

comment:2 Changed 15 years ago by stuartm

Can you break out the changes into separate patches please. One patch for source changes,one for the translation updates and the scripts in a third?

comment:3 Changed 15 years ago by stuartm

Status: newinfoneeded_new

Changed 15 years ago by Stefan Asserhäll <stefan.asserhall@…>

Updated and split patch

comment:4 Changed 15 years ago by Stefan Asserhäll <stefan.asserhall@…>

Thanks for the info about themestringtool. I didn't realize that <value> tags were handled differently from <text> and <alttext>. It seems a good idea to avoid having the translations in XML, but to also change <text> and <alttext> to use the same scheme as <value>, I think the existing translations need be moved into the ts files.

I have updated the lupdate.sh script to use themestringtool, and lrelease.pl to only deposit <text> and <alttext> translations.

I have uploaded a new patch, with the changes split as per your request.

comment:5 Changed 15 years ago by stuartm

Status: infoneeded_newnew

Changed 15 years ago by Stefan Asserhäll <stefan.asserhall@…>

Additional patch for mythbrowser with some strings I missed before

comment:6 Changed 15 years ago by stuartm

Type: enhancementpatch

comment:7 Changed 15 years ago by Janne Grunau

Owner: changed from Isaac Richards to Janne Grunau
Status: newaccepted

comment:8 Changed 15 years ago by Janne Grunau

(In [22198]) mark a few more strings translateable, Refs #6875

comment:9 Changed 15 years ago by Janne Grunau

(In [22200]) add mythtv/programs/themestrings.h for xml translations in mythtv/programs/*. Refs #6875

comment:10 Changed 15 years ago by Janne Grunau

(In [22201]) enable translations in mythmovies and add swedish translations. Refs #6875

comment:11 Changed 15 years ago by Janne Grunau

(In [22208]) update swedish translations in xml files. Refs #6875

I didn't try to resolve the rejects. translations in the xml files are deprecated. they should be available via themestrings.h in the standard translation files.

comment:12 Changed 15 years ago by Janne Grunau

Resolution: fixed
Status: acceptedclosed

(In [22209]) update swedish plugin translations. Fixes #6875

mythweather translation do not apply. please create a new ticket with the remaining translations.

Note: See TracTickets for help on using tickets.