Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I need to write a manual to the software I made. If it possible to use gettext when writing a manual, or other documents?

share|improve this question

2 Answers 2

up vote 5 down vote accepted

Check out Sphinx to write your documents in reStructuredText and make them translatable in gettext format.

share|improve this answer
1  
Exactly what I've been looking for. Thanks for answering even though the question is very old! –  Rafał Cieślak Oct 10 '11 at 18:30

afaik gettext is useful when you have a programming language which contains strings, that is when strings are intermixed with code.

alert(_("Hello"));

Then a preprocessor finds all occurrences of _("..") and generates a .po template and then you copy that edit that .po file translating "Hello" to your language:

msgid "Hello"
msgstr "Cześć"

gettext is aimed to solve the problems you encounter when you use string inside a programming language, typically format strings with positional arguments, plurals, duals (some languages have duals), etc, stuff which might change the translation due to runtime parameters.

This kind of things is not necessary on manuals, because manuals normally don't have runtime parameters which change the sentences.

The only advantage I see of using gettext would be to preserve markup, but usually markup (in latex, docbook etc) is an operation that defines your structure so it's part of the semantics of your documentation, while the appareance should be handled in a different place (css, etc).

I don't feel that the ability to isolate the translation from the markup will be a big advantage, considering the noise that xgettext tags will introduce in your documentation markup language.

(Furthermore I don't know of any tools that would preprocess and postprocess latex/docbook/whatever with gettext)

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.