[New-bugs-announce] [issue4163] textwrap wordsep_re Unicode

Sebastian Kirsche report at bugs.python.org
Tue Oct 21 22:05:23 CEST 2008


New submission from Sebastian Kirsche <sebastian.kirsche at gmail.com>:

The attached patch makes textwrap work with strings containing dashes 
and Unicode alphabetic characters. In addition, it fixes the test case 
for issue 1149508, which no longer failed after temporarily undoing the 
corresponding change.


Example 1:
    print textwrap.fill(u'Die Empfänger-Auswahl', 13)

Output without patch: 
    Die Empf
    änger-Auswahl

With patch:
    Die
    Empfänger-
    Auswahl


Example 2:
    print textwrap.fill(u'aa ää-ää', 7)

Output without patch:
    aa
    ää-ää

With patch:
    aa ää-
    ää

----------
components: Library (Lib)
files: textwrap-umlauts.patch
keywords: patch
messages: 75037
nosy: skirsche
severity: normal
status: open
title: textwrap wordsep_re Unicode
type: behavior
versions: Python 2.5, Python 2.5.3, Python 2.6, Python 2.7
Added file: http://bugs.python.org/file11848/textwrap-umlauts.patch

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue4163>
_______________________________________


More information about the New-bugs-announce mailing list