Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <curses.h>
- int main(void) {
- int KeyPressed;
- system("mode 100, 50");
- initscr(); // Here we go!
- raw();
- nonl();
- noecho();
- keypad(stdscr, TRUE);
- curs_set(2);
- WINDOW *Wind;
- // This works fine.
- Wind=newwin(3, 10, 4, 4);
- box(Wind, 0, 0);
- wnoutrefresh(Wind);
- wrefresh(Wind);
- doupdate();
- // This also works.
- KeyPressed = getch();
- move(5, 12);
- wnoutrefresh(Wind);
- wrefresh(Wind);
- doupdate();
- // This does not appear to move the cursor.
- KeyPressed = getch();
- wmove(Wind, 1, 1);
- wnoutrefresh(Wind);
- wrefresh(Wind);
- doupdate();
- KeyPressed = getch();
- endwin();
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment