On this page
  1. gettext.NullTranslations
  2. Import
  3. Signature & Overview
  4. Methods & Attributes
  5. Usage
  6. Gotchas
  7. REPL Inspect

gettext.NullTranslations

Prev: gettext.npgettext | Up: gettext | Next: gettext.pgettext
Rel: gettext.bindtextdomain, gettext.Catalog, gettext.dgettext, gettext.dngettext
Ref: docs.python.org — gettext.NullTranslations
Tags: #public #python3 #stdlib #gettext


Import

import gettext
from gettext import NullTranslations

Signature & Overview

gettext.NullTranslations(fp=None)

gettext.NullTranslations class.

Methods & Attributes

Usage

import gettext

t = gettext.NullTranslations()
assert t.gettext("Save") == "Save"
assert t.ngettext("%d item", "%d items", 2) == "%d items"

Gotchas

REPL Inspect

from gettext import NullTranslations
help(NullTranslations)

Linked from

Related notes