AUC Translation Guide
It is relatively easy to translate AUC from one language to another. I
already
have partial or complete translations for Spanish, Danish, French, and
Italian.
I have created this document to assist those who wish to create or
maintain a translation
for AUC. There are a few guidelines to follow to make sure that your
translation
is easy for me to integrate into the existing codebase.
Beginning a Translation
- Get a copy of the latest source release, or even better, download the
current CVS
release (for the CVS release, you'll need to compile it although
installation is not
necessary before continuing).
- Locate the file
auc.pot located in the po/
directory of
the AUC sources. This is the template file from which all translations
are created.
- Rename
auc.pot to LanguageCode.po ,
where the
language
code
is a two-letter abbreviation for the language to which you are
translating.
- Edit the po-file with a text editor or one of the translation
utilities listed below.
Each of the strings in the file preceeded by
msgid is a
string that appears
somewhere in the AUC code. Below it, following msgstr , you
should place
the correct translation in your native language.
- Once the po-file is complete (or whenever you are bored of that), find
the
data/ and data/help/ directories in the AUC
sources. These
contain data files and help files that are used by AUC at run-time. The
primary content
of these files are text messages that will appear for users. Thus, they
should be
translated as well.
- Any files in this directory that you translate should be named
OriginalFilename.LanguageCode . Any html files
can
be translated almost directly. The xml files usually contain templates
for
html forms. Within the xml files, only text inside title or
description tags should be translated.
- Please send your translated files (in any stage of progress) to me so
I can include
them in the latest copy of the source.
Maintaining a Translation
The most difficult part of maintaining a translation is to keep it up
to date with the
latest changes to the code. For the files in data/ it is
necessary to keep
an eye on them and make sure they are up to date by hand. For the
po-file, there are some
utilities which help to keep them up to date. It is not necessary for
you, as a translator
to use them, but be aware that I use them from time to time, and will
often send you an
updated po-file to check and add additional translations if necessary.
The msgmerge program is used to keep po-files up to date
with the most
recent source. Since the auc.pot file is kept up to date
every time I compile
AUC, it is necessary only to merge the new information in auc.pot with the
old translations in
the po-file. In order to do this, grab the most recent version of
auc.pot and
run the following command (or send me your po-file and I can do it for you
and then email a
new po-file back to you):
msgmerge LanguageCode.po auc.pot -o newfile.po
newfile.po will now contain an updated set of
translations. You should
then edit the file and get it up to date. In some cases, there will be
new, untranslated
strings that you should translate. In other cases, strings which you have
previously
translated will have changed. In these cases, the following text will
preceed the translation:
#, fuzzy
You should update your translation to match the changes in the
untranslated string. It is
important that you remove the line containing the "fuzzy flag" or else the
string will not
be translated in the final AUC output. Finally, at the end of the new
po-file, there will
be a large number of commented-out translations. These are strings that
no longer exist in
the AUC code. They can be safely deleted from the po-file if you
wish.
It is important to go through this maintenence process from time to
time to keep
your translation working with AUC.
Translation Utilities
The following unix tools are available as alternatives to a text editor
when making
changes to a po-file. They help especially for finding and fixing fuzzy
and
untranslated entries. If you are in a windows-only environment, a text
editor is probably
still your only choice.
- GTranslator (for
GNOME)
- KTranslator (for
KDE)
- KBabel (for KDE)
- Emacs in PO mode (an explanation of how to set this up is available in
the
GNU gettext documentation, linked below)
Further Information
© 2000, David Moore
|