Andre Delfino
b420428cf5
Document actual string.punctuation value. (GH-12270)
2019-03-14 21:28:31 +02:00
Andrés Delfino
d64991031e
Correct grammar mistakes in string.rst. (GH-9752)
2018-11-07 19:24:56 +02:00
Serhiy Storchaka
3f819ca138
bpo-35110: Fix unintentional spaces around hyphens and dashes. (GH-10231)
2018-10-31 02:26:06 +02:00
Serhiy Storchaka
913876d824
bpo-35054: Add yet more index entries for symbols. (GH-10121)
2018-10-28 13:41:26 +02:00
Serhiy Storchaka
ddb961d2ab
bpo-35054: Add more index entries for symbols. (GH-10064)
2018-10-26 09:00:49 +03:00
Terry Jan Reedy
28c7f8c8ce
bpo-34273: Change 'Fixed point' to 'Fixed-point notation'. ( #8673 )
...
* bpo-34273: Change 'Fixed point' to 'Fixed-point notation'.
The change in the mini language floating point and decimal table
is consistent with 'Exponential notation' and clarifies that we
are referring to the output notation, not an object type.
* Update string.rst
* Update string.rst
* Update string.rst
* Update string.rst
2018-08-06 08:41:17 -04:00
Xiang Zhang
b9d8ad5130
bpo-33828: Add missing versionchanged note for string.Formatter. (GH-7668)
...
string.Formatter auto-numbering feature was added in 3.4 and there
is no versionchanged note in its documentation, making the documentation
ambiguous about which version the feature is available.
2018-06-13 09:42:44 +08:00
Mariatta
7a561afd2c
bpo-32720: Fixed the replacement field grammar documentation. (GH-5544)
...
`arg_name` and `element_index` are defined as `digit`+ instead of `integer`.
2018-02-05 04:29:02 -05:00
nathankerr96
8b5fa289fd
bpo-32720: Fixed the definition for width and precision in format mini-language doc (GH-5482)
...
Changed the definition of width and precision from "integer" to "digit+" in format mini-language doc.
2018-02-04 00:42:08 -05:00
Serhiy Storchaka
87be28f4a1
bpo-31672: Restore the former behavior when override flags in Template. ( #5099 )
...
Overriding flags to 0 will make the default pattern matching only
lower case letters.
2018-01-04 19:20:11 +02:00
Barry Warsaw
e256b40888
bpo-31672 - Add one last minor clarification for idpattern ( #4483 )
...
Add one last minor clarification for idpattern
2017-11-21 10:28:13 -05:00
INADA Naoki
073150db39
bpo-31672: doc: Remove one sentence from library/string.rst (GH-3990)
...
This sentence is removed while backporting to 3.6 branch.
See https://github.com/python/cpython/pull/3982#discussion_r144555768
2017-10-14 21:22:41 +09:00
INADA Naoki
b22273ec5d
bpo-31672: Fix string.Template accidentally matched non-ASCII identifiers (GH-3872)
...
Pattern `[a-z]` with `IGNORECASE` flag can match to some non-ASCII characters.
Straightforward solution for this is using `IGNORECASE | ASCII` flag.
But users may subclass `Template` and override only `idpattern`. So we want to
avoid changing `Template.flags`.
So this commit uses local flag `-i` for `idpattern` and change `[a-z]` to `[a-zA-Z]`.
2017-10-13 16:02:23 +09:00
Barry Warsaw
ba4279683f
bpo-1198569: Allow string.Template braced pattern to be different ( #3288 )
...
* bpo-1198569: Allow the braced pattern to be different
``string.Template`` subclasses can optionally define ``braceidpattern`` if
they want to specify different placeholder patterns inside and outside the
braces. If None (the default) it falls back to ``idpattern``.
2017-09-04 16:32:10 -04:00
Barry Warsaw
9f74deba78
Improve the documentation for template strings ( #856 )
...
bpo-19824
bpo-20314
bpo-12518
2017-03-28 10:02:07 -04:00
Serhiy Storchaka
009b0a1fac
Issue #29193 : A format string argument for string.Formatter.format()
...
is now positional-only.
2017-01-13 09:10:51 +02:00
Serhiy Storchaka
989db5c880
Issue #19795 : Mark up None as literal text.
2016-10-19 16:37:13 +03:00
Serhiy Storchaka
ecf41da83e
Issue #19795 : Mark up None as literal text.
2016-10-19 16:29:26 +03:00
Eric V. Smith
d7665ca7a4
Further improved ',' and '_' specification in format mini-language.
2016-09-09 23:13:01 -04:00
Eric V. Smith
fef4391c88
Improved ',' and '_' specification in format mini-language.
2016-09-09 23:12:02 -04:00
Eric V. Smith
89e1b1aae0
Issue 27080: PEP 515: add '_' formatting option.
2016-09-09 23:06:47 -04:00
Serhiy Storchaka
c499f30286
Issue #23921 : Standardized documentation whitespace formatting.
...
Original patch by James Edwards.
2016-05-10 12:01:56 +03:00
Serhiy Storchaka
dba903993a
Issue #23921 : Standardized documentation whitespace formatting.
...
Original patch by James Edwards.
2016-05-10 12:01:23 +03:00
Terry Jan Reedy
370764a824
Merge with 3.5
2016-03-20 21:06:15 -04:00
Terry Jan Reedy
4902c46bff
Issue #15660 : Further clarify 0 prefix for width specifier in formats.
2016-03-20 21:05:57 -04:00
Martin Panter
bc1ee460dc
Issue #25179 : Documentation for formatted string literals aka f-strings
...
Some of the inspiration and wording is taken from the text of PEP 498 by Eric
V. Smith, and the existing str.format() documentation.
2016-02-13 00:41:37 +00:00
Martin Panter
d5db14794b
Issue #25179 : Preparatory cleanup of existing docs on string formatting
...
* Various sections were pointing to the section on the string.Formatter
class, when the section on the common format string syntax is probably more
appropriate
* Fix references to various format() functions and methods
* Nested replacement fields may contain conversions and format specifiers,
and this is tested; see Issue #19729 for instance
2016-02-08 01:34:09 +00:00
Barry Warsaw
9380acbbf7
- Issue #24351 : Clarify what is meant by "identifier" in the context of
...
string.Template instances.
2015-06-09 14:22:44 -04:00
Barry Warsaw
17d5f47423
- Issue #24351 : Clarify what is meant by "identifier" in the context of
...
string.Template instances.
2015-06-09 14:20:31 -04:00
Serhiy Storchaka
b876df4cbb
Issue #23671 : string.Template now allows to specify the "self" parameter as
...
keyword argument. string.Formatter now allows to specify the "self" and
the "format_string" parameters as keyword arguments.
2015-03-24 22:30:46 +02:00
Terry Jan Reedy
c6ad57608b
Issue #22546 : update doc for mini-language float None presentation type.
2014-10-06 02:04:33 -04:00
Ezio Melotti
2bbdfe7eda
#19238 : fix typo in documentation.
2013-11-17 02:47:12 +02:00
Ezio Melotti
c318442571
#19238 , #19289 : fix description of the align and fill values of the format specification.
2013-10-21 02:53:07 +03:00
Eric V. Smith
45fe62dc9c
Issue #17728 : Specify default precision for float.format for presentation types e, f, and g.
2013-04-15 09:51:54 -04:00
Ezio Melotti
4d6795e1a2
#17265 : merge with 3.2.
2013-02-21 12:35:40 +02:00
Ezio Melotti
bcbc5678d5
#17265 : fix highlight in template example. Initial patch by Berker Peksag.
2013-02-21 12:30:32 +02:00
Ezio Melotti
5a4b03dd82
#16154 : merge with 3.2.
2013-01-11 09:12:28 +02:00
Ezio Melotti
405079213b
#16154 : fix some doctests in Doc/library. Patch by Ravi Sinha.
2013-01-11 09:09:07 +02:00
Ezio Melotti
7768dd77c1
#16556 : merge with 3.2.
2012-11-27 19:18:47 +02:00
Ezio Melotti
28c88f48f9
#16556 : Fix inconsistency between kwds and kwargs. Patch by Taavi Burns.
2012-11-27 19:17:57 +02:00
Ezio Melotti
a6229e6ebd
Fix and add more links.
2012-10-12 10:59:14 +03:00
R David Murray
e56bf97ef4
#13579 : teach string.Formatter about 'a'.
...
Patch by Francisco Martín Brugué.
2012-08-19 17:26:34 -04:00
Terry Jan Reedy
f6190c1463
Issue 15660: Clarify 0 prefix for width field in str.format doc.
2012-08-17 15:40:46 -04:00
Sandro Tosi
38b86b4cf5
correctly define what 'fill' could be; thanks to Leland Hulbert from docs@
2012-05-12 23:29:32 +02:00
Sandro Tosi
baf30da240
remove spurious dot from string formatting example; thanks to Anthon van der Neut from docs@
2011-12-24 15:53:35 +01:00
Ezio Melotti
e130a52d8a
Remove duplication.
2011-10-19 10:58:56 +03:00
Éric Araujo
29cf58c9d5
Document that format string don’t support arbitrary dictonary keys.
...
Text adapted from the PEP. Addition requested by Terry J. Reedy on
2011-02-23 on python-dev.
2011-09-01 18:59:06 +02:00
Éric Araujo
19f9b71ffe
Add a few missing source links from 2.7 and harmonize lib docs headers
2011-08-19 00:49:18 +02:00
Eli Bendersky
ebd4805df0
Fix grammar
2011-08-06 09:31:09 +03:00
Georg Brandl
ca583b66c8
#8691 : document that right alignment is default for numbers.
2011-02-07 12:13:58 +00:00