On Ma, 2007-06-11 at 02:11 +0200, Alessandro Cattelan wrote:
> Aiet Kolkhi ha scritto:
> > Ciao Alessandro!
> > 
> > sorry for the mix up ;)
> > 
> > yes, the syntax of PO files is very simple. And WordForge project has
> > created Translate Toolkit that enables converting to GNU Gettext PO
> > files from great many formats.
> > 
> > This is how a simple terminology PO file entry can look like:
> > 
> > #. "Any piece of information (text, graphics, executable) put together
> > and given a name. All the information you have on the hard drive is
> > arranged as a collection of files."
> > msgid "File"
> > msgstr "Lima"
> > 
> > The text after # sign is merely an explanation and is not needed by
> > Pootle. The important lines are: msgid, followed by the original word
> > in double quotes, and msgstr, followed by translation in double
> > quotes.
> > 
> > So it should be fairly easy to convert any text-based list to PO.
> > 
> 
> 
> I'd been told before that it should be quite easy to convert a txt into
> PO but unfortunately I don't know how to do it.
> 
> Basically what I have is a long list of terms and expressions in two
> tab-separated columns, one for the English version and one for the
> Italian translation. Something like this:
> 
> fraction      frazione        
> fraction      divisore        
> fraction bar  linee di frazione       
> frame frame
> frame cornice 
> frame contents        contenuto cornice       
> 
> 
> I understand that a PO files with these entries would look something
> like this:
> 
> msgid "fraction"
> msgstr "frazione"
> 
> msgid "fraction"
> msgstr "divisore"
> 
> msgid "fraction bar"
> msgstr "linee di frazione"
> 
> msgid "frame"
> msgstr "frame"
> 
> msgid "frame"
> msgstr "cornice"
> 
> msgid "frame contents"
> msgstr "contenuto cornice"
> 
> Is that correct?
> 
> I assume it would be quite easy to write a script for that, but I can't
> do it.

Open your text file in OOo Calc as a CSV file and choose "tab" as the
delimiter. Save it as a normal CSV file (comma seperated) and then you
can convert it to PO using csv2po from the translate toolkit. Here is
the documentation for that:
http://translate.sourceforge.net/wiki/toolkit/csv2po

> 
> I have another question: how would Pootle manage two entries with two
> different translations, such as "frame" above?
> 
> Ale.
> 

It should suggest both. Note that (in the current implementation) the
target field (msgstr) of the terminology files are considered free form,
so you are free to add something like "frame (verb)" or "cornice (noun)"
to help the translators.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to