Re: Line Wrapping

2007-06-18 Thread Evan Klitzke
On 6/18/07, TeroV <[EMAIL PROTECTED]> wrote: > Evan Klitzke wrote: > > All, > > > > Mail messages should be wrapped at 78 characters (as suggested in RFC > > 2822). I want my python batch scripts/cron jobs to enforce this > > behavior, and format the mail that is sent out so that newline > > charac

Re: Line Wrapping

2007-06-18 Thread TeroV
Evan Klitzke wrote: > All, > > Mail messages should be wrapped at 78 characters (as suggested in RFC > 2822). I want my python batch scripts/cron jobs to enforce this > behavior, and format the mail that is sent out so that newline > characters are inserted as appropriate to keep line lengths at 7

Line Wrapping

2007-06-18 Thread Evan Klitzke
All, Mail messages should be wrapped at 78 characters (as suggested in RFC 2822). I want my python batch scripts/cron jobs to enforce this behavior, and format the mail that is sent out so that newline characters are inserted as appropriate to keep line lengths at 78 characters or less. I wrote a

Docstring line wrapping in C modules?

2006-04-06 Thread Kelvie Wong
While writing docstrings in C, they don't get wrapped properly (i.e., lines will break in the middle of a word) when invoking the `help' function. Is there any way to have Python break lines automatically, or do I have to write my own C function/vim script to do it? Kelvie -- http://mail.python.

Re: line wrapping problem

2006-02-09 Thread Kent Johnson
S Borg wrote: > Hello, > > I am parsing text from one document to another. I have a scheme > similar to: > > for x in myfoobar: >print >> mytextfile, "%s" % mydictionary[x], #all on same line > print >> mytextfile, '\n' #new line > > > I am getting line breaks before my explic

Re: line wrapping problem

2006-02-09 Thread Juho Schultz
ZeD wrote: > Ciao, Juho Schultz! Che stavi dicendo? > Moro, ZeD! Kunhan pulisen. Should we stick to English? > >>should work. IMO file.write() is self-explanatory but "print >> file" is >>a bit obscure. > > is obscure only if you have never used a shell :) > (I have used the shell a bit. I star

Re: line wrapping problem

2006-02-09 Thread Peter Otten
S Borg wrote: > I am parsing text from one document to another. I have a scheme > similar to: > > for x in myfoobar: >print >> mytextfile, "%s" % mydictionary[x], #all on same line print >> mytextfile # minimal fix > I am getting line breaks before my explicit line break. Am

Re: line wrapping problem

2006-02-09 Thread ZeD
Ciao, Juho Schultz! Che stavi dicendo? > should work. IMO file.write() is self-explanatory but "print >> file" is > a bit obscure. is obscure only if you have never used a shell :) -- Evangelion e' la storia yaoi di un angelo che vuole portarsi a letto un ragazzo che si intreccia con la storia

Re: line wrapping problem

2006-02-09 Thread John Zenger
S Borg wrote: > print >> mytextfile, '\n' #new line Wouldn't this print two line breaks--the one you specify in the string, plus the one always added by print if there is no comma at the end of the statement? -- http://mail.python.org/mailman/listinfo/python-list

Re: line wrapping problem

2006-02-09 Thread Juho Schultz
S Borg wrote: > Hello, > > I am parsing text from one document to another. I have a scheme > similar to: > > for x in myfoobar: >print >> mytextfile, "%s" % mydictionary[x], #all on same line > print >> mytextfile, '\n' #new line > > > I am getting line breaks before my explic

Re: line wrapping problem

2006-02-09 Thread Fuzzyman
S Borg wrote: > Hello, > > I am parsing text from one document to another. I have a scheme > similar to: > > for x in myfoobar: >print >> mytextfile, "%s" % mydictionary[x], #all on same line > print >> mytextfile, '\n' #new line > You are using the print command to output the t

line wrapping problem

2006-02-09 Thread S Borg
Hello, I am parsing text from one document to another. I have a scheme similar to: for x in myfoobar: print >> mytextfile, "%s" % mydictionary[x], #all on same line print >> mytextfile, '\n' #new line I am getting line breaks before my explicit line break. Am I unwittingly copy