A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2002-June/025073.html below:

[Python-Dev] Where to put wrap_text()?

[Python-Dev] Where to put wrap_text()? [Python-Dev] Where to put wrap_text()?Greg Ward gward@python.net
Thu, 6 Jun 2002 11:20:11 -0400
On 01 June 2002, Tim Peters said:
> [Greg Ward, on wrapping text]
> > ...
> 
> Note that regrtest.py also has a wrapper:
> 
> def printlist(x, width=70, indent=4):
>     """Print the elements of a sequence to stdout.
> 
>     Optional arg width (default 70) is the maximum line length.
>     Optional arg indent (default 4) is the number of blanks with which to
>     begin each line.
>     """

I think this one will probably stand; I've gotten to the point with my
text-wrapping code where I'm reimplementing the various other
text-wrappers people have mentioned on top of it, and
regrtest.printlist() is just not a good fit.  It's for printing
lists compactly, not for filling text.  Whatever.

> Just make sure it handle the union of all possible desires, but has a simple
> and intuitive interface <wink>.

Right.  Gotcha.  Code coming up soon.

        Greg
-- 
Greg Ward - Unix weenie                                 gward@python.net
http://starship.python.net/~gward/
Quick!!  Act as if nothing has happened!




RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4