Keith Thompson <[EMAIL PROTECTED]> wrote: >[EMAIL PROTECTED] (Floyd L. Davidson) writes: >> [EMAIL PROTECTED] wrote: >>>If I may recommend an alternative, >>> >>>print "\033[H\033[J" >>> >>>the ansi sequence to clear the screen. >> >> Or so you would hope (however, that is *not* what you have listed!). >> >> Unfortunately, it is poor practice to hard code such sequences. >> Instead the proper sequence should be obtained from the >> appropriate database (TERMINFO or TERMCAP), and the easy way to >> do that is, >> >> tput clear > >(Or "clear".)
But /clear/ merely uses "tput clear". >On the other hand, I think it's been at least a decade since I've used >a terminal or emulator that's not VT100-compatible (i.e., accepts ANSI >control sequences). > >Of course, I'll run into one the day after I start writing code that >depends on that assumption. However, if you check out the various TERMINFO database entries for an assortment of "VT100-compatible" terminals, you *will* find variation! Plus, if a user has customized a terminal database, for who knows what reason... -- Floyd L. Davidson <http://www.apaflo.com/floyd_davidson> Ukpeagvik (Barrow, Alaska) [EMAIL PROTECTED] -- http://mail.python.org/mailman/listinfo/python-list