Re: textwrap.wrap() breaks non-breaking spaces

2015-05-21 Thread Roy Smith
In article , Johannes Bauer wrote: > so that textwrap.wrap() breks non-breaking spaces, is this a bug or > intended behavior? I opened http://bugs.python.org/issue16623 on this a couple of years ago. Looks like it was being worked (http://bugs.python.org/issue20491) but got stalled in the te

Re: textwrap.wrap() breaks non-breaking spaces

2015-05-17 Thread Ned Batchelder
On Sunday, May 17, 2015 at 3:40:07 PM UTC-4, Johannes Bauer wrote: > Hey there, > > so that textwrap.wrap() breks non-breaking spaces, is this a bug or > intended behavior? For example: > > Python 3.4.0 (default, Apr 11 2014, 13:05:11) > [GCC 4.8.2] on linux > > >>> import textwrap > >>> for lin

Re: textwrap.wrap() breaks non-breaking spaces

2015-05-17 Thread Tim Chase
On 2015-05-17 21:39, Johannes Bauer wrote: > Hey there, > > so that textwrap.wrap() breks non-breaking spaces, is this a bug or > intended behavior? For example: > > Python 3.4.0 (default, Apr 11 2014, 13:05:11) > [GCC 4.8.2] on linux > > >>> import textwrap > >>> for line in textwrap.wrap("foo

textwrap.wrap() breaks non-breaking spaces

2015-05-17 Thread Johannes Bauer
Hey there, so that textwrap.wrap() breks non-breaking spaces, is this a bug or intended behavior? For example: Python 3.4.0 (default, Apr 11 2014, 13:05:11) [GCC 4.8.2] on linux >>> import textwrap >>> for line in textwrap.wrap("foo dont\xa0break " * 20): print(line) ... foo dont break foo dont