ncurses.c
changeset 45 7197576fedcf
parent 27 81a574d60c15
child 77 49e0babccb23
equal deleted inserted replaced
44:bb6586b1c547 45:7197576fedcf
    32         return EXIT_FAILURE;
    32         return EXIT_FAILURE;
    33     }
    33     }
    34     return EXIT_SUCCESS;
    34     return EXIT_SUCCESS;
    35 }
    35 }
    36 
    36 
    37 wchar_t fucnt (WINDOW * win)
    37 wchar_t func (WINDOW * win)
    38 {
    38 {
    39     wchar_t guess;
    39     wchar_t guess;
    40 
    40 
    41     char dest[4];
    41     char dest[4];
    42 
    42 
    43     int maxx;
    43     int maxx;
    44 
       
    45     int maxy;
    44     int maxy;
    46 
    45 
    47     while (guess != ESCAPE) {
    46     while (guess != ESCAPE) {
    48         while ((get_wch (&guess)) != OK)
    47         while ((get_wch (&guess)) != OK)
    49             /*
    48             /*
    80 
    79 
    81     WINDOW *win;
    80     WINDOW *win;
    82 
    81 
    83     check_locale ();
    82     check_locale ();
    84     win = initscr ();
    83     win = initscr ();
       
    84     keypad (win, 1);
    85     noecho ();
    85     noecho ();
    86     x = fucnt (win);
    86 
       
    87     x = func (win);
       
    88 
    87     endwin ();
    89     endwin ();
    88 
       
    89     printf ("\n");
    90     printf ("\n");
    90 
    91 
    91     return EXIT_SUCCESS;
    92     return EXIT_SUCCESS;
    92 }
    93 }