Init style output with python?

Tina I tinaweb at bestemselv.com
Sun May 6 02:24:25 EDT 2007


Maxim Veksler wrote:

> Is there are frame work or something in python that would allow me to
> do this (quickly) ?
> If not, ideas how I should I be getting this boring task of:
> 1. get screen width

You can look into the 'curses' module and do something like:

	screen = curses.initscreen()
	maxheight, maxwith = screen.getmaxyx()

In my experience curses can be a bit tricky to work with but the online 
tutorials have some nice examples that help you avoid some of the 
pitfalls (like messing up your terminal)

Tina



More information about the Python-list mailing list