[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Restarting Curses

From: Thomas Dickey
Subject: Re: Restarting Curses
Date: Thu, 3 Sep 2009 16:29:54 -0400 (EDT)

On Thu, 3 Sep 2009, Tim Mooney wrote:

In regard to: Restarting Curses, Nicholas Cole said (at 3:30pm on Sep 3, 2009):
I have a strange problem.  I have code that can start up and close
down curses making sure the terminal is reset.  But if I call it a
second time, the terminal is not properly reset.  I'm using python,
but I suspect it would be the same in C.  What might I be doing wrong?

It's been years and years since I've done any curses programming so I'm
a little rusty, but I do remember this hard-learned lesson: you only want
to call initscr() ONCE per program.

for portable programs, yes.

ncurses happens to allow initscr more than once, but that's
something that other curses implementations do not support.

Even with ncurses, there's the possibility of (a) python interacting in some way, or (b) a bug in ncurses.

Thomas E. Dickey

reply via email to

[Prev in Thread] Current Thread [Next in Thread]