• Home
  • Raw
  • Download

Lines Matching +full:- +full:gettext

4 support for your Python programs by providing an interface to the GNU gettext
17 # C-based libintlmodule (later renamed _gettext), along with a skeletal
18 # gettext.py implementation.
21 # which also included a pure-Python implementation to read .mo files if
24 # James Henstridge, who also wrote a gettext.py module, which has some
32 # Francois Pinard and Marc-Andre Lemburg also contributed valuably to this
38 # - Lazy loading of .mo files. Currently the entire catalog is loaded into
42 # the undocumented double-hash algorithm for .mo files with hash tables, but
43 # you'll need to study the GNU gettext code to do this.
45 # - Support Solaris .mo file formats. Unfortunately, we've been unable to
57 'textdomain', 'dgettext', 'dngettext', 'gettext',
66 # The gettext library supports a small subset of C syntax. The only
70 # https://www.gnu.org/software/gettext/manual/gettext.html#Plural-forms
71 # http://git.savannah.gnu.org/cgit/gettext.git/tree/gettext-runtime/intl/plural.y
75 (?P<NUMBER>[0-9]+\b) | # decimal integer
78 (?P<OPERATOR>[-*/%+?:]|[><!]=?|==|&&|\|\|) | # !, *, /, %, +, -, <, >,
111 ('+', '-'),
118 def _parse(tokens, priority=-1):
216 depth -= 1
290 def gettext(self, message): member in NullTranslations
292 return self._fallback.gettext(message)
326 builtins.__dict__['_'] = self.gettext
328 allowed = {'gettext', 'ngettext', 'npgettext', 'pgettext'}
339 # msgctxt + "\x04" + msgid (gettext version >= 0.15)
351 # Delay struct import for speeding up gettext import when .mo files
398 if item.startswith('#-#-#-#-#') and item.endswith('#-#-#-#-#'):
409 if k == 'content-type':
411 elif k == 'plural-forms':
417 # parameter of the Content-Type header. The gettext documentation
418 # strongly encourages msgids to be us-ascii, but some applications
420 # traditional gettext applications, the msgid conversion will
421 # cause no problems since us-ascii should always be a subset of
422 # the charset encoding. We may want to fall back to 8-bit msgids
438 def gettext(self, message): member in GNUTranslations
446 return self._fallback.gettext(message)
487 # Locate a .mo file using the gettext strategy
551 # Delay copy import for speeding up gettext import when .mo files
569 # current global domain, `messages' used for compatibility w/ GNU gettext
592 return t.gettext(message)
627 def gettext(message): function
645 # James Henstridge's Catalog constructor from GNOME gettext. Documented usage
648 # import gettext
649 # cat = gettext.Catalog(PACKAGE, localedir=LOCALEDIR)
650 # _ = cat.gettext
655 # gettext.