croatoan

API Reference

croatoan

Common Lisp bindings for the ncurses terminal library.

DE.ANVI.NCURSES

Low-level CFFI bindings to the Ncurses C API. Not meant to be used directly.
  • Cffi-Type CHTYPE
  • Cffi-Type WCHAR_T
  • Cffi-Type WINT_T
  • Cffi-Type ATTR_T
    The 32 bit integral type attr_t holds an OR-ed set of attributes.
  • Cffi-Struct CCHAR_T
    C struct containing a wide char, a color pair and attributes.
  • Cffi-Type PTR-CCHAR_T
  • Cffi-Struct CCHAR
    C struct containing a wide char, a color pair and attributes.
  • Cffi-Type MMASK_T
  • Cffi-Struct MEVENT
    C struct containing mouse coordinates and button state.
  • Cffi-Function %ADDCH
  • Function %ADDCH (ch)
  • Cffi-Function %WADDCH
  • Function %WADDCH (win ch)
  • Cffi-Function %MVADDCH
  • Function %MVADDCH (y x ch)
  • Cffi-Function %MVWADDCH
  • Function %MVWADDCH (win y x ch)
  • Cffi-Function %ECHOCHAR
  • Function %ECHOCHAR (ch)
  • Cffi-Function %WECHOCHAR
  • Function %WECHOCHAR (win ch)
  • Cffi-Function %ADD-WCH
  • Function %ADD-WCH (wch)
  • Cffi-Function %WADD-WCH
  • Function %WADD-WCH (win wch)
  • Cffi-Function %MVADD-WCH
  • Function %MVADD-WCH (y x wch)
  • Cffi-Function %MVWADD-WCH
  • Function %MVWADD-WCH (win y x wch)
  • Cffi-Function %ECHO-WCHAR
  • Function %ECHO-WCHAR (wch)
  • Cffi-Function %WECHO-WCHAR
  • Function %WECHO-WCHAR (win wch)
  • Cffi-Function %ADDSTR
  • Function %ADDSTR (str)
  • Cffi-Function %ADDNSTR
  • Function %ADDNSTR (str n)
  • Cffi-Function %WADDSTR
  • Function %WADDSTR (win str)
  • Cffi-Function %WADDNSTR
  • Function %WADDNSTR (win str n)
  • Cffi-Function %MVADDSTR
  • Function %MVADDSTR (y x str)
  • Cffi-Function %MVADDNSTR
  • Function %MVADDNSTR (y x str n)
  • Cffi-Function %MVWADDSTR
  • Function %MVWADDSTR (win y x str)
  • Cffi-Function %MVWADDNSTR
  • Function %MVWADDNSTR (win y x str n)
  • Cffi-Function %ATTROFF
  • Function %ATTROFF (attrs)
  • Cffi-Function %WATTROFF
  • Function %WATTROFF (win attrs)
  • Cffi-Function %ATTRON
  • Function %ATTRON (attrs)
  • Cffi-Function %WATTRON
  • Function %WATTRON (win attrs)
  • Cffi-Function %ATTRSET
  • Function %ATTRSET (attrs)
  • Cffi-Function %WATTRSET
  • Function %WATTRSET (win attrs)
  • Cffi-Function %COLOR-SET
  • Function %COLOR-SET (color-pair-number opts)
  • Cffi-Function %WCOLOR-SET
  • Function %WCOLOR-SET (win color-pair-number opts)
  • Cffi-Function %STANDEND
  • Function %STANDEND
  • Cffi-Function %WSTANDEND
  • Function %WSTANDEND (win)
  • Cffi-Function %STANDOUT
  • Function %STANDOUT
  • Cffi-Function %WSTANDOUT
  • Function %WSTANDOUT (win)
  • Cffi-Function %ATTR-GET
  • Function %ATTR-GET (attrs pair opts)
  • Cffi-Function %WATTR-GET
  • Function %WATTR-GET (win attrs pair opts)
  • Cffi-Function %ATTR-OFF
  • Function %ATTR-OFF (attrs opts)
  • Cffi-Function %WATTR-OFF
  • Function %WATTR-OFF (win attrs opts)
  • Cffi-Function %ATTR-ON
  • Function %ATTR-ON (attrs opts)
  • Cffi-Function %WATTR-ON
  • Function %WATTR-ON (win attrs opts)
  • Cffi-Function %ATTR-SET
  • Function %ATTR-SET (attrs pair opts)
  • Cffi-Function %WATTR-SET
  • Function %WATTR-SET (win attrs pair opts)
  • Cffi-Function %CHGAT
  • Function %CHGAT (n attr color opts)
  • Cffi-Function %WCHGAT
  • Function %WCHGAT (win n attr color opts)
  • Cffi-Function %MVCHGAT
  • Function %MVCHGAT (y x n attr color opts)
  • Cffi-Function %MVWCHGAT
  • Function %MVWCHGAT (win y x n attr color opts)
  • Cffi-Function %BEEP
  • Function %BEEP
  • Cffi-Function %FLASH
  • Function %FLASH
  • Cffi-Function %BKGDSET
  • Function %BKGDSET (ch)
  • Cffi-Function %WBKGDSET
  • Function %WBKGDSET (win ch)
  • Cffi-Function %BKGD
  • Function %BKGD (ch)
  • Cffi-Function %WBKGD
  • Function %WBKGD (win ch)
  • Cffi-Function %GETBKGD
  • Function %GETBKGD (win)
  • Cffi-Function %BKGRND
  • Function %BKGRND (wch)
  • Cffi-Function %WBKGRND
  • Function %WBKGRND (win wch)
  • Cffi-Function %BKGRNDSET
  • Function %BKGRNDSET (wch)
  • Cffi-Function %WBKGRNDSET
  • Function %WBKGRNDSET (win wch)
  • Cffi-Function %GETBKGRND
  • Function %GETBKGRND (wch)
  • Cffi-Function %WGETBKGRND
  • Function %WGETBKGRND (win wch)
  • Cffi-Function %BORDER
  • Function %BORDER (ls rs ts bs tl tr bl br)
  • Cffi-Function %WBORDER
  • Function %WBORDER (win ls rs ts bs tl tr bl br)
  • Cffi-Function %BOX
  • Function %BOX (win verch horch)
  • Cffi-Function %HLINE
  • Function %HLINE (ch n)
  • Cffi-Function %WHLINE
  • Function %WHLINE (win ch n)
  • Cffi-Function %VLINE
  • Function %VLINE (ch n)
  • Cffi-Function %WVLINE
  • Function %WVLINE (win ch n)
  • Cffi-Function %MVHLINE
  • Function %MVHLINE (y x ch n)
  • Cffi-Function %MVWHLINE
  • Function %MVWHLINE (win y x ch n)
  • Cffi-Function %MVVLINE
  • Function %MVVLINE (y x ch n)
  • Cffi-Function %MVWVLINE
  • Function %MVWVLINE (win y x ch n)
  • Cffi-Function %BORDER-SET
  • Function %BORDER-SET (ls rs ts bs tl tr bl br)
  • Cffi-Function %WBORDER-SET
  • Function %WBORDER-SET (win ls rs ts bs tl tr bl br)
  • Cffi-Function %BOX-SET
  • Function %BOX-SET (win verch horch)
  • Cffi-Function %HLINE-SET
  • Function %HLINE-SET (wch n)
  • Cffi-Function %WHLINE-SET
  • Function %WHLINE-SET (win wch n)
  • Cffi-Function %MVHLINE-SET
  • Function %MVHLINE-SET (y x wch n)
  • Cffi-Function %MVWHLINE-SET
  • Function %MVWHLINE-SET (win y x wch n)
  • Cffi-Function %VLINE-SET
  • Function %VLINE-SET (wch n)
  • Cffi-Function %WVLINE-SET
  • Function %WVLINE-SET (win wch n)
  • Cffi-Function %MVVLINE-SET
  • Function %MVVLINE-SET (y x wch n)
  • Cffi-Function %MVWVLINE-SET
  • Function %MVWVLINE-SET (win y x wch n)
  • Cffi-Function %ERASE
  • Function %ERASE
  • Cffi-Function %WERASE
  • Function %WERASE (win)
  • Cffi-Function %CLEAR
  • Function %CLEAR
  • Cffi-Function %WCLEAR
  • Function %WCLEAR (win)
  • Cffi-Function %CLRTOBOT
  • Function %CLRTOBOT
  • Cffi-Function %WCLRTOBOT
  • Function %WCLRTOBOT (win)
  • Cffi-Function %CLRTOEOL
  • Function %CLRTOEOL
  • Cffi-Function %WCLRTOEOL
  • Function %WCLRTOEOL (win)
  • Cffi-Function %START-COLOR
  • Function %START-COLOR
  • Cffi-Function %HAS-COLORS
  • Function %HAS-COLORS
  • Cffi-Function %CAN-CHANGE-COLOR
  • Function %CAN-CHANGE-COLOR
  • Cffi-Function %INIT-PAIR
  • Function %INIT-PAIR (pair f b)
  • Cffi-Function %INIT-COLOR
  • Function %INIT-COLOR (color r g b)
  • Cffi-Function %PAIR-CONTENT
  • Function %PAIR-CONTENT (pair f b)
  • Cffi-Function %COLOR-CONTENT
  • Function %COLOR-CONTENT (color r g b)
  • Cffi-Function %INIT-EXTENDED-PAIR
  • Function %INIT-EXTENDED-PAIR (pair f b)
  • Cffi-Function %INIT-EXTENDED-COLOR
  • Function %INIT-EXTENDED-COLOR (color r g b)
  • Cffi-Function %PAIR-EXTENDED-CONTENT
  • Function %PAIR-EXTENDED-CONTENT (pair f b)
  • Cffi-Function %COLOR-EXTENDED-CONTENT
  • Function %COLOR-EXTENDED-CONTENT (color r g b)
  • Cffi-Function %COLOR-PAIR
  • Function %COLOR-PAIR (n)
  • Cffi-Function %PAIR-NUMBER
  • Function %PAIR-NUMBER (attrs)
  • Variable %COLOR_BLACK
    0
  • Variable %COLOR_RED
    1
  • Variable %COLOR_GREEN
    2
  • Variable %COLOR_YELLOW
    3
  • Variable %COLOR_BLUE
    4
  • Variable %COLOR_MAGENTA
    5
  • Variable %COLOR_CYAN
    6
  • Variable %COLOR_WHITE
    7
  • Cffi-Function %USE-DEFAULT-COLORS
  • Function %USE-DEFAULT-COLORS
  • Cffi-Function %ASSUME-DEFAULT-COLORS
  • Function %ASSUME-DEFAULT-COLORS (fg bg)
  • Cffi-Function %DEFINE-KEY
  • Function %DEFINE-KEY (definition keycode)
  • Cffi-Function %DELCH
  • Function %DELCH
  • Cffi-Function %WDELCH
  • Function %WDELCH (win)
  • Cffi-Function %MVDELCH
  • Function %MVDELCH (y x)
  • Cffi-Function %MVWDELCH
  • Function %MVWDELCH (win y x)
  • Cffi-Function %DELETELN
  • Function %DELETELN
  • Cffi-Function %WDELETELN
  • Function %WDELETELN (win)
  • Cffi-Function %INSDELLN
  • Function %INSDELLN (n)
  • Cffi-Function %WINSDELLN
  • Function %WINSDELLN (win n)
  • Cffi-Function %INSERTLN
  • Function %INSERTLN
  • Cffi-Function %WINSERTLN
  • Function %WINSERTLN (win)
  • Cffi-Function %CURSES-VERSION
  • Function %CURSES-VERSION
  • Cffi-Function %USE-EXTENDED-NAMES
  • Function %USE-EXTENDED-NAMES (enable)
  • Cffi-Function %GETCH
  • Function %GETCH
  • Cffi-Function %WGETCH
  • Function %WGETCH (win)
  • Cffi-Function %MVGETCH
  • Function %MVGETCH (y x)
  • Cffi-Function %MVWGETCH
  • Function %MVWGETCH (win y x)
  • Cffi-Function %UNGETCH
  • Function %UNGETCH (ch)
  • Cffi-Function %HAS-KEY
  • Function %HAS-KEY (ch)
  • Cffi-Function %GET-WCH
  • Function %GET-WCH (wch)
  • Cffi-Function %WGET-WCH
  • Function %WGET-WCH (win wch)
  • Cffi-Function %MVGET-WCH
  • Function %MVGET-WCH (y x wch)
  • Cffi-Function %MVWGET-WCH
  • Function %MVWGET-WCH (win y x wch)
  • Cffi-Function %UNGET-WCH
  • Function %UNGET-WCH (wch)
  • Cffi-Function %GETCCHAR
  • Function %GETCCHAR (wcval wch attrs color_pair opts)
  • Cffi-Function %SETCCHAR
  • Function %SETCCHAR (wcval wch attrs color_pair opts)
  • Cffi-Function %GETSTR
  • Function %GETSTR (str)
  • Cffi-Function %GETNSTR
  • Function %GETNSTR (str n)
  • Cffi-Function %WGETSTR
  • Function %WGETSTR (win str)
  • Cffi-Function %WGETNSTR
  • Function %WGETNSTR (win str n)
  • Cffi-Function %MVGETSTR
  • Function %MVGETSTR (y x str)
  • Cffi-Function %MVGETNSTR
  • Function %MVGETNSTR (y x str n)
  • Cffi-Function %MVWGETSTR
  • Function %MVWGETSTR (win y x str)
  • Cffi-Function %MVWGETNSTR
  • Function %MVWGETNSTR (win y x str n)
  • Cffi-Function %INCH
  • Function %INCH
  • Cffi-Function %WINCH
  • Function %WINCH (win)
  • Cffi-Function %MVINCH
  • Function %MVINCH (y x)
  • Cffi-Function %MVWINCH
  • Function %MVWINCH (win y x)
  • Cffi-Function %IN-WCH
  • Function %IN-WCH (wcval)
  • Cffi-Function %MVIN-WCH
  • Function %MVIN-WCH (y x wcval)
  • Cffi-Function %WIN-WCH
  • Function %WIN-WCH (win wcval)
  • Cffi-Function %MVWIN-WCH
  • Function %MVWIN-WCH (win y x wcval)
  • Cffi-Function %INSCH
  • Function %INSCH (ch)
  • Cffi-Function %WINSCH
  • Function %WINSCH (win ch)
  • Cffi-Function %MVINSCH
  • Function %MVINSCH (y x ch)
  • Cffi-Function %MVWINSCH
  • Function %MVWINSCH (win y x ch)
  • Cffi-Function %INS-WCH
  • Function %INS-WCH (wch)
  • Cffi-Function %WINS-WCH
  • Function %WINS-WCH (win wch)
  • Cffi-Function %MVINS-WCH
  • Function %MVINS-WCH (y x wch)
  • Cffi-Function %MVWINS-WCH
  • Function %MVWINS-WCH (win y x wch)
  • Cffi-Function %INSTR
  • Function %INSTR (str)
  • Cffi-Function %INNSTR
  • Function %INNSTR (str n)
  • Cffi-Function %WINSTR
  • Function %WINSTR (win str)
  • Cffi-Function %WINNSTR
  • Function %WINNSTR (win str n)
  • Cffi-Function %MVINSTR
  • Function %MVINSTR (y x str)
  • Cffi-Function %MVINNSTR
  • Function %MVINNSTR (y x str n)
  • Cffi-Function %MVWINSTR
  • Function %MVWINSTR (win y x str)
  • Cffi-Function %MVWINNSTR
  • Function %MVWINNSTR (win y x str n)
  • Cffi-Function %INWSTR
  • Function %INWSTR (str)
  • Cffi-Function %INNWSTR
  • Function %INNWSTR (str n)
  • Cffi-Function %WINWSTR
  • Function %WINWSTR (win str)
  • Cffi-Function %WINNWSTR
  • Function %WINNWSTR (win str n)
  • Cffi-Function %MVINWSTR
  • Function %MVINWSTR (y x str)
  • Cffi-Function %MVINNWSTR
  • Function %MVINNWSTR (y x str n)
  • Cffi-Function %MVWINWSTR
  • Function %MVWINWSTR (win y x str)
  • Cffi-Function %MVWINNWSTR
  • Function %MVWINNWSTR (win y x str n)
  • Cffi-Function %INCHSTR
  • Function %INCHSTR (chstr)
  • Cffi-Function %INCHNSTR
  • Function %INCHNSTR (chstr n)
  • Cffi-Function %WINCHSTR
  • Function %WINCHSTR (win chstr)
  • Cffi-Function %WINCHNSTR
  • Function %WINCHNSTR (win chstr n)
  • Cffi-Function %MVINCHSTR
  • Function %MVINCHSTR (y x chstr)
  • Cffi-Function %MVINCHNSTR
  • Function %MVINCHNSTR (y x chstr n)
  • Cffi-Function %MVWINCHSTR
  • Function %MVWINCHSTR (win y x chstr)
  • Cffi-Function %MVWINCHNSTR
  • Function %MVWINCHNSTR (win y x chstr n)
  • Cffi-Function %INSSTR
  • Function %INSSTR (str)
  • Cffi-Function %INSNSTR
  • Function %INSNSTR (str n)
  • Cffi-Function %WINSSTR
  • Function %WINSSTR (win str)
  • Cffi-Function %WINSNSTR
  • Function %WINSNSTR (win str n)
  • Cffi-Function %MVINSSTR
  • Function %MVINSSTR (y x str)
  • Cffi-Function %MVINSNSTR
  • Function %MVINSNSTR (y x str n)
  • Cffi-Function %MVWINSSTR
  • Function %MVWINSSTR (win y x str)
  • Cffi-Function %MVWINSNSTR
  • Function %MVWINSNSTR (win y x str n)
  • Cffi-Function %INITSCR
  • Function %INITSCR
  • Cffi-Function %ENDWIN
  • Function %ENDWIN
  • Cffi-Function %ISENDWIN
  • Function %ISENDWIN
  • Cffi-Function %NEWTERM
  • Function %NEWTERM (type outfd infd)
  • Cffi-Function %SET-TERM
  • Function %SET-TERM (new)
  • Cffi-Function %DELSCREEN
  • Function %DELSCREEN (sp)
  • Cffi-Function %CBREAK
  • Function %CBREAK
  • Cffi-Function %NOCBREAK
  • Function %NOCBREAK
  • Cffi-Function %ECHO
  • Function %ECHO
  • Cffi-Function %NOECHO
  • Function %NOECHO
  • Cffi-Function %HALFDELAY
  • Function %HALFDELAY (tenths)
  • Cffi-Function %INTRFLUSH
  • Function %INTRFLUSH (win bf)
  • Cffi-Function %KEYPAD
  • Function %KEYPAD (win bf)
  • Cffi-Function %META
  • Function %META (win bf)
  • Cffi-Function %NODELAY
  • Function %NODELAY (win bf)
  • Cffi-Function %RAW
  • Function %RAW
  • Cffi-Function %NORAW
  • Function %NORAW
  • Cffi-Function %NOQIFLUSH
  • Function %NOQIFLUSH
  • Cffi-Function %QIFLUSH
  • Function %QIFLUSH
  • Cffi-Function %NOTIMEOUT
  • Function %NOTIMEOUT (win bf)
  • Cffi-Function %TIMEOUT
  • Function %TIMEOUT (delay)
  • Cffi-Function %WTIMEOUT
  • Function %WTIMEOUT (win delay)
  • Cffi-Function %TYPEAHEAD
  • Function %TYPEAHEAD (fd)
  • Cffi-Function %DEF-PROG-MODE
  • Function %DEF-PROG-MODE
  • Cffi-Function %DEF-SHELL-MODE
  • Function %DEF-SHELL-MODE
  • Cffi-Function %RESET-PROG-MODE
  • Function %RESET-PROG-MODE
  • Cffi-Function %RESET-SHELL-MODE
  • Function %RESET-SHELL-MODE
  • Cffi-Function %RESETTY
  • Function %RESETTY
  • Cffi-Function %SAVETTY
  • Function %SAVETTY
  • Cffi-Function %GETSYX
  • Function %GETSYX (y x)
  • Cffi-Function %SETSYX
  • Function %SETSYX (y x)
  • Cffi-Function %RIPOFFLINE
  • Function %RIPOFFLINE (line init)
  • Cffi-Function %CURS-SET
  • Function %CURS-SET (visibility)
  • Cffi-Function %NAPMS
  • Function %NAPMS (ms)
  • Cffi-Function %KEYBOUND
  • Function %KEYBOUND (keycode count)
  • Cffi-Function %KEY-DEFINED
  • Function %KEY-DEFINED (definition)
  • Cffi-Function %GETBEGX
  • Function %GETBEGX (win)
  • Cffi-Function %GETBEGY
  • Function %GETBEGY (win)
  • Cffi-Function %GETCURX
  • Function %GETCURX (win)
  • Cffi-Function %GETCURY
  • Function %GETCURY (win)
  • Cffi-Function %GETMAXX
  • Function %GETMAXX (win)
  • Cffi-Function %GETMAXY
  • Function %GETMAXY (win)
  • Cffi-Function %GETPARX
  • Function %GETPARX (win)
  • Cffi-Function %GETPARY
  • Function %GETPARY (win)
  • Cffi-Function %USE-LEGACY-CODING
  • Function %USE-LEGACY-CODING (level)
  • Cffi-Function %GETMOUSE
  • Function %GETMOUSE (event)
  • Cffi-Function %MOUSEMASK
  • Function %MOUSEMASK (newmask oldmask)
  • Cffi-Function %MOVE
  • Function %MOVE (y x)
  • Cffi-Function %WMOVE
  • Function %WMOVE (win y x)
  • Cffi-Function %IS-CLEARED
  • Function %IS-CLEARED (win)
  • Cffi-Function %IS-IDCOK
  • Function %IS-IDCOK (win)
  • Cffi-Function %IS-IDLOK
  • Function %IS-IDLOK (win)
  • Cffi-Function %IS-IMMEDOK
  • Function %IS-IMMEDOK (win)
  • Cffi-Function %IS-KEYPAD
  • Function %IS-KEYPAD (win)
  • Cffi-Function %IS-LEAVEOK
  • Function %IS-LEAVEOK (win)
  • Cffi-Function %IS-NODELAY
  • Function %IS-NODELAY (win)
  • Cffi-Function %IS-NOTIMEOUT
  • Function %IS-NOTIMEOUT (win)
  • Cffi-Function %IS-PAD
  • Function %IS-PAD (win)
  • Cffi-Function %IS-SCROLLOK
  • Function %IS-SCROLLOK (win)
  • Cffi-Function %IS-SUBWIN
  • Function %IS-SUBWIN (win)
  • Cffi-Function %IS-SYNCOK
  • Function %IS-SYNCOK (win)
  • Cffi-Function %WGETPARENT
  • Function %WGETPARENT (win)
  • Cffi-Function %WGETSCRREG
  • Function %WGETSCRREG (win top bottom)
  • Cffi-Function %CLEAROK
  • Function %CLEAROK (win bf)
  • Cffi-Function %IDLOK
  • Function %IDLOK (win bf)
  • Cffi-Function %IDCOK
  • Function %IDCOK (win bf)
  • Cffi-Function %IMMEDOK
  • Function %IMMEDOK (win bf)
  • Cffi-Function %LEAVEOK
  • Function %LEAVEOK (win bf)
  • Cffi-Function %SCROLLOK
  • Function %SCROLLOK (win bf)
  • Cffi-Function %SETSCRREG
  • Function %SETSCRREG (top bot)
  • Cffi-Function %WSETSCRREG
  • Function %WSETSCRREG (win top bot)
  • Cffi-Function %NL
  • Function %NL
  • Cffi-Function %NONL
  • Function %NONL
  • Cffi-Function %NEWPAD
  • Function %NEWPAD (nlines ncols)
  • Cffi-Function %SUBPAD
  • Function %SUBPAD (orig nlines ncols begin_y begin_x)
  • Cffi-Function %PREFRESH
  • Function %PREFRESH (pad pminrow pmincol sminrow smincol smaxrow smaxcol)
  • Cffi-Function %PNOUTREFRESH
  • Function %PNOUTREFRESH (pad pminrow pmincol sminrow smincol smaxrow smaxcol)
  • Cffi-Function %PECHOCHAR
  • Function %PECHOCHAR (pad ch)
  • Cffi-Function %PECHO-WCHAR
  • Function %PECHO-WCHAR (pad wch)
  • Cffi-Function %REFRESH
  • Function %REFRESH
  • Cffi-Function %WREFRESH
  • Function %WREFRESH (win)
  • Cffi-Function %WNOUTREFRESH
  • Function %WNOUTREFRESH (win)
  • Cffi-Function %DOUPDATE
  • Function %DOUPDATE
  • Cffi-Function %REDRAWWIN
  • Function %REDRAWWIN (win)
  • Cffi-Function %WREDRAWLN
  • Function %WREDRAWLN (win beg-line num-lines)
  • Cffi-Function %IS-TERM-RESIZED
  • Function %IS-TERM-RESIZED (lines columns)
  • Cffi-Function %RESIZE-TERM
  • Function %RESIZE-TERM (lines columns)
  • Cffi-Function %RESIZETERM
  • Function %RESIZETERM (lines columns)
  • Cffi-Function %SCROLL
  • Function %SCROLL (win)
  • Cffi-Function %SCRL
  • Function %SCRL (n)
  • Cffi-Function %WSCRL
  • Function %WSCRL (win n)
  • Cffi-Function %SLK-INIT
  • Function %SLK-INIT (fmt)
  • Cffi-Function %SLK-SET
  • Function %SLK-SET (labnum label fmt)
  • Cffi-Function %SLK-REFRESH
  • Function %SLK-REFRESH
  • Cffi-Function %SLK-NOUTREFRESH
  • Function %SLK-NOUTREFRESH
  • Cffi-Function %SLK-LABEL
  • Function %SLK-LABEL (labnum)
  • Cffi-Function %SLK-CLEAR
  • Function %SLK-CLEAR
  • Cffi-Function %SLK-RESTORE
  • Function %SLK-RESTORE
  • Cffi-Function %SLK-TOUCH
  • Function %SLK-TOUCH
  • Cffi-Function %SLK-ATTRON
  • Function %SLK-ATTRON (attrs)
  • Cffi-Function %SLK-ATTROFF
  • Function %SLK-ATTROFF (attrs)
  • Cffi-Function %SLK-ATTRSET
  • Function %SLK-ATTRSET (attrs)
  • Cffi-Function %SLK-ATTR-ON
  • Function %SLK-ATTR-ON (attrs opts)
  • Cffi-Function %SLK-ATTR-OFF
  • Function %SLK-ATTR-OFF (attrs opts)
  • Cffi-Function %SLK-ATTR-SET
  • Function %SLK-ATTR-SET (attrs color-pair opts)
  • Cffi-Function %SLK-ATTR
  • Function %SLK-ATTR
  • Cffi-Function %SLK-COLOR
  • Function %SLK-COLOR (color-pair)
  • Cffi-Function %BAUDRATE
  • Function %BAUDRATE
  • Cffi-Function %ERASECHAR
  • Function %ERASECHAR
  • Cffi-Function %HAS-IC
  • Function %HAS-IC
  • Cffi-Function %HAS-IL
  • Function %HAS-IL
  • Cffi-Function %KILLCHAR
  • Function %KILLCHAR
  • Cffi-Function %LONGNAME
  • Function %LONGNAME
  • Cffi-Function %TERM-ATTRS
  • Function %TERM-ATTRS
  • Cffi-Function %TERMATTRS
  • Function %TERMATTRS
  • Cffi-Function %TERMNAME
  • Function %TERMNAME
  • Cffi-Function %TOUCHWIN
  • Function %TOUCHWIN (win)
  • Cffi-Function %TOUCHLINE
  • Function %TOUCHLINE (win start count)
  • Cffi-Function %UNTOUCHWIN
  • Function %UNTOUCHWIN (win)
  • Cffi-Function %WTOUCHLN
  • Function %WTOUCHLN (win y n changed)
  • Cffi-Function %IS-LINETOUCHED
  • Function %IS-LINETOUCHED (win line)
  • Cffi-Function %IS-WINTOUCHED
  • Function %IS-WINTOUCHED (win)
  • Cffi-Function %UNCTRL
  • Function %UNCTRL (c)
  • Cffi-Function %KEYNAME
  • Function %KEYNAME (c)
  • Cffi-Function %FILTER
  • Function %FILTER
  • Cffi-Function %NOFILTER
  • Function %NOFILTER
  • Cffi-Function %USE-ENV
  • Function %USE-ENV (f)
  • Cffi-Function %PUTWIN
  • Function %PUTWIN (win filep)
  • Cffi-Function %GETWIN
  • Function %GETWIN (filep)
  • Cffi-Function %DELAY-OUTPUT
  • Function %DELAY-OUTPUT (ms)
  • Cffi-Function %FLUSHINP
  • Function %FLUSHINP
  • Cffi-Function %NEWWIN
  • Function %NEWWIN (nlines ncols begin_y begin_x)
  • Cffi-Function %DELWIN
  • Function %DELWIN (win)
  • Cffi-Function %MVWIN
  • Function %MVWIN (win y x)
  • Cffi-Function %SUBWIN
  • Function %SUBWIN (orig nlines ncols begin_y begin_x)
  • Cffi-Function %DERWIN
  • Function %DERWIN (orig nlines ncols begin_y begin_x)
  • Cffi-Function %MVDERWIN
  • Function %MVDERWIN (win par_y par_x)
  • Cffi-Function %DUPWIN
  • Function %DUPWIN (win)
  • Cffi-Function %WSYNCUP
  • Function %WSYNCUP (win)
  • Cffi-Function %SYNCOK
  • Function %SYNCOK (win bf)
  • Cffi-Function %WCURSYNCUP
  • Function %WCURSYNCUP (win)
  • Cffi-Function %WSYNCDOWN
  • Function %WSYNCDOWN (win)
  • Cffi-Function %WRESIZE
  • Function %WRESIZE (win lines columns)

DE.ANVI.CROATOAN

High-level Lisp interface to the basic CFFI Ncurses API.
  • Macro WITH-SCREEN ((screen &key (input-buffering nil) (process-control-chars t) (input-blocking t) (input-echoing t) (enable-fkeys t) (enable-colors t) (use-default-colors nil) (cursor-visibility t) (stacked nil) (color-pair nil) (background nil)) &body body)
    Create a screen, evaluate the forms in the body, then cleanly close the screen. Pass any arguments to the initialisation of the screen object. The screen is cleared immediately after initialisation. This macro is the main entry point for writing ncurses programs with the croatoan library. Do not run more than one screen at the same time.
  • Macro WITH-WINDOW ((win &rest options) &body body)
    Create a window, evaluate the forms in the body, then cleanly close the window. Pass any arguments to the initialisation of the window object. Example: (with-window (win :input-echoing t body)
  • Macro WITH-WINDOWS (bindings &body body)
    Create one or more windows, evaluate the forms in the body, then cleanly close the windows. Pass any arguments to the initialisation of the window objects. Example: (with-windows ((win1 :input-echoing t) (win2 :input-echoing t)) body)
  • Macro EVENT-CASE ((window event &optional mouse-y mouse-x) &body body)
    Window event loop, events are handled by an implicit case form. For now, it is limited to events generated in a single window. So events from multiple windows have to be handled separately. In order for event-handling to work, input-buffering has to be nil. Several control character events can only be handled when process-control-chars is also nil. If input-blocking is nil, we can handle the (nil) event, i.e. what happens between key presses. If input-blocking is t, the (nil) event is never returned. The main window event loop name is hard coded to event-case to be used with return-from. Instead of ((nil) nil), which eats 100% CPU, use input-blocking t.
  • Macro ADD-EVENT-HANDLER ((window event) &body handler-function)
    Add the event and its handler-function to the window's event handler alist. The handlers will be called by the run-event-loop when keyboard or mouse events occur. The handler functions have two mandatory arguments, window and event. For every event-loop, at least an event to exit the event loop should be assigned, by associating it with the predefined function exit-event-loop. If a handler for the event :default is defined, it will handle all events for which no specific event handler has been defined. If input-blocking of the window is set to nil, a handler for the nil event can be defined, which will be called at a specified frame-rate between keypresses. Here the main application state can be updated. Alternatively, to achieve the same effect, input-blocking can be set to a specific delay in miliseconds.
  • Macro REMOVE-EVENT-HANDLER (window event)
    Remove the event and the handler function from a windows event-handlers collection.
  • Function MAKE-KEYMAP (&rest args)
    Take a list of keys and values, return an event handler keymap. Currently the keymap is implemented as an alist, but will be converted to a hash table in the future.
  • Function GET-KEYMAP (keymap-name)
    Take a keyword denoting a keymap name, return a keymap object from the global keymap collection.
  • Function ADD-KEYMAP (keymap-name keymap)
    Add a keymap by its name to the global keymap collection.
  • Function RUN-EVENT-LOOP (win &optional args)
    Read events from the window, then call predefined event handler functions on the events. The handlers can be added by the macro add-event-handler, or by directly setting a predefined keymap to the window's event-handlers property. Args is either a single additional argument passed to the handlers, or a list of arguments.
  • Function EXIT-EVENT-LOOP (win event &optional args)
    Associate this function with an event to exit the event loop.
  • Macro SAVE-EXCURSION (window &body body)
    After executing body, return the cursor in window to its initial position.
  • Class COMPLEX-CHAR
    A complex char consists of a simple char, a list of attribute keywords and a pair of color keywords.
    SIMPLE-CHAR   Accessor: .SIMPLE-CHAR
    Lisp primitive character type, like #a.
    ATTRIBUTES   Accessor: .ATTRIBUTES
    List of keywords denoting attributes.
    COLOR-PAIR   Accessor: .COLOR-PAIR
    Two element list of keywords denoting a foreground and background color of the char.
  • Class COMPLEX-STRING
    A complex string consists of an array of complex characters.
    COMPLEX-CHAR-ARRAY   Accessor: .COMPLEX-CHAR-ARRAY
    Lisp primitive string type.
  • Class WINDOW  (FUNDAMENTAL-CHARACTER-INPUT-STREAM, FUNDAMENTAL-CHARACTER-OUTPUT-STREAM)
    A curses window object as returned by newwin.
    POSITION
    The (y=row x=column) coordinate of the top left corner of the window.
    WIDTH
    The width (second, horizontal, x dimension) of the window.
    HEIGHT
    The height (first, vertical, y dimension) of the window.
    CURSOR-POSITION
    The current cursor position coordinates in the form (y x).
    INPUT-BLOCKING
    Input mode: blocking (t), non-blocking (nil) or blocking duration in (positive integer) miliseconds.
    FRAME-RATE   Accessor: .FRAME-RATE
    Set the frame rate in fps (frames per second). When input-blocking is nil, sleep for 1/frame-rate seconds between event loop cycles. Has the same effect as setting input-blocking duration, and should thus not be used simultaneously.
    ENABLE-FKEYS
    Enable (t) or disable (nil) support for function keys.
    ENABLE-SCROLLING
    Enable (t) or disable (nil) support for window scrolling.
    SCROLLING-REGION
    When scrolling is enabled, only scroll the window region from line y1 to y2 given as the list (y1 y2).
    INSERT-ENABLED   Accessor: .INSERT-ENABLED
    Printing a new char will insert (t) it before the character under the cursor instead of overwriting (nil) it.
    EVENT-HANDLERS   Accessor: .EVENT-HANDLERS
    A collection (alist or hash table) containing events (characters, keywords or integers) as keys and handler functions as values. Used by the run-event-loop function.
    BACKGROUND
    Sets a complex char as the background of the window. It does not change the colors or attributes of existing complex chars. A newline sets the background till the end of the line.
    ATTRIBUTES
    A list of keywords denoting attributes of new characters added to a window.
    COLOR-PAIR
    A two element list of keywords denoting the foreground and background color of new characters added to a window.
    BORDER   Reader: .BORDER
    Enable (t) or disable (nil, default) an initial border around a window.
    STACKED
    If stacked is t, the window is added to the global window stack, so overlapping windows can be refreshed in the stacking order.
    VISIBLE   Accessor: .VISIBLE
    If visible is nil, do not refresh the window when refreshing the window stack.
    WINPTR   Reader: .WINPTR
    Pointer to a C/ncurses WINDOW structure after the window is created.
  • Method .STACKED ((win window))
  • Method (setf .STACKED) (stacked (win window))
  • Class SCREEN  (WINDOW)
    Represents the main window created upon screen initialisation.
    ENABLE-COLORS
    Enable (t) or disable (nil) display of colors, if the terminal supports it.
    USE-DEFAULT-COLORS
    Use (t) the default colors of the terminal, instead of the ncurses default white on black.
    CURSOR-VISIBILITY
    Enable (t) or disable (nil) displaying a visible cursor.
    INPUT-ECHOING
    Enable (t) or disable (nil) echoing of chars during keyboard input.
    INPUT-BUFFERING
    Set whether typed characters will be returned immediately when they are typed (nil, default) or buffered until Return is typed (t).
    PROCESS-CONTROL-CHARS
    If input-buffering is nil, set whether some control characters like ^C, ^S, ^Q, ^D will be processed (t, default) or passed directly to the program (nil). When input-buffering is t, control chars are always processed and this option has no effect.
    CLOSED-P
    Check whether the screen has been closed, without a subsequent call to refresh to reactivate it.
  • Class SUB-WINDOW  (WINDOW)
    A sub-window shares the memory and the display with and has to be contained within a parent window.
    PARENT
    The parent window which will contain the sub-window.
    RELATIVE
    The position of the sub-window is relative to the parent window (t) or to the screen (nil, default).
    SOURCE
    Position (y x) of the area of the parent window, which is mapped to the subwindow. By default it is identical to the position of the subwindow.
  • Class DECORATED-WINDOW  (WINDOW)
    A decorated-window is a window consisting of a background window for a border, a title and a content sub-window.
    SUB-WINDOW   Reader: .SUB-WINDOW
    Active content window, for example for menu items.
    TITLE   Accessor: .TITLE
    If t, a title of the window will be displayed over the top border.
  • Class MENU-ITEM
    A menu consists of a list of menu items.
    NAME   Reader: .NAME
    Short name of a menu item displayed in the menu.
    CHECKED   Accessor: .CHECKED
    t if the item has been checked, nil if it hasn't.
    VALUE   Reader: .VALUE
    If the item is not a string, it can be a sub menu or (not yet implemented) a function.
  • Class MENU
    A menu is a list of items that can be selected by the user.
    NAME   Reader: .NAME
    Name of the menu. (For example for setting the menu-window title, if title is t.)
    ITEMS   Accessor: .ITEMS
    List of menu items. Item types can be strings, symbols, other menus or (not yet implemented) functions.
    TYPE   Accessor: .TYPE
    Types of menus: :selection (default, can contain strings, symbols, menus) or :checklist.
    CURRENT-ITEM-NUMBER   Accessor: .CURRENT-ITEM-NUMBER
    Number of the currently selected item.
    CURRENT-ITEM   Accessor: .CURRENT-ITEM
    Pointer to the currently selected item object. The first item is initialized as the current item.
    CURRENT-ITEM-MARK   Reader: .CURRENT-ITEM-MARK
    A string prefixed to the current item in the menu.
    CYCLIC-SELECTION   Reader: .CYCLIC-SELECTION
    Wrap around when the end of a non-scrolled menu is reached.
    MAX-ITEM-LENGTH   Reader: .MAX-ITEM-LENGTH
    Max number of characters displayed for a single item.
    LAYOUT   Accessor: .LAYOUT
    Layout (no-of-rows no-of-columns) of the items in the menu. If nil, we have a vertical list.
    SCROLLED-LAYOUT   Accessor: .SCROLLED-LAYOUT
    Layout (no-of-rows no-of-columns) of the menu items actually displayed on screen.
    SCROLLED-REGION-START   Accessor: .SCROLLED-REGION-START
    A 2-element list tracking the starting row/y and column/x of the displayed menu region.
    WINDOW   Accessor: .WINDOW
    Window created separately and then associated with the menu.
  • Class MENU-WINDOW  (MENU, DECORATED-WINDOW)
    A menu-window is decorated-window providing a list of items to be selected by the user.
    No slots.
  • Class DIALOG-WINDOW  (MENU-WINDOW)
    A dialog is a decorated menu with a title, a message and items.
    MESSAGE-PAD   Reader: .MESSAGE-PAD
    Passive content window, for example for menu descriptions.
    MESSAGE-TEXT   Accessor: .MESSAGE-TEXT
    Optional message text to describe the choices in the menu below.
    MESSAGE-HEIGHT   Reader: .MESSAGE-HEIGHT
    Max number of lines reserved for the optional message text.
    MESSAGE-PAD-COORDINATES   Reader: .MESSAGE-PAD-COORDINATES
    List of four coordinates where to refresh/display the message pad: min-y min-x max-y max-x.
  • Class FIELD
    A field is an editable part of the screen for user input.
    POSITION   Accessor: .POSITION
    A two-element list (y=row x=column) containing the coordinate of the top left corner of the field.
    HEIGHT   Accessor: .HEIGHT
    The height (number of lines) of the field. The default is 1, a single-line field.
    WIDTH   Accessor: .WIDTH
    The width of the field.
    BUFFER   Accessor: .BUFFER
    List containing the characters in the field.
    FILL-POINTER   Accessor: .FILL-POINTER
    The current position in the input buffer to which the next character will be written.
  • Class FORM
    A form is a list of fields.
    FIELDS   Accessor: .FIELDS
    List of fields. The first field will be initialized as the current field.
    CURRENT-FIELD-NUMBER   Accessor: .CURRENT-FIELD-NUMBER
    Number of the currently selected field.
    CURRENT-FIELD   Accessor: .CURRENT-FIELD
    Currently selected field object.
    WINDOW   Accessor: .WINDOW
    Window created separately and then associated with the form.
  • Class PAD  (WINDOW)
    A pad is a window without a specified position on screen, which is specified dynamically during refresh.
    No slots.
  • Class SUB-PAD  (PAD)
    A sub-pad shares the memory and the display with a parent pad and has to be contained within it.
    PARENT
    The parent pad which will contain the sub-pad.
  • Generic-Function .POSITION (window)
  • Method .POSITION ((window window))
  • Method .POSITION ((win sub-window))
  • Generic-Function (setf .POSITION) (coordinates window)
  • Method (setf .POSITION) (coordinates (w window))
  • Generic-Function .POSITION-Y (window)
  • Method .POSITION-Y ((win window))
  • Method .POSITION-Y ((win sub-window))
  • Generic-Function .POSITION-X (window)
  • Method .POSITION-X ((win window))
  • Method .POSITION-X ((win sub-window))
  • Generic-Function (setf .POSITION-Y) (y window)
  • Method (setf .POSITION-Y) (y (win window))
  • Generic-Function (setf .POSITION-X) (x window)
  • Method (setf .POSITION-X) (x (win window))
  • Generic-Function (setf .SOURCE) (coordinates sub-window)
  • Method (setf .SOURCE) (coordinates (w sub-window))
  • Generic-Function .WIDTH (window)
  • Method .WIDTH ((window window))
  • Generic-Function .HEIGHT (window)
  • Method .HEIGHT ((window window))
  • Generic-Function .CURSOR-POSITION (window)
  • Method .CURSOR-POSITION ((window window))
  • Generic-Function (setf .CURSOR-POSITION) (coordinates window)
  • Method (setf .CURSOR-POSITION) (coordinates (w window))
  • Generic-Function .CURSOR-POSITION-Y (window)
  • Method .CURSOR-POSITION-Y ((win window))
  • Generic-Function .CURSOR-POSITION-X (window)
  • Method .CURSOR-POSITION-X ((win window))
  • Generic-Function (setf .CURSOR-POSITION-Y) (y window)
  • Method (setf .CURSOR-POSITION-Y) (y (win window))
  • Generic-Function (setf .CURSOR-POSITION-X) (x window)
  • Method (setf .CURSOR-POSITION-X) (x (win window))
  • Generic-Function .CURSOR-VISIBILITY (window)
  • Method .CURSOR-VISIBILITY ((screen screen))
  • Generic-Function (setf .CURSOR-VISIBILITY) (status screen)
  • Method (setf .CURSOR-VISIBILITY) (status (screen screen))
  • Generic-Function .INPUT-BLOCKING (window)
  • Method .INPUT-BLOCKING ((window window))
  • Generic-Function (setf .INPUT-BLOCKING) (status window)
  • Method (setf .INPUT-BLOCKING) (status (window window))
  • Generic-Function .ENABLE-FKEYS (window)
  • Method .ENABLE-FKEYS ((window window))
  • Generic-Function (setf .ENABLE-FKEYS) (status window)
  • Method (setf .ENABLE-FKEYS) (status (window window))
  • Generic-Function .ENABLE-SCROLLING (window)
  • Method .ENABLE-SCROLLING ((window window))
  • Generic-Function (setf .ENABLE-SCROLLING) (status window)
  • Method (setf .ENABLE-SCROLLING) (status (window window))
  • Generic-Function .SCROLLING-REGION (window)
  • Method .SCROLLING-REGION ((window window))
  • Generic-Function (setf .SCROLLING-REGION) (list window)
  • Method (setf .SCROLLING-REGION) (list (window window))
  • Generic-Function .INPUT-ECHOING (screen)
  • Method .INPUT-ECHOING ((screen screen))
  • Generic-Function (setf .INPUT-ECHOING) (status screen)
  • Method (setf .INPUT-ECHOING) (status (screen screen))
  • Generic-Function .INPUT-BUFFERING (screen)
  • Method .INPUT-BUFFERING ((screen screen))
  • Generic-Function (setf .INPUT-BUFFERING) (status screen)
  • Method (setf .INPUT-BUFFERING) (status (screen screen))
  • Generic-Function .PROCESS-CONTROL-CHARS (screen)
  • Method .PROCESS-CONTROL-CHARS ((screen screen))
  • Generic-Function (setf .PROCESS-CONTROL-CHARS) (status screen)
  • Method (setf .PROCESS-CONTROL-CHARS) (status (screen screen))
  • Generic-Function .BACKGROUND (window)
  • Method .BACKGROUND ((win window))
  • Generic-Function (setf .BACKGROUND) (char window &optional apply)
  • Method (setf .BACKGROUND) (char (window window) &optional (apply t))
  • Method .ATTRIBUTES ((window window))
  • Method (setf .ATTRIBUTES) (attributes (win window))
  • Method .COLOR-PAIR ((window window))
  • Method (setf .COLOR-PAIR) (color-pair (window window))
  • Generic-Function .CLOSED-P (s)
    Check whether the screen has been closed, without a subsequent call to refresh to reactivate it.
  • Method .CLOSED-P ((s screen))
  • Function ADD (window object &key attributes color-pair y x n)
    Add the object (char or string) to the window, then advance the cursor. If the destination coordinates y (row) and x (column) are given, move the cursor to the destination first and then add the object (char or string). If n is given for a char, write n chars. If n is -1, as many chars will be added as will fit on the line. If n is given for a string, write at most n chars from the string. If n is -1, as many chars will be added as will fit on the line.
  • Function ADD-CHAR (window char &key attributes color-pair y x n)
    Add the char to the window, then advance the cursor. If the destination coordinates y and x are given, move the cursor to the destination first and then add the character. If n is given, write n chars. If n is -1, as many chars will be added as will fit on the line. Example: (add-char scr #a :attributes '(:bold) :color-pair '(:red :yellow))
  • Function ECHO (window char &key attributes color-pair y x)
    Add one rendered character to the window, then refresh the window. If the destination coordinates Y and X are given, move to the destination first and then echo the character. The only difference to add-char and a subsequent refresh is a performance gain if we know that we only need to output a single character.
  • Function NEW-LINE (window &optional (count 1))
    Insert count newline characters into window.
  • Function ACS (char-name)
    Take a symbol, return the integer representing the acs char.
  • Function ADD-WIDE-CHAR-UTF-8 (window char &key attributes color-pair y x n)
    Add the wide (multi-byte) char to the window, then advance the cursor. If the destination coordinates y and x are given, move the cursor to the destination first and then add the character. If n is given, write n chars. If n is -1, as many chars will be added as will fit on the line.
  • Function ADD-WIDE-CHAR (window char &key attributes color-pair y x n)
    Add the wide (multi-byte) char to the window, then advance the cursor. If the destination coordinates y and x are given, move the cursor to the destination first and then add the character. If n is given, write n chars. If n is -1, as many chars will be added as will fit on the line.
  • Function ECHO-WIDE-CHAR (window char &key attributes color-pair y x)
    Add one rendered character to the window, then refresh the window. If the destination coordinates Y and X are given, move to the destination first and then echo the character. The only difference to add-wide-char and a subsequent refresh is a performance gain if we know that we only need to output a single character.
  • Function WACS (char-name)
    Take a keyword symbol, return the wide unicode integer representing the ACS char.
  • Function ADD-STRING (window string &key attributes color-pair y x n)
    Add the unrendered string to the window. If n is given, write at most n chars from the string. If n is -1, as many chars will be added that will fit on the line. If the coordinates y and x are given, move to the destination first and then add the string.
  • Variable *ANSI-COLOR-LIST*
    '(:black :red :green :yellow :blue :magenta :cyan :white)
  • Function ADD-ATTRIBUTES (win attributes)
    Takes a list of keywords and turns the appropriate attributes on.
  • Function REMOVE-ATTRIBUTES (win attributes)
    Takes a list of keywords and turns the appropriate attributes off.
  • Function CHANGE-ATTRIBUTES (win n attributes &key color-pair y x)
    Change the attributes of n chars starting at the current cursor position. If n is -1, as many chars will be added as will fit on the line. If the destination coordinates y and x are given, the attributes are changed from the given point without moving the cursor position.
  • Generic-Function CONVERT-CHAR (char result-type)
    Take a char and convert it to a char of result-type.
  • Method CONVERT-CHAR ((char complex-char) result-type)
  • Method CONVERT-CHAR ((char character) result-type)
  • Method CONVERT-CHAR ((char integer) result-type)
  • Function ALERT (&optional (type :beep))
  • Function BOX (window &optional (hline-char 0) (vline-char 0))
    Draw a border around the window. If any parameter is nil or zero, the default ACS char will be used.
  • Function DRAW-BORDER (window &key left right top bottom top-left top-right bottom-left bottom-right)
    Draw a border around the window using single-byte line-drawing characters. If no border chars are given, the default ncurses ACS chars will be used.
  • Function DRAW-WIDE-BORDER (window &key left right top bottom top-left top-right bottom-left bottom-right)
    Draw a border around the window using (wide) unicode line-drawing characters. If no border chars are given, the default ncurses WACS chars will be used.
  • Function CLEAR (window &key redraw (target :whole-window))
    Clear the window by overwriting it with blanks. If the keyword redraw is t, first copy blanks to every position in the window, then set the clear-redraw-flag to have the window redrawn from scratch on the next refresh. If target is :end-of-line, clear the window from the cursor to the end of the current line. If target is :bottom, clear the window from the cursor to the end of the current line and all lines below.
  • Function DELETE-CHAR (window &key y x)
    Delete the character under the cursor. All characters to the right of the cursor on the same line are moved to the left one position and the last character on the line is filled with a blank. The cursor position does not change after moving to (y,x), if specified.
  • Function DELETE-LINE (window &key (n 1))
    Delete n lines starting with the one under the cursor. The remaining lines are moved up. The bottom n lines are cleared. The current cursor position does not change.
  • Function INSERT-LINE (window &key (n 1))
    Insert n lines above the current line. The current line and the lines below are moved down. The n bottom lines are lost. The current cursor position does not change.
  • Function GET-CHAR (window &key y x)
    Read in a C char (single byte) from the keyboard and return it. If the destination coordinates y (row) and x (column) are given, move the cursor to the destination first and then read a single byte. The window from which the char is read is automatically refreshed.
  • Function UNGET-CHAR (chtype)
  • Function KEY-SUPPORTED-P (key-char)
  • Function FUNCTION-KEY (number)
  • Function FUNCTION-KEY-P (number)
  • Function KEY-PRESSED-P (window)
  • Function GET-EVENT (window)
  • Function GET-WIDE-CHAR (window &key y x)
    Read in a wide C wchar_t (multi-byte) from the keyboard and return it. If the destination coordinates y (row) and x (column) are given, move the cursor to the destination first and then read a multi-byte char. The window from which the char is read is automatically refreshed.
  • Function GET-WIDE-EVENT (window)
    Return a single user input event. An event can be a lisp character or a keyword representing a function or mouse key. If input-blocking is nil for the window, return nil if no key was typed.
  • Function GET-STRING (window n &key y x)
    Read a string from the keyboard and return it. Reading is performed until a newline or carriage return is received. The terminating character is not included in the returned string. If n is given, read at most n chars, to prevent a possible input buffer overflow. If the destination coordinates y and x are given, move the cursor there first.
  • Function END-SCREEN
    Clean shutdown of the curses display.
  • Function EXTRACT-CHAR (window &key y x)
    Extract and return the single-byte complex char from the window. If the destination coordinates y and x are given, move the cursor there first.
  • Function EXTRACT-WIDE-CHAR (window &key y x)
    Extract and return a single wide (complex) character from the window. This includes wide characters (code > 255), and requires the ncursesw library. If the destination coordinates y and x are given, move the cursor first.
  • Function EXTRACT-WIDE-STRING (window &key y x n)
    Extract and return a string from window. Any attributes are stripped from the characters before the string is returned. Start at the current cursor position and end at the right margin of window. If n is given explicitely, read at most n chars. If the destination coordinates y and x are given, move the cursor to the destination first.
  • Function EXTRACT-COMPLEX-STRING (window &key y x n)
    Extract and return a complex string from the window. Start at the current cursor position and end at the right margin of window. If n is given explicitely, read at most n chars. If the destination coordinates y and x are given, move the cursor first.
  • Function INSERT-CHAR (window char &key attributes color-pair y x)
    Insert char into window before the character currently under the cursor. Chars right of the cursor are moved one position to the right. The rightmost character on the line may be lost. The position of the cursor is not changed. If the destination coordinates y and x are given, move the cursor there first.
  • Function INSERT-WIDE-CHAR (window char &key attributes color-pair y x n)
    Insert char into window before the character currently under the cursor. Chars right of the cursor are moved one position to the right. The rightmost character on the line may be lost. The position of the cursor is not changed. If the destination coordinates y and x are given, move the cursor there first. If n is given, insert n chars.
  • Function INSERT-STRING (window string &key y x n)
    Insert string at the current position in window. Chars right of the cursor are moved to the right. The rightmost chars on the line may be lost. The cursor position is not changed. If n is given, insert n chars. If (<= n 0) insert the whole string. If the destination coordinates y and x are given, move the cursor there first.
  • Function EXTRACT-STRING (window &key y x n)
    Extract and return a string from window. Any attributes are stripped from the characters before the string is returned. Start at the current cursor position and end at the right margin of window. If n is given, read at most n chars. If the destination coordinates y and x are given, move the cursor to the destination first.
  • Function SET-MOUSE-EVENT (keyword-list)
    Take a list of mouse events, activate tracking of those events. Returns an integer bitmask. An empty list turns off mouse tracking.
  • Function GET-MOUSE-EVENT
  • Function MOVE (window y x &key relative)
    Move cursor to row y and column x. If relative is t, move the cursor by y rows and x columns.
  • Function MOVE-TO (window direction &optional (n 1))
    Move cursor in the given direction by n cells.
  • Function MOVE-WINDOW (window y x &key relative)
    Move top left corner of the window to row y and column x. If relative is t, move the window by y rows and x columns.
  • Function RAISE (win)
    Raise window one position in the stack.
  • Function RAISE-TO-TOP (win)
    Raise window to the top of the window stack.
  • Function LOWER (win)
    Lower window one position in the stack.
  • Function LOWER-TO-BOTTOM (win)
    Lower window to the bottom of the window stack.
  • Function EMPTY-STACK
    Remove all windows from the stack.
  • Function REFRESH-STACK
    Touch and refresh visible windows in the window stack.
  • Function REFRESH (win &optional pad-min-y pad-min-x screen-min-y screen-min-x screen-max-y screen-max-x)
    Redisplay the window after changes have been made to it. Copies a window to the virtual screen, then updates the visible physical screen by the contents of the virtual screen. Only updates the changed parts of the window. In order to redraw the whole window, it has to be explicitely touched or marked for redraw.
  • Function MARK-FOR-REFRESH (win &optional pad-min-y pad-min-x screen-min-y screen-min-x screen-max-y screen-max-x)
    Mark a window for a later batch-refresh. Copy a window to the virtual screen, but do not display it on the visible physical screen. Call batch-refresh to display all marked refreshes.
  • Function REFRESH-MARKED
    Refresh windows marked for refresh.
  • Function MARK-FOR-REDRAW (window &key first-line no-of-lines)
    Mark a whole window or a number of lines to be completely redrawn on the next refresh.
  • Function TOUCH (window)
    Make the next call to refresh rewrite whe whole window by marking the whole window as changed. Makes it possible to raise unchanged overlapping windows by refreshing.
  • Function RESIZE (window height width)
  • Function REMOVE-NTH (n list)
    Remove element at nth place from the list, decreasing the length of the list. Example: (remove-nth 3 '(a b c d e)) => (A B C E)
  • Function INSERT-NTH (n element list)
    Insert element into list at nth place, increasing the length of the list. Example: (insert-nth 3 'x '(a b c d e)) => (A B C X D E)
  • Function REPLACE-NTH (n element list)
    Replaces element of list at nth place, not increasing the length of the list. Example: (replace-nth 3 'x '(a b c d e)) => (A B C X E)
  • Function FIELD-BUFFER-TO-STRING (field)
    Return the value of the field buffer (list of chars) as a string.
  • Function EDIT (window object)
    Allow the used to edit fields or forms.
  • Function UPDATE-MENU (menu event)
    Take a menu and an event, update in-place the current item of the menu.
  • Generic-Function DRAW-MENU (s)
    Draw a menu.
  • Method DRAW-MENU ((menu menu))
    Draw the menu to its associated window.
  • Method DRAW-MENU ((menu menu-window))
    Draw the menu-window.
  • Method DRAW-MENU ((menu dialog-window))
  • Function RETURN-FROM-MENU (window return-value)
    Set menu window to invisible, refresh the window stack, return the value from select.
  • Function EXIT-MENU-EVENT-LOOP (window event &optional menu)
    Associate this function with an event to exit the menu event loop.
  • Function ACCEPT-SELECTION (window event &optional menu-)
    Return the value of the currently selected item or all checked items.
  • Function UPDATE-REDRAW-MENU (window event &optional menu-)
    Update the menu after an event, the redraw the menu.
  • Function TOGGLE-ITEM-CHECKBOX (window event &optional menu-)
    Toggle the checked state of the item, used in checkbox menus.
  • Function SELECT (menu)
    Display the menu, let the user select an item, return the selected item. If the item is a menu object, recursively display the sub menu.

DE.ANVI.CROATOAN.TESTS

Tests and examples demonstrating the use of the Croatoan API.
  • Function NCTEST
  • Function NCTEST2
  • Function NCTEST3
  • Function NCTEST4
    Test low-level cchar_t reading and writing. The output is: a rendered cchar_t 97 code of character #a 1 color pair 1 00020100 attribute underline #x00020000 OR-ed with bit-shifted color pair 1 We see that the attr_t slot contains _both_ the attribute _and_ the bit-shifted color pair, as if it were a chtype in ABI5. When ABI6 is used, the separate color-pair slot contains the same color pair number. The goal is obviously to make the cchar_t usable under both ABI5 and ABI6.
  • Function UT01
  • Function UT02
  • Function UT02B
  • Function UT03
  • Function UT04
  • Function TETRIS
  • Function SNAKE
  • Function PIPES
  • Function MATRIX
  • Function MATRIX2
  • Function T00
  • Function T01
  • Function T02
  • Function T02A
    Set and get a wide character background.
  • Function T03
  • Function T03A
  • Function T03A2
  • Function T03B
  • Function T03B2
  • Function T03B3
  • Function T03C
  • Function T03D
    Read and display wide (multi-byte) characters until q is pressed.
  • Function T03D2
    Use gray stream functions to read and display wide (multi-byte) characters until q is pressed.
  • Function T03E
    Test switching between input modes and control char processing.
  • Function T04 (&optional (name 'car))
  • Function T04A
  • Function T04B
  • Function T05
  • Function T06
  • Function T06A
  • Function T07
  • Function T07A
  • Function T08
  • Function T08A
  • Function T08B
  • Function T08C
  • Function T09
  • Function T09A
  • Function T09B
    Use with-screen, event-case and mapc to simplify t09a.
  • Function T09C
    Use a window stack to manage overlapping windows.
  • Function T10
  • Function T10A
  • Function T11
  • Function T12
  • Function T12A
  • Function T12B
  • Function T12C
  • Function T12C2
    ACS chars not available on all terminals: thick and double line drawing characters. Tested with xterm, gnome-terminal, st. Doesn't work in the linux console, aterm, eterm.
  • Function T12D
    Print all graphic alternative chars supported by the non-wide acs_map[128] array. Only the chars 33 to 126 are graphic, and not all are accessible through the keywords provided by ncurses, and the supported chars are terminal dependent.
  • Function T13
  • Function T14
  • Function T14A
  • Function T14B
  • Function T14C
    Print all mouse events.
  • Function T15
  • Function T15A
  • Function T15B
  • Function T16
  • Function T16A
  • Function T16B
  • Function T16C
  • Function T16D
    Use an input buffer instead of extracting the string from the window. Create windows using the with-windows macro.
  • Function T16E
    Edit a single input field, not part of a form.
  • Function T16F
    Group several input fields to a form.
  • Function T17
  • Function T17A
  • Function T18
  • Function T18A
    Display misc quicklisp information.
  • Function T19
  • Function T19A
  • Function T19B
    Use the menu class, draw-menu and select functions.
  • Function T19B2
    Use the select function with independent windows and menus
  • Function T19C
    Improved t19b, the menu can be called repeatedly with the key a.
  • Function T19C2
    Test the menu-item class for submenus.
  • Function T19D
    Use the arrow keys to pick a value from an 2D array menu, given as a layout parameter.
  • Function T19E
    A one-line menu without a title and border resembling a menu bar.
  • Function T19E2
    A menu bar and submenus.
  • Function T19F
    A more fancy version of t19a, a yes-no dialog using the class dialog-window.
  • Function T19G
    A checkbox dialog.
  • Function T20
    Display a randomly created carpet of the seven default colors, except for black.
  • Function T20A
    Display the 256 supported colors. This only works with TERM=xterm-256color in xterm and gnome-terminal.
  • Function T21
  • Function T22
  • Function T23
    Use save-excursion to return the cursor to its initial position.
  • Function T24
    Test usage of insert-line and delete-line.
  • Function T25
    Test initialisation and refreshing of pads and sub-pads.
  • Function T26
    Test accessors of window and cursor positions.
  • Function T27
    Use run-event-loop and add-event-handler instead of event-case to handle keyboard events.
  • Function T28
    Use run-event-loop and a pre-defined event handler alist. Use a default handler.
  • Function T28A
    Use run-event-loop with non-blocking events.
  • Function EVOLVE5
    Use the event-case macro for event handling.
  • Function EVOLVE6
    Use the run-event-loop for event handling.