disable line wrap in xterm??

Michael Hudson mwh at python.net
Tue Jun 19 13:12:34 EDT 2001

"Scherer, Bill" <Bill.Scherer at VerizonWireless.com> writes:

> Can anyone tell me how I can disable line wrap in an xterm (or
> equiv, eg: rxvt, Eterm, etc) from Python?

To turn auto-wrap off:

print "\033[?7l"

to turn it on:

print "\033[?7h"

Do you have the ctlseqs.TXT document?  It's handy for this sort of

These are probably grossly xterm specific - AFAIK there's no
corresponding terminfo/termcap code (but my termcap & terminfo book
seems to have vanished into the depths of my room, so I'm not sure).


58. Fools ignore complexity. Pragmatists suffer it. Some can avoid
    it. Geniuses remove it.
  -- Alan Perlis, http://www.cs.yale.edu/homes/perlis-alan/quotes.html

More information about the Python-list mailing list