International APPs / pygettext

Denis S. Otkidach ods at strana.ru
Fri Oct 18 17:49:35 CEST 2002


On Fri, 18 Oct 2002, Ingo Linkweiler wrote:

IL> I now use this way to set languages:
IL>
IL> import gettext
IL> lang = gettext.translation("messages",".",languages=['en'])
IL> lang.install()
IL>
IL> But how can I install the internal language (=no
IL> translation) ?
IL> Defining
IL>
IL> def _(x): return x
IL>
IL> is not a good solution, because this does not change ALL
IL> used modules.

The only builtin namespace is available directly to all modules:

import __biltin__
__biltin__ = lambda m: m

-- 
Denis S. Otkidach
http://www.python.ru/      [ru]





More information about the Python-list mailing list