//bindings align(4){ int NCURSES_BITS(int mask, int shift){ return (mask) << ((shift) + NCURSES_ATTR_SHIFT); } int COLOR_PAIR(int n){ return NCURSES_BITS(n, 0); } const int NCURSES_ATTR_SHIFT = 8; const int A_UNDERLINE = NCURSES_BITS(1UL,9); const int A_BOLD = NCURSES_BITS(1UL,13); const int COLOR_BLACK = 0; const int COLOR_RED = 1; const int COLOR_GREEN = 2; const int COLOR_YELLOW = 3; const int COLOR_BLUE = 4; const int COLOR_MAGENTA = 5; const int COLOR_CYAN = 6; const int COLOR_WHITE = 7; extern (C) extern int COLS; extern (C) extern int LINES; extern (C) int addch(uint); extern (C) void* stdscr; extern (C) void* initscr(); extern (C) int init_pair(short, short, short); extern (C) int clrtobot(); extern (C) int addstr(char *); extern (C) int attron(int); extern (C) int attroff(int); extern (C) int endwin(); extern (C) int move(int, int); extern (C) int getch(); extern (C) int nonl(); extern (C) int keypad(void*, bool); extern (C) int cbreak(); extern (C) int noecho(); extern (C) bool has_colors(); extern (C) int start_color(); //signals typedef void(*sighandler)(int); extern(C)void function(int) signal(int, sighandler); }