Opened 17 years ago

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

Download all attachments as: .zip

Change History (15)

by Stefan Asserhäll <stefan.asserhall@…>, 17 years ago

Translation patch for MythTV

comment:1 by stuartm, 17 years ago

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 by stuartm, 17 years ago

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 by stuartm, 17 years ago

Status: newinfoneeded_new

by Stefan Asserhäll <stefan.asserhall@…>, 17 years ago

Updated and split patch

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

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 by stuartm, 17 years ago

Status: infoneeded_newnew

by Stefan Asserhäll <stefan.asserhall@…>, 17 years ago

Additional patch for mythbrowser with some strings I missed before

comment:6 by stuartm, 17 years ago

Type: enhancementpatch

comment:7 by Janne Grunau, 17 years ago

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

comment:8 by Janne Grunau, 17 years ago

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

comment:9 by Janne Grunau, 17 years ago

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

comment:10 by Janne Grunau, 17 years ago

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

comment:11 by Janne Grunau, 17 years ago

(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 by Janne Grunau, 17 years ago

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.