]> gitweb.factorcode.org Git - factor.git/commitdiff
curses: Add some more api calls. Allow a getch that doesn't throw on errors because...
authorDoug Coleman <doug.coleman@gmail.com>
Mon, 25 Aug 2014 21:48:15 +0000 (14:48 -0700)
committerDoug Coleman <doug.coleman@gmail.com>
Mon, 25 Aug 2014 21:50:20 +0000 (14:50 -0700)
extra/curses/curses.factor
extra/curses/ffi/ffi.factor

index dc1edfc33352944ced05cd689af305eed32816c0..a6629650ad107cd92250d7f3a2ee70fd2eae7448 100644 (file)
@@ -322,6 +322,9 @@ PRIVATE>
 : wgetch ( window -- key ) ptr>> (wgetch) ;
 : getch ( -- key ) current-window get wgetch ;
 
+: wgetch-err ( window -- key ) ptr>> ffi:wgetch ;
+: getch-err ( -- key ) current-window get wgetch-err ;
+
 : waddch ( ch window -- ) ptr>> (waddch) ;
 : addch ( ch -- ) current-window get waddch ;
 
index c3b0d42cd260b97529c67708352d053b01d794dd..9c87d72173d2c4d72331bd2430fcac81bf69888d 100644 (file)
@@ -280,3 +280,7 @@ FUNCTION: int wborder ( WINDOW* win, chtype ls, chtype rs, chtype ts, chtype bs,
 FUNCTION: int box ( WINDOW* win, chtype verch, chtype horch ) ;
 FUNCTION: int whline ( WINDOW* win, chtype ch, int n ) ;
 FUNCTION: int wvline ( WINDOW* win, chtype ch, int n ) ;
+
+FUNCTION: bool is_term_resized ( int lines, int columns ) ;
+FUNCTION: int resize_term ( int lines, int columns ) ;
+FUNCTION: int resizeterm ( int lines, int columns ) ;