Fwd: ATB: Group communication regarding Plone translation

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

Fwd: ATB: Group communication regarding Plone translation

Russ Ferriday
I18n experts, I have assembled what looks like a fantastic team to  
jump deep into Welsh Plone.

The first step was to run a .pot file using a translation memory.  
Rhos Prys, an experienced translator familiar with the tools from  
projects such Firefox, and OpenOffice, has raised the following  
question. Can anyone comment?
> I’ve had a look at the Plone .po files and they seem to be using  
> the .po format in an unusual way, - as a friend told me recently  
> ‘the good thing about standards is that there are so many of them…’
> If you open cmfplone in poedit, lines 22 – 1737 open in the normal  
> manner:
> #: ./skins/plone_scripts/folder_delete.cpy:44
> msgid "${items} could not be deleted."
> msgstr "The translation goes here"

> The lines following 1737 and in the other files lines have the code  
> on the #, Default line…

> #. Default: "Specify the default language setting for newly created  
> items."
> #: ./skins/plone_prefs/reconfig_form.cpt
> msgid "help_default_language"
> msgstr ""

> Which is crazy. It means that the memory translation element of  
> tools such as poedit, kbabel cannot help in this instance.

> Russ, have you come across any discussion on this issue and is  
> there a means of overcoming it?

Boiling it down, up to line 1737 the source text is in the msgid.  
After that point, the source text is in the #. Default line.
Looks as if Rhos's tool wants to use the msgid source to run through  
the TM. But most of our messages (across the 6 main pot files) have  
the source in the Default line.

Could this be a question of tools being out of date, or is our file  
format non-standard? If so, has anyone done the scripts to extract  
and merge for a TM enable translation tool to work on the text? Any  
thoughts?

Best wishes,

--r

-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
<a href="http://sel.as-us.falkag.net/sel?cmd=lnk&kid0944&bid$1720&dat1642">http://sel.as-us.falkag.net/sel?cmd=lnk&kid0944&bid$1720&dat1642
_______________________________________________
Plone-i18n mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/plone-i18n
Reply | Threaded
Open this post in threaded view
|

Re: Fwd: ATB: Group communication regarding Plone translation

Alexander Limi
Administrator
On Tue, 28 Mar 2006 12:44:38 -0800, Russ Ferriday  
<[hidden email]> wrote:

>> Which is crazy. It means that the memory translation element of tools  
>> such as poedit, kbabel cannot help in this instance.

Translation memory is not very useful - at least in my experience. Maybe  
if you have a tool with a lot of duplicate text, or on the size of  
OpenOffice. For Plone, it didn't do much (I tried it in the beginning,  
when we had a different setup).

>> Russ, have you come across any discussion on this issue and is there a  
>> means of overcoming it?
>
> Boiling it down, up to line 1737 the source text is in the msgid. After  
> that point, the source text is in the #. Default line.
> Looks as if Rhos's tool wants to use the msgid source to run through the  
> TM. But most of our messages (across the 6 main pot files) have the  
> source in the Default line.
>
> Could this be a question of tools being out of date, or is our file  
> format non-standard? If so, has anyone done the scripts to extract and  
> merge for a TM enable translation tool to work on the text? Any thoughts?

The reason it is this way is to be able to change spelling errors in the  
original template without having to re-translate that string in  
50+ languages.

--
_____________________________________________________________________

      Alexander Limi · Chief Architect · Plone Solutions · Norway

  Consulting · Training · Development · http://www.plonesolutions.com
_____________________________________________________________________

       Plone Co-Founder · http://plone.org · Connecting Content
   Plone Foundation · http://plone.org/foundation · Protecting Plone



-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
Plone-i18n mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/plone-i18n
Alexander Limi · http://limi.net

Reply | Threaded
Open this post in threaded view
|

Re: Fwd: ATB: Group communication regarding Plone translation

Hanno Schlichting-2
In reply to this post by Russ Ferriday
Russ Ferriday wrote:

>
> Boiling it down, up to line 1737 the source text is in the msgid. After
> that point, the source text is in the #. Default line.
> Looks as if Rhos's tool wants to use the msgid source to run through the
> TM. But most of our messages (across the 6 main pot files) have the
> source in the Default line.
>
> Could this be a question of tools being out of date, or is our file
> format non-standard? If so, has anyone done the scripts to extract and
> merge for a TM enable translation tool to work on the text? Any thoughts?

This is not a questions of outdated tools but of Plone (and Zope) using
the gettext standard in a not-fully-intended way ;)

The only known drawback of our policy to have artificial message ids
rather than putting the text into the msgid is in fact, that the
translations memory function of all tools doesn't work.

For a reasoning of this policy please read the introduction paragraph of
the translators guidelines
(http://plone.org/development/teams/i18n/translators-guidelines).

As this is a known problem with the gettext standard which have been
worked around by a lot of products in different ways the standard has
been extended to support a new context argument known as msgctext. But
as this is only implemented in the yet unreleased cvs version of gettext
it will require some time for all tools to recognize it and so for us to
actually use it.

So I suppose for at least the next year we won't support the usage of
translations memories for the Plone translations.

Hanno



-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
Plone-i18n mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/plone-i18n
Reply | Threaded
Open this post in threaded view
|

Re: Re: Fwd: ATB: Group communication regarding Plone translation

Russ Ferriday
In reply to this post by Alexander Limi
Thanks, Alex.

On 29 Mar 2006, at 01:07, Alexander Limi wrote:

Translation memory is not very useful - at least in my experience. Maybe if you have a tool with a lot of duplicate text, or on the size of OpenOffice. For Plone, it didn't do much (I tried it in the beginning, when we had a different setup).

Yes, that may well be the case, it depends, I suppose, on the history of the translator. TM has potential to assist us in general as our i18n infrastructure evolves, by providing translation storage outside the context of any particular implementation. The value we obtain from TM depends on how we can standardize to dovetail into existing tools and practices. 
In this case, Rhos has done some significant work prior to Plone that will help Welsh Plone appear consistent with Welsh Firefox and Welsh Open Office. Usng Rhos's TM may also help the cause of Welsh itself, where some new terminology is being newly standardised, and early convergence is especially important.  Rhos is part of the team working on Welsh standardization in Bangor uni, so I have high expectations for his TM.


Russ, have you come across any discussion on this issue and is there a means of overcoming it?

Boiling it down, up to line 1737 the source text is in the msgid. After that point, the source text is in the #. Default line.
Looks as if Rhos's tool wants to use the msgid source to run through the TM. But most of our messages (across the 6 main pot files) have the source in the Default line.

Could this be a question of tools being out of date, or is our file format non-standard? If so, has anyone done the scripts to extract and merge for a TM enable translation tool to work on the text? Any thoughts?

The reason it is this way is to be able to change spelling errors in the original template without having to re-translate that string in 50+ languages.
Yes. I knew the reason for the id approach. The thrust of my question was about how to handle it. I had the incorrect impression that TM was in more widespread use.

Please see my following message which details a bridging solution.

Best wishes,

--r

—————————————————————

Russ Ferriday
Topia Systems
tel: (+44) (0) 2076 177758
mobile: (+44) (0) 7789 338868
skype: ferriday


Reply | Threaded
Open this post in threaded view
|

Re: Re: Fwd: ATB: Group communication regarding Plone translation

Russ Ferriday
In reply to this post by Hanno Schlichting-2
Thanks, Hanno!

On 29 Mar 2006, at 01:22, Hanno Schlichting wrote:

Russ Ferriday wrote:

Boiling it down, up to line 1737 the source text is in the msgid. After
that point, the source text is in the #. Default line.
Looks as if Rhos's tool wants to use the msgid source to run through the
TM. But most of our messages (across the 6 main pot files) have the
source in the Default line.

Could this be a question of tools being out of date, or is our file
format non-standard? If so, has anyone done the scripts to extract and
merge for a TM enable translation tool to work on the text? Any thoughts?

This is not a questions of outdated tools but of Plone (and Zope) using
the gettext standard in a not-fully-intended way ;)
It's good to have that acknowledged.


The only known drawback of our policy to have artificial message ids
rather than putting the text into the msgid is in fact, that the
translations memory function of all tools doesn't work.
OK. But see later...


For a reasoning of this policy please read the introduction paragraph of
the translators guidelines

As this is a known problem with the gettext standard which have been
worked around by a lot of products in different ways the standard has
been extended to support a new context argument known as msgctext. But
as this is only implemented in the yet unreleased cvs version of gettext
it will require some time for all tools to recognize it and so for us to
actually use it.

So I suppose for at least the next year we won't support the usage of
translations memories for the Plone translations.
Pending your and limi's responses, I created a tool called fillmsgstr. I've sent it to Rhos for testing with his TM, to gauge the benefit.
From a .po file, it creates a .po.filled file that stores the original (possibly cryptic) msgid as #savedmsgid, and builds a temporary replacement for msgid from the #. Default line, which contains real text.
Running fillmsgstr makes the file, after renaming it to .po, meet the expectations of the translation tools.
After translation, the file is run through the same program, but with the -r option to reverse the process. By default the output file is .po.unfilled. The temporary msgids are replaced by the original msgids that were stored as #savedmsgid s.
In testing, running the program forwards then in reverse, gives you the same file back, which is encouraging ;)

Do we have a dedicated svn space to put tools like this? Meanwhile copies available by email.

Best wishes,

--r

Hanno

—————————————————————
Russ Ferriday
Topia Systems
tel: (+44) (0) 2076 177758
mobile: (+44) (0) 7789 338868
skype: ferriday


Reply | Threaded
Open this post in threaded view
|

Re: Re: Fwd: ATB: Group communication regarding Plone translation

Alexander Limi
Administrator
On Tue, 28 Mar 2006 23:32:45 -0800, Russ Ferriday  
<[hidden email]> wrote:

> Do we have a dedicated svn space to put tools like this? Meanwhile  
> copies available by email.

I would just stick it in the PloneTranslation product somewhere, with a  
simple readme :)

--
_____________________________________________________________________

      Alexander Limi · Chief Architect · Plone Solutions · Norway

  Consulting · Training · Development · http://www.plonesolutions.com
_____________________________________________________________________

       Plone Co-Founder · http://plone.org · Connecting Content
   Plone Foundation · http://plone.org/foundation · Protecting Plone



-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
Plone-i18n mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/plone-i18n
Alexander Limi · http://limi.net

Reply | Threaded
Open this post in threaded view
|

fillmsgstr.py - tool to support use of translation memory - informal HOW-TO

Russ Ferriday
In reply to this post by Hanno Schlichting-2
If you are translating with the aid of Translation Memories (if not, it makes sense to have a close look) you will find this tool
useful for preparing .po files for your TM enabled tool.
If you are just starting a translation simply run it on a .pot file like this

    python fillmsgstr.py -o plone-LC.po plone.pot

where LC is your language code. Then plone-LC.po will be created from plone.pot.

Do your translation on plone-LC.po. Then use the same program with the -r option to put things back into our slightly offbeat form...

    python fillmsgstr.py -r plone-LC.po

This will make a plone-LC.po.unfilled file that you must manually copy over the plone-LC.po file.

Full doc in the program, including details of what it does to the files, and why.

Best wishes,

--r


On 11 Apr 2006, at 13:46, Hanno Schlichting wrote:

Hi Russ.

Actually I have no good argument for either of these places. So the
simpler option should win, which is PloneTranslations/i18n/utils. This
way translators won't have to check out an additional program (and
install it).

If I really like your script and have some time, I might add it to
i18ndude as well ;)

Hanno

—————————————————————

Russ Ferriday
Topia Systems
tel: (+44) (0) 2076 177758
mobile: (+44) (0) 7789 338868
skype: ferriday