{ "info": { "author": "Chris Withers", "author_email": "chris@simplistix.co.uk", "bugtrack_url": null, "classifiers": [], "description": "===============\r\nsx.translations\r\n===============\r\n\r\nThis package provides components for use with Zope 3 and Zope 2 +\r\nFive that implement both ITranslationDomain and\r\nILanguageAvailability as well as supporting the recording of\r\nuntranslated msgids. This means that, not only do the components\r\nsupport the interface require to provide message to Zope 3's i18n\r\nframework, they can also be used to generate a list of avaiable\r\nlanguages using code similar to the following::\r\n\r\n from zope.component import getUtility\r\n from zope.i18n.interfaces import ILanguageAvailability\r\n from zope.i18n.locales import locales, LoadLocaleError\r\n\r\n domain = 'myproject'\r\n\r\n def getLanguages(self):\r\n options = getUtility(ILanguageAvailability,\r\n domain).getAvailableLanguages()\r\n options.sort()\r\n result = []\r\n for option in options:\r\n lang = option[0]\r\n try:\r\n locale = locales.getLocale(lang)\r\n except LoadLocaleError:\r\n # probably not a real locale\r\n continue\r\n result.append(\r\n {'code':lang,\r\n 'name':locale.displayNames.languages[lang],}\r\n )\r\n return result\r\n\r\nRequirements\r\n------------\r\n\r\nZope 2.12.0 or higher is required.\r\n\r\nInstallation\r\n------------\r\n\r\nTo install, simply place the sx folder contained in the distribution\r\nonto your PYTHONPATH.\r\n\r\nConfiguration\r\n-------------\r\n\r\nConfiguration is through ZCML, a complete example of which is\r\nshows below::\r\n\r\n \r\n\r\n \r\n \r\n\r\n \r\n \r\n\r\n \r\n\r\n`locales` is a path pointing to a folder containing locale\r\ninformation in the standard GNU gettext layout, as currently\r\nsupported by Zope 3.\r\n\r\n`missing` is a file to which untranslated msgids will be appended in\r\n.pot fortmat.\r\n\r\n`encoding` is optional and specifies the encoding to use for the\r\nfile specified in the \"missing\" attribute. If not supplied, a\r\ndefault of utf-8 is used.\r\n\r\nLicensing\r\n---------\r\n\r\nCopyright (c) 2006-2009 Simplistix Ltd\r\n\r\nThis Software is released under the MIT License:\r\nhttp://www.opensource.org/licenses/mit-license.html\r\nSee license.txt for more details.\r\n\r\nChanges\r\n-------\r\n\r\n1.2 (16 Apr 2009)\r\n-----------------\r\n\r\n- record dates when missing msgids are found\r\n\r\n1.1 (12 Apr 2009)\r\n-----------------\r\n\r\n- bring up to date for zope.i18n 3.7.0\r\n\r\n1.0 (18 Sep 2006)\r\n-----------------\r\n\r\n- Initial release", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "http://www.simplistix.co.uk/software/zope/sx.translations", "keywords": null, "license": "MIT", "maintainer": null, "maintainer_email": null, "name": "sx.translations", "package_url": "https://pypi.org/project/sx.translations/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/sx.translations/", "project_urls": { "Download": "UNKNOWN", "Homepage": "http://www.simplistix.co.uk/software/zope/sx.translations" }, "release_url": "https://pypi.org/project/sx.translations/1.2/", "requires_dist": null, "requires_python": null, "summary": "An enhanced version of zope.i18n.translationdomain", "version": "1.2" }, "last_serial": 800304, "releases": { "1.0": [], "1.1": [ { "comment_text": "", "digests": { "md5": "ea580638cb659a919dab0fdaba01b41d", "sha256": "af9dce6583de5064faa54680f8e1e0e84107f33dae917443806027243de41efc" }, "downloads": -1, "filename": "sx.translations-1.1.tar.gz", "has_sig": false, "md5_digest": "ea580638cb659a919dab0fdaba01b41d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8269, "upload_time": "2009-04-13T00:35:30", "url": "https://files.pythonhosted.org/packages/3b/73/14aeca54e149d3bf1201df64473495214f2fb0b5348d44604c084207957a/sx.translations-1.1.tar.gz" } ], "1.2": [ { "comment_text": "", "digests": { "md5": "b1920d320b1c46b0aa08cdbbafb390b6", "sha256": "c5673694036a97f1ee5ed0acd4b31fcaae30a45093bfa57d30e3363bd71e536a" }, "downloads": -1, "filename": "sx.translations-1.2.tar.gz", "has_sig": false, "md5_digest": "b1920d320b1c46b0aa08cdbbafb390b6", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8560, "upload_time": "2009-04-16T16:35:59", "url": "https://files.pythonhosted.org/packages/b9/1a/1680e938af36ec066e259a8040bf16906c3bccc4b81b6fbf2e4c547ca2f0/sx.translations-1.2.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "b1920d320b1c46b0aa08cdbbafb390b6", "sha256": "c5673694036a97f1ee5ed0acd4b31fcaae30a45093bfa57d30e3363bd71e536a" }, "downloads": -1, "filename": "sx.translations-1.2.tar.gz", "has_sig": false, "md5_digest": "b1920d320b1c46b0aa08cdbbafb390b6", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8560, "upload_time": "2009-04-16T16:35:59", "url": "https://files.pythonhosted.org/packages/b9/1a/1680e938af36ec066e259a8040bf16906c3bccc4b81b6fbf2e4c547ca2f0/sx.translations-1.2.tar.gz" } ] }