Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(68)  |  Call(28)  |  Derive(5)  |  Import(35)
An extended translation catalog class.

src/p/l/Plurk_Solace-0.1/solace/i18n/__init__.py   Plurk_Solace(Download)
 
from babel import Locale, dates, numbers, UnknownLocaleError
from babel.support import Translations
from werkzeug.exceptions import NotFound
 
        else:
            with open(catalog, 'rb') as f:
                rv = Translations(fileobj=f, domain=LOCALE_DOMAIN)
        _translations[key] = rv
    return rv

src/s/o/solace-HEAD/solace/i18n/__init__.py   solace(Download)
 
from babel import Locale, dates, numbers, UnknownLocaleError
from babel.support import Translations
from werkzeug.exceptions import NotFound
 
        else:
            with open(catalog, 'rb') as f:
                rv = Translations(fileobj=f, domain=LOCALE_DOMAIN)
        _translations[key] = rv
    return rv

src/m/e/mediadrop-HEAD/mediadrop/lib/i18n.py   mediadrop(Download)
    format_datetime as _format_datetime, format_time as _format_time)
from babel.numbers import format_decimal as _format_decimal
from babel.support import Translations
from babel.util import LOCALTZ
from pylons import config, request, translator
                msg = 'No %r translations found for %r in %r.'
                raise LanguageError(msg % (domain, self._languages, locale_dirs))
            translations = Translations(domain=domain)
            for translation in translation_list:
                translations.merge(translation)

src/b/l/bloodhound-HEAD/trac/trac/dist.py   bloodhound(Download)
                                        compile_catalog, update_catalog
    from babel.messages.pofile import read_po
    from babel.support import Translations
    from babel.util import parse_encoding
 
 
                with open(mo_file, 'rb') as infile:
                    t = Translations(infile, self.domain)
                    catalog = t._catalog
 

src/t/r/Trac-1.0.1/trac/dist.py   Trac(Download)
                                        compile_catalog, update_catalog
    from babel.messages.pofile import read_po
    from babel.support import Translations
    from babel.util import parse_encoding
 
 
                with open(mo_file, 'rb') as infile:
                    t = Translations(infile, self.domain)
                    catalog = t._catalog
 

src/t/r/trac-HEAD/trac/dist.py   trac(Download)
                                        compile_catalog, update_catalog
    from babel.messages.pofile import read_po
    from babel.support import Translations
    from babel.util import parse_encoding
 
 
                with open(mo_file, 'rb') as infile:
                    t = Translations(infile, self.domain)
                    catalog = t._catalog
 

src/o/p/openlibrary-HEAD/openlibrary/i18n/__init__.py   openlibrary(Download)
 
import babel
from babel.support import Translations
from babel.messages import Catalog
from babel.messages.pofile import read_po, write_po
 
    if os.path.exists(mo_path):
        return Translations(open(mo_path))
 
@web.memoize

src/b/l/bloodhound-HEAD/trac/trac/util/translation.py   bloodhound(Download)
try:
    from babel import Locale
    from babel.support import LazyProxy, Translations
 
    class TranslationsProxy(object):

src/t/r/Trac-1.0.1/trac/util/translation.py   Trac(Download)
try:
    from babel import Locale
    from babel.support import LazyProxy, Translations
 
    class TranslationsProxy(object):

src/i/n/indico-HEAD/indico/util/translations.py   indico(Download)
 
 
from babel.support import Translations, LazyProxy as _LazyProxy
from babel.core import Locale
from gettext import NullTranslations
class LazyTranslations(Translations):
    """
    Defers translation in case there is still no translation available
    It will be then done when the value is finally used
    """

  1 | 2 | 3 | 4 | 5  Next