@@ -18,7 +18,7 @@ know all the specifics of each country where the software is executed.
1818
1919.. index :: pair: module; _locale
2020
21- The :mod: `locale ` module is implemented on top of the :mod: `_locale ` module,
21+ The :mod: `locale ` module is implemented on top of the :mod: `! _locale ` module,
2222which in turn uses an ANSI C locale implementation if available.
2323
2424The :mod: `locale ` module defines the following exception and functions:
@@ -192,7 +192,13 @@ The :mod:`locale` module defines the following exception and functions:
192192 Get a format string for :func: `time.strftime ` to represent time in the am/pm
193193 format.
194194
195- .. data :: DAY_1 ... DAY_7
195+ .. data :: DAY_1
196+ DAY_2
197+ DAY_3
198+ DAY_4
199+ DAY_5
200+ DAY_6
201+ DAY_7
196202
197203 Get the name of the n-th day of the week.
198204
@@ -202,15 +208,43 @@ The :mod:`locale` module defines the following exception and functions:
202208 international convention (ISO 8601) that Monday is the first day of the
203209 week.
204210
205- .. data :: ABDAY_1 ... ABDAY_7
211+ .. data :: ABDAY_1
212+ ABDAY_2
213+ ABDAY_3
214+ ABDAY_4
215+ ABDAY_5
216+ ABDAY_6
217+ ABDAY_7
206218
207219 Get the abbreviated name of the n-th day of the week.
208220
209- .. data :: MON_1 ... MON_12
221+ .. data :: MON_1
222+ MON_2
223+ MON_3
224+ MON_4
225+ MON_5
226+ MON_6
227+ MON_7
228+ MON_8
229+ MON_9
230+ MON_10
231+ MON_11
232+ MON_12
210233
211234 Get the name of the n-th month.
212235
213- .. data :: ABMON_1 ... ABMON_12
236+ .. data :: ABMON_1
237+ ABMON_2
238+ ABMON_3
239+ ABMON_4
240+ ABMON_5
241+ ABMON_6
242+ ABMON_7
243+ ABMON_8
244+ ABMON_9
245+ ABMON_10
246+ ABMON_11
247+ ABMON_12
214248
215249 Get the abbreviated name of the n-th month.
216250
@@ -229,14 +263,14 @@ The :mod:`locale` module defines the following exception and functions:
229263
230264 .. data :: NOEXPR
231265
232- Get a regular expression that can be used with the regex(3) function to
266+ Get a regular expression that can be used with the `` regex(3) `` function to
233267 recognize a negative response to a yes/no question.
234268
235269 .. note ::
236270
237271 The regular expressions for :const: `YESEXPR ` and
238272 :const: `NOEXPR ` use syntax suitable for the
239- :c:func: ` regex ` function from the C library, which might
273+ `` regex ` ` function from the C library, which might
240274 differ from the syntax used in :mod: `re `.
241275
242276 .. data :: CRNCYSTR
@@ -581,9 +615,9 @@ the locale is ``C``).
581615
582616When Python code uses the :mod: `locale ` module to change the locale, this also
583617affects the embedding application. If the embedding application doesn't want
584- this to happen, it should remove the :mod: `_locale ` extension module (which does
618+ this to happen, it should remove the :mod: `! _locale ` extension module (which does
585619all the work) from the table of built-in modules in the :file: `config.c ` file,
586- and make sure that the :mod: `_locale ` module is not accessible as a shared
620+ and make sure that the :mod: `! _locale ` module is not accessible as a shared
587621library.
588622
589623
@@ -597,17 +631,18 @@ Access to message catalogs
597631.. function :: dcgettext(domain, msg, category)
598632.. function :: textdomain(domain)
599633.. function :: bindtextdomain(domain, dir)
634+ .. function :: bind_textdomain_codeset(domain, codeset)
600635
601636The locale module exposes the C library's gettext interface on systems that
602- provide this interface. It consists of the functions :func: `! gettext `,
603- :func: `! dgettext `, :func: `! dcgettext `, :func: `! textdomain `, :func: `! bindtextdomain `,
604- and :func: `! bind_textdomain_codeset `. These are similar to the same functions in
637+ provide this interface. It consists of the functions :func: `gettext `,
638+ :func: `dgettext `, :func: `dcgettext `, :func: `textdomain `, :func: `bindtextdomain `,
639+ and :func: `bind_textdomain_codeset `. These are similar to the same functions in
605640the :mod: `gettext ` module, but use the C library's binary format for message
606641catalogs, and the C library's search algorithms for locating message catalogs.
607642
608643Python applications should normally find no need to invoke these functions, and
609644should use :mod: `gettext ` instead. A known exception to this rule are
610645applications that link with additional C libraries which internally invoke
611- :c:func: ` gettext ` or :c:func: ` dcgettext `. For these applications, it may be
646+ C functions `` gettext `` or `` dcgettext ` `. For these applications, it may be
612647necessary to bind the text domain, so that the libraries can properly locate
613648their message catalogs.
0 commit comments