Annotation of capa/capa51/pProj/capalogineditor.c, revision 1.1.1.1

1.1       albertel    1: /* gather subjective answers from student */
                      2: 
                      3: #define    BS    8
                      4: #define    DEL   127
                      5: #define    ESC   27
                      6: 
                      7: #define    COLON 58
                      8: 
                      9: #define EDIT_HEIGHT 21
                     10: #define EDIT_WIDTH 80
                     11: 
                     12: void init_editor(char*** sbuf_pp)
                     13: {
                     14:   int   ww=EDIT_WIDTH, hh=EDIT_HEIGHT,i;
                     15:   *sbuf_pp = (char **)capa_malloc(sizeof(char *),hh);
                     16:   for(i=0;i<hh;i++) {
                     17:     *sbuf_pp[i] = (char *)capa_malloc(sizeof(char)*ww+1,1);
                     18:   }
                     19: }
                     20: 
                     21: int handle_keystrokes_editor(char** sbuf_pp)
                     22: {
                     23: }
                     24: 
                     25: int editor(char*** sbuf_pp)
                     26: {
                     27:   init_editor(sbuf_pp);
                     28:   return handle_keystrokes_editor(*sbuf_pp);
                     29: }
                     30: 
                     31: void
                     32: answer_subjective(student_number,set,section,prob)
                     33: char  *student_number; 
                     34: int    set; 
                     35: int   *section;
                     36: int    prob;
                     37: {
                     38:   char **sbuf_pp;
                     39: 
                     40:   if (editor(&sbuf_pp)) {
                     41:     /*turn sbuf_pp into one string and store subjective*/
                     42:   }
                     43: }

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>