bug-ncurses
[Top][All Lists]
Advanced

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

RE: about not using stdscr


From: chinlu chinawa
Subject: RE: about not using stdscr
Date: Tue, 24 Oct 2006 15:10:08 +0100 (BST)

>short: keypad() and other flags are not inherited in
>new windows from the
>standard screen (or other parent windows).

Hello,

Thanks to both, that was actually the why. I started
my application using stdscr, then had to split it away
in two independent windows because refreshing stdscr
caused the small one at the bottom to dissappear, but
keypad reamined activating stdscr.

Actually I think must be really tired the last time I
wrote, cose how to catch shift+letter for example
might be as simple as "case 'A':" if using a switch
satement.

Though still haven't had time to look at it
thoroughly, I don't see curses.h defining CTRL or ALT
keys, or not with that names, and while I could
probably do a showkey and see what value it does
return, I'm still curious about how is this usually
done? perhaps for some reason those keys are taken
from each terminfo's description which isn't the case
as for example arrow keys and others?

Another question I had is about program structure
while using curses, what I'm doing is initializang
curses, creating the interface's windows, and then
falling into an infinite loop which derives on other
functions depending on the key pressed.

Eventually, I need subwindows to get some user's
feedback, so in that case the main loop calls in a
function that again creates the window, does a `key =
wgetch(win);' and has it's own loop. By using
`beep();' I cannot see inheritance or propagation from
within the private loop in regards of the main one. 

However I've recently upgraded my system from an old
gcc-2.95.3/libc2.3 to a "shiny" gcc-4.1.1/libc4.4, and
sometimes my app stops with something that looks like
a memory backtrace, I understand my old system would
just have said: "segmentation fault", though I cannot
see why, I doing it all the same way as for the main
interface and it never does that, any ideas or 
advises? 

Kind Regards,



Send instant messages to your online friends http://uk.messenger.yahoo.com 




reply via email to

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