on i4PACE(i for Personal Archiving and Creating Environment)
actions » SearchLogin 89 articles • 30 Jul 2010

Recent articles in 'translation'

Friday, 09 Jan 2009

permalink Translate toolkit

Installed the latest version of translate-toolkit 1.2.1. First, downloaded translate-toolkit_1.2.1-1_all.deb at http://translate.sourceforge.net/wiki/. Needed to add python-lxml on Ubuntu.

Also, installed virtaal, a simple editor for PO files by downloading a deb file at the same site. It's version0.2 and very simple, which may be good for further customization.

• Wrote Teru at 16:45 | read 93× | 11 Comments

Sunday, 07 Dec 2008

permalink OmegaT

Installed OmegaT, one of open-source software for computer assisted translation tools. Using Ubuntu 8.10, it's just one command:

$ sudo apt-get install omegat

Its menu shows up as one of the office applications, and its initial screen looks like [[image: omegat.png]] Automatically showing Japanese interface :-) Look forward to making use of it for translating software, especially as a tool to manage translation memory.

• Wrote Teru at 18:24 (edited 1×, last on 07 Dec 2008) | read 32× | 0 Comments

Thursday, 04 Dec 2008

permalink Japanese translation of Pinax 1

Working on translating Pinax into Japanese.

Using gettext and its tools, useful commands are: msgfmt : create .mo file from .po file msgunfmt : create .po file from .mo file msgmerge old.po temp.po > new.po : create new.po with template temp.po using data in old.po

Pootle has turned out to be an excellent tool. To install on Ubuntu,

$ sudo apt-get install pootle

Edit files in /etc/pootle. Create translation projects in /var/lib/pootle. Start pootle server by

$ sudo /etc/init.d/pootle start

As for translation memory, Pootle has "terminology" feature, which is limited to 30 characters per item and upto 500 words. Better program is updatetm as explained at http://translate.sourceforge.net/wiki/pootle/updatetm. E.g.,

$ updatetm -i sample.po -t memory.tmx -o sample.po.tm

where sample.po.tm is created from sample.po with memory.tmx as a translation memory, and is a translation memory file used to create suggestions on Pootle.

Well, it uses the translation memory, but how do I create it? There are other commands as shown at http://translate.sourceforge.net/wiki/decathlon/wordpress_files:

$ po2tmx -l ja -i translation_folder -o translation.tmx

which reads the po files under the folder translation_folder and put the translation into the translaton memory file translation.tmx. When a template po file sample.pot is created by xgettext or django-admin.py/manage.py makemessages, run

$ pot2po -t translation.tmx -i sample.pot -o sample.po

.

Just found out that there are many other "msg" commands:

$ man -k msg
msgattrib (1)        - attribute matching and manipulation on message catalog
msgcat (1)           - combines several message catalogs
msgcmp (1)           - compare message catalog and template
msgcomm (1)          - match two message catalogs
msgconv (1)          - character set conversion for message catalog
msgen (1)            - create English message catalog
msgexec (1)          - process translations of message catalog
msgfilter (1)        - edit translations of message catalog
msgfmt (1)           - compile message catalog to binary format
msggrep (1)          - pattern matching on message catalog
msghack (1)          - Alter .po files in ways no sane mind would think about
msginit (1)          - initialize a message catalog
msgmerge (1)         - merge message catalog and template
msgunfmt (1)         - uncompile message catalog from binary format
msguniq (1)          - unify duplicate translations in message catalog
poen (1)             - Initialises a directory English PO files by taking POT...

In addition, there are html2po and po2html commands as well:

$ html2po -t old_readme.html.po -i readme.html -o new_readme.html.po
$ po2html -t readme.html -i new_readme.html.po -o new_readme.html

as shown at http://translate.sourceforge.net/wiki/decathlon/wordpress_files.

• Wrote Teru at 15:00 (edited 7×, last on 04 Dec 2008) | read 44× | 0 Comments

Wednesday, 12 Nov 2008

permalink Japanese translation of Pinax

Pinax on Django looks good, but Japanese translation isn't available. Will try to work on the po file in the source as a good experience for me to go thru a procedure to localize a software using gettext and its related programs.

Here's a memo on procedures to translate the user interface using .po files. (cf. http://bluequartz.org/docs/translate/index-j.html)

$ sudo apt-get install gettext
$ mkdir -p /home/yarrow/translation/pinax/ja
$ cp -R /home/yarrow/pinax/projects/complete_project/locale/en/* /home/yarrow/translation/pinax/ja/
$cd /home/yarrow/translation/pinax/ja

Becauuse django.mo and django.po are both available, no need to do

$ msgunfmt django.mo -o django.po

After editing django.po for Japanese translation, create django.mo by

$ msgfmt django.po -o django.mo

Then,

$mkdir -p /home/yarrow/pinax/projects/complete_project/locale/ja
$ cp /home/yarrow/translation/pinax/ja/*.mo  /home/yarrow/pinax/projects/complete_project/locale/ja
• Wrote Teru at 21:10 (edited 2×, last on 12 Nov 2008) | read 41× | 0 Comments

4 shown; more articles may be found in the archives. The permalink icon is the article's permalink.
Process times: page=0.378 request=0.388 cpu=0.390