Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #87436

Re: Module/lib for controlling a terminal program using redrawing?

From Paul Rubin <no.email@nospam.invalid>
Newsgroups comp.lang.python
Subject Re: Module/lib for controlling a terminal program using redrawing?
Date 2015-03-14 11:00 -0700
Organization A noiseless patient Spider
Message-ID <87h9tncvcq.fsf@jester.gateway.sonic.net> (permalink)
References <CA+Zd3FeBRz2ErLZLX1rsFioUrtLmrpC5TnLqCp=QpmBiiGOhcQ@mail.gmail.com> <mailman.354.1426338694.21433.python-list@python.org>

Show all headers | View raw


Dave Angel <davea@davea.name> writes:
>> Is there a module/library that can help me with this?
> https://docs.python.org/3/howto/curses.html

That's the opposite of what the OP wanted.  Curses generates the escape
codes and so on to draw your desired stuff on the terminal.  The OP
wants a screen scraper, something that takes the escape codes generated
by another program and interprets them to figure out what the screen is
supposed to look like.

The classic program that does this is Rog-o-matic.  I don't happen to
know of any Python code that does it but the search terms "python ansi
screen scraping" find some results that might be worth looking into.  It
also shouldn't be all that terribly hard to implement.

Leaving out the "ansi" keyword finds mostly HTML scrapers which aren't
what is wanted.  Trying other terminal types like "vt100" might find
desirable stuff though.

Back to comp.lang.python | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

Re: Module/lib for controlling a terminal program using redrawing? Dave Angel <davea@davea.name> - 2015-03-14 09:11 -0400
  Re: Module/lib for controlling a terminal program using redrawing? Paul Rubin <no.email@nospam.invalid> - 2015-03-14 11:00 -0700

csiph-web