Re: Routine for prefixing '' before every line of a string

2006-12-16 Thread Sanjay
Thanks a lot, guys! sanjay -- http://mail.python.org/mailman/listinfo/python-list

Routine for prefixing '' before every line of a string

2006-12-14 Thread Sanjay
Hi All, Is somewhere a routine useful to convert a string to lines of maxsize, each prefixed with a ''. This is a typical requirement for 'keeping existing text while replying to a post in a forum'. It can be developed, but if something obvious is already there(I being new to python might not be

Re: Routine for prefixing '' before every line of a string

2006-12-14 Thread Boris Borcic
Sanjay wrote: Hi All, Is somewhere a routine useful to convert a string to lines of maxsize, each prefixed with a ''. This is a typical requirement for 'keeping existing text while replying to a post in a forum'. It can be developed, but if something obvious is already there(I being new

Re: Routine for prefixing '' before every line of a string

2006-12-14 Thread Peter Otten
Sanjay wrote: Is somewhere a routine useful to convert a string to lines of maxsize, each prefixed with a ''. This is a typical requirement for 'keeping existing text while replying to a post in a forum'. import textwrap format = textwrap.TextWrapper(20, initial_indent=] ,

Re: Routine for prefixing '' before every line of a string

2006-12-14 Thread Roberto Bonvallet
Sanjay wrote: Is somewhere a routine useful to convert a string to lines of maxsize, each prefixed with a ''. This is a typical requirement for 'keeping existing text while replying to a post in a forum'. Take a look to the textwrap module: http://docs.python.org/lib/module-textwrap.html Here

Re: Routine for prefixing '' before every line of a string

2006-12-14 Thread Neil Cerutti
On 2006-12-14, Roberto Bonvallet [EMAIL PROTECTED] wrote: Sanjay wrote: Is somewhere a routine useful to convert a string to lines of maxsize, each prefixed with a ''. This is a typical requirement for 'keeping existing text while replying to a post in a forum'. Take a look to the textwrap