The development of GNU Solfege has moved to Savannah because tca@gnu.org (main author) is stepping down as the only maintainer of the program. Please contact maintainers@gnu.org if you want to take over the job.

Translate GNU Solfege

We use gettext to make Solfege display translated messages, and let the Translation Project to handle the translation of .po files. You can view the status of the existing translations on http://translationproject.org/domain/solfege.html. You should visit their web site and join your language team if you want to translate solfege to you own language. Do not just translate the .po file included in the tarball and send it to Tom Cato or the mailing list!

Documentation about the Translation Project are available on their site. You can also ask for help mailing list.

Should I translate the stable or unstable branch?

Wrong question! You should translate whatever is the current branch on the Translation Project. We do this to make life easier and to avoid people doing unnecessary translation work.

Which files should I translate?

Existing translations are available on http://translationproject.org/domain/solfege.html The .pot file to use to start a new translation is also available there. But then you should first check with the language teams how to start translating.

PO files

The po-files are plain-text files, so you can edit them in any text editor. But my advise is to edit them using emacs or any program designed to edit these files. On windows, the best tool is poEdit. This can save you some trouble because these programs prevent you from the most annoying syntax errors.

Ambiguous strings

When you translate the .po file, you will notice some msgid strings that look a little strange, for example "interval|m9". This is because very short strings can be ambiguous. So some times in the source code I might write _("interval|m9") and some other place _("chord|m9"). Both strings will be displayed as "m9" when you run with english messages. But for some languages the strings might be translated differently. In norwegian "chord|m9" is translated to "m9" and "interval|m9" is translated to "l9". Notice that you should not include the word before "|" in the translated message.

Strings to take special care of

The string SOLFEGETRANSLATORS should name the people that have translated Solfege to that particular language.

One entry starting with "Because not all documents..." contain the uppercase word "LANGUAGE". Here you must replace "LANGUAGE" with the language you are translating to.

The two strings "notenameformat|%(notename)s" and "notenameformat|%(notename)s%(oct)s" describe how notenames are displayed to the user. Add a translation of this string if you want to change any thing.

%(unotename)s
Untranslated notename
%(notename)s
Translated notename
%(notename2)s
Translated notename. Capitalize the first letter in notename if the note is (in solfege internal format) c, or lower.
%(oct)s
Zero or more comma (",") or apostrop ("'") chars that tell the octave.
%(suboct)s
If the tone is b, or lower, this will return a number (1 for "c,", 2 for "c,,", 3 for "c,,," etc.) that will be displayed as small numbers below the line.
%(supoct)s
If the tone is c' or higher, this will return a number (1 for "c'", 2 for "c''", 3 for "c'''" etc.) that will be displayed as small numbers above the line.

More about lesson files

Lesson files will also be translated using the gettext tools. This mean that messages from lesson files will be translated in the .po file together with the rest of the program. So translators don't even have to know that there exists anything called lesson files.

Lesson file writers should mark strings for translation like this:

name = _("Major")

If you write lesson files that will not be included in the official release, you can enter the translations directly into the lesson file:

name = "Major"
name[no] = "Dur"
name[fr] = "Majeur"

Note that the translation in name[LANG] will be used instead of name=_("string...") if LANG is your current locale and both are present.

The user manual

Benno Schulenberg summarised the long description below in this sentence:

Do not change anything between "<" and ">", but do translate things between ">" and "<", where appropriate.

If you care for a longer description:

The Solfege User Manual is written in DocBook XML. The xml2po tool is used to create the .po file. Most of the xml elements are filtered out before the text reach the translators, but some are still left.

The content of these elements should be translated:

  • <empasis>TRANSLATE THIS</emphasis>
  • <guimenu>Help</guimenu>
  • <guimenuitem>Exit</guimenuitem>
  • <guibutton>BUTTONLABEL</guibutton> Translate the text BUTTONLABEL the same way the button we are describing is translate in the program.

Don't translate anything of the UPPERCASE strings here:

<xref linkend="DONT TRANSLATE THIS"/>
<userinput>DONT TRANSLATE THIS</userinput>
<literal>DONT TRANSLATE THIS</literal>
<filename>/SOME/FILE/NAME/filename>
<email>EMAIL@ADDRESS.COM</email>

In the <ulink> element you should translate the linked text (uppercase in the example below), but not the url:

<ulink url="http://example.com">TRANSLATABLE TEXT</ulink>

The string "&app; &appversion; User Manual" will be expanded to "GNU Solfege x.y.z User Manual" where "x.y.z" is the version of the program. You should translate the words "User Manual", and it is ok to change the order and placement in the string of &app and &appversion

msgid "&app; &appversion; User Manual"
msgstr ""

User comments

Add your own comment