curses library

G

Ghirai

Hello list,

I need to write a console application.

Are there any wrappers around curses/ncurses?
Or any other similar libraries?

Thanks.
 
N

Neil Cerutti

I need to write a console application.

Are there any wrappers around curses/ncurses?
Or any other similar libraries?

The answer depends on your chosen platform. Python hasn't got a
cross-platform console library as one of its included batteries.

First try the curses module. It does come with Python on systems
with a curses port.

For Windows, there's the Effbot's console module.
http://effbot.org/zone/console-index.htm

Or go to plan B: Use a Tkinter or other GUI interface's text
widget.
 
G

Ghirai

The answer depends on your chosen platform. Python hasn't got a
cross-platform console library as one of its included batteries.

First try the curses module. It does come with Python on systems
with a curses port.

For Windows, there's the Effbot's console module.
http://effbot.org/zone/console-index.htm

Or go to plan B: Use a Tkinter or other GUI interface's text
widget.

Forgot to say, i don't need it to work on windows :)
 
L

Lawrence D'Oliveiro

Ghirai said:
I need to write a console application.

Why not just use VT100 escape sequences directly? Terminal emulators don't
support anything else.
 
B

Ben Finney

Ghirai said:
Are there any wrappers around curses/ncurses?

Python has its own 'curses' module in the standard library of course.

<URL:http://docs.python.org/lib/module-curses>

That's if you want to work directly with the curses functionality,
which is rather low-level.
Or any other similar libraries?

The library that I always think of when I think "Python ncurses
wrapper" is:

Urwid is a console user interface library for Python.

<URL:http://excess.org/urwid/>

Available as a package (e.g. 'python-urwid') in most GNU/Linux
distributions, or you can install it from the download link.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,431
Messages
2,571,679
Members
48,796
Latest member
Greg L.

Latest Threads

Top