gettext switch language on the fly

Peter Irbizon peterirbizon at gmail.com
Fri Jul 29 03:20:45 CEST 2011


hello,
I am using gettext fo localization
        local_path=os.path.join(module_path(), lang_folder)
        gettext.bindtextdomain(lang_name, local_path)
        gettext.textdomain(lang_name)
        # Get the language to use
        lang = gettext.translation(lang_name, local_path, languages=['sk'],
fallback = True)
        lang.install()

Now I would like to switch all texts in my app when I click on item in menu.
Unfortunatelly this not switch texts immediately. How can I do this?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20110729/6b257ef2/attachment.html>


More information about the Python-list mailing list