class HighLine::Terminal::NCurses
terminal api.
@note Code migrated UNTESTED
from the old code base to the new
NCurses HighLine::Terminal
def raw_no_echo_mode
def raw_no_echo_mode FFI::NCurses.initscr FFI::NCurses.cbreak end
def restore_mode
def restore_mode FFI::NCurses.endwin end
def terminal_size
A ncurses savvy method to fetch the console columns, and rows.
(see Terminal#terminal_size)
def terminal_size size = [80, 40] FFI::NCurses.initscr begin size = FFI::NCurses.getmaxyx(FFI::NCurses.stdscr).reverse ensure FFI::NCurses.endwin end size end