그래. 키패드가 없으면 ncurses가 이스케이프 코드를 처리하지 않습니다. 키패드 사람이 페이지에서 :
The keypad option enables the keypad of the user's terminal. If en-
abled (bf is TRUE), the user can press a function key (such as an arrow
key) and wgetch returns a single value representing the function key,
as in KEY_LEFT. If disabled (bf is FALSE), curses does not treat func-
tion keys specially and the program has to interpret the escape se-
quences itself. If the keypad in the terminal can be turned on (made
to transmit) and off (made to work locally), turning on this option
causes the terminal keypad to be turned on when wgetch is called. The
default value for keypad is false.
은 종종 내가 ncurses를 프로그램에서 할 첫번째 일은 좋은 키보드 매핑을 사용하는 전화 키패드 (stdscr, TRUE)입니다.
희망이 있습니다.
그래서 여기에서 이해할 수없는 것은 두 건의 키 입력 후에 "수정"되는 이유입니다. –