ncurses' Dark Devilry
Tony Nelson
*firstname*nlsnews at georgea*lastname*.com
Tue Nov 29 15:50:12 EST 2005
In article <mailman.1336.1133289146.18701.python-list at python.org>,
Jeremy Moles <jeremy at emperorlinux.com> wrote:
> I'm working on a project using ncurses w/ Python. As an aside, I
> implemented addchstr in the cursesmodule.c file in Python SVN, if anyone
> wants me to try and get that made permanent.
>
> AT ANY RATE...
>
> I was wondering--and this is more a general curses question rather than
> a Python one, but I know there are some old-timers here who have made
> curses obey before--is there a way to "repaint" a portion of screen
> without stealing the "cursor?" That is:
>
> I have a focus "wheel" of sorts that allows the user to do input on
> various wigets and windows and whatnot. However, if I want to quickly
> call addstr somewhere else in the application I have to:
>
> 1. Store the YX coords of the cursor currently
> 2. Use the cursor in the "current" action
> 3. Restore the old cursor location
>
> I know there are ways around this as I have seen curses apps that, for
> example, have a clock that updates every second without stealing
> "focus."
>
> I tried implementing/using addchstr (mentioned above) to no success.
>
> Any ideas? Is this just the plain wrong place to ask this? :)
I've only tried to read the Python Library Curses docs, but I thought
that the Window object method addstr() would do what you want.
________________________________________________________________________
TonyN.:' *firstname*nlsnews at georgea*lastname*.com
' <http://www.georgeanelson.com/>
More information about the Python-list
mailing list