diff options
| author | Steve Piercy <web@stevepiercy.com> | 2018-11-20 01:11:09 -0800 |
|---|---|---|
| committer | Steve Piercy <web@stevepiercy.com> | 2018-11-20 01:11:09 -0800 |
| commit | b1c500c3d4cb269aed254742501040c1c64367c2 (patch) | |
| tree | 00c9160a2f9ac1d8a50bdc8ab28088e3a7aa3c82 | |
| parent | c9d5832707877faac5b94943e00951b69192185d (diff) | |
| download | pyramid-b1c500c3d4cb269aed254742501040c1c64367c2.tar.gz pyramid-b1c500c3d4cb269aed254742501040c1c64367c2.tar.bz2 pyramid-b1c500c3d4cb269aed254742501040c1c64367c2.zip | |
s/msgid/``msgid`` as needed
| -rw-r--r-- | docs/narr/i18n.rst | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/docs/narr/i18n.rst b/docs/narr/i18n.rst index 3a4f5af5b..b8cd396c0 100644 --- a/docs/narr/i18n.rst +++ b/docs/narr/i18n.rst @@ -62,7 +62,7 @@ This creates a ``str``-like object that is a TranslationString. The first argument to :class:`~pyramid.i18n.TranslationString` is the ``msgid``; it is required. It represents the key into the translation mappings provided by a particular localization. The ``msgid`` argument must be a string. -The msgid may optionally contain *replacement markers*. For instance: +The ``msgid`` may optionally contain *replacement markers*. For instance: .. code-block:: python :linenos: @@ -80,14 +80,14 @@ may be supplied at the same time as the replacement marker itself: from pyramid.i18n import TranslationString ts = TranslationString('Add ${number}', mapping={'number':1}) -Any number of replacement markers can be present in the msgid value, any number +Any number of replacement markers can be present in the ``msgid`` value, any number of times. Only markers which can be replaced by the values in the *mapping* will be replaced at translation time. The others will not be interpolated and will be output literally. A translation string should also usually carry a *domain*. The domain represents a translation category to disambiguate it from other translations of -the same msgid, in case they conflict. +the same ``msgid``, in case they conflict. .. code-block:: python :linenos: @@ -99,7 +99,7 @@ the same msgid, in case they conflict. The above translation string named a domain of ``form``. A :term:`translator` function will often use the domain to locate the right translator file on the filesystem which contains translations for a given domain. In this case, if it -were trying to translate our msgid to German, it might try to find a +were trying to translate our ``msgid`` to German, it might try to find a translation from a :term:`gettext` file within a :term:`translation directory` like this one: |
