Added support for ncurses