[Tex/LaTex] Managing multiple translation of a single document

languages

Consider that you are working on a standard that should be translated into some other languages. The document structure (figures, table structures, …) is constant among languages. Is there any facility/technique/strategy/package to streamline multilingual documents production?

Is it possible to use a gettex-like method in (la)tex?

Best Answer

There is another way to support internationalization within your LaTeX documents. For instance, below is the support for english and german languages I made some time ago:

\newif\ifen
\newif\ifde

\newcommand{\en}[1]{\ifen#1\fi}
\newcommand{\de}[1]{\ifde#1\fi}

Next, if you need you can define different commands for months, date formats, etc:

\newcommand{\jan}{%
  \en{January}%
  \de{Januar}%
}

Finally, in text you can write something like this:

\en{English text.}
\de{Deutscher Text.}

After all, when you've created the whole document you can simple switch between languages setting in the document preamble either \entrue or \detrue. All this allows you to keep multilingual texts up-to-dated near each other.