However, this simple program - which should
1) Clear the terminal & print a
2) Wait for a char, but do no echoing
3) Print b
4) wait for a char and exit
(asdf:operate 'asdf:load-op 'cl-ncurses)
(in-package :cl-ncurses) ; needed in SBCL, not for CMUCL
(defun start ()
(initscr)
(erase)
(cbreak)
(noecho)
(refresh)
(addch (char-code #\a))
(refresh)
(getch)
(addch (char-code #\b))
(refresh)
(getch)
(print "after rl")
(nocbreak)
(echo)
(endwin))
(start)
Doesn't behave as expected. The getch accepts multiple chars until
return is pressed. Am I doing something very wrong? Is the Lisp shell
mucking me up?
Thanks
Brad
#include <curses.h>
#include <signal.h>
int main(int argc, char *argv[])
{
/* initialize your non-curses data structures here */
(void) initscr(); /* initialize the curses library */
//keypad(stdscr, TRUE); /* enable keyboard mapping */
//(void) nonl(); /* tell curses not to do NL->CR/NL on
output */
(void) cbreak(); /* take input chars one at a time, no wait
for \n */
(void) noecho(); /* echo input - in color */
addch('a');
getch(); /* refresh, accept single keystroke of input */
addch('b');
getch(); /* refresh, accept single keystroke of input */
endwin ();
}
Works for me. You're not using SLIME or linedit or anything with it,
are you?
--
Julian Squires
Thanks
Brad
Hi all, I am trying to use the getyx macro, and get the error
; Warning: This function is undefined:
; WRAP-GETYX
; Error in KERNEL:%COERCE-TO-FUNCTION: the function WRAP-GETYX is
undefined.
My program does basically ...
(asdf:operate 'asdf:load-op 'cl-ncurses)
(in-package :cl-ncurses)
(let (x y)
(getyx stdscr y x)
(mvaddstr 20 0 (format nil "~a ~a" x y)))
I am new to Lisp in general, so I don't really know how to go about
fixing this...
Any help is much appreciated.
Thanks
Brad
The problem appears to be in the asdf packaging
1) The glue.so file isn't being "linked"
2) The glue.lisp file isn't being loaded
I don't know how to fix this myself, but hopefully someone can look
into this & not waste too much time getting to the root of the problem.
Not that an experienced Lisper would take so long to find the issue :)
Brad