[comp.sources.amiga] v91i084: Quiz 1.0 - question and answer program, Part01/02

amiga-request@ab20.larc.nasa.gov (Amiga Sources/Binaries Moderator) (04/10/91)

Submitted-by: creubank@is.crl.sony.co.jp
Posting-number: Volume 91, Issue 084
Archive-name: applications/quiz-1.0/part01

[ executable to appear in comp.binaries.amiga  ...tad ]

Quiz 1.0, similar to UNIX's /usr/games/quiz, will quiz you given a
question-answer file.  It keeps a history over trials and questions,
and can graph the results.  I find it useful for practicing
vocabulary.  Source, binary and a couple of sample quiz files are
included.  Enjoy.
				      -creubank

#!/bin/sh
# This is a shell archive.  Remove anything before this line, then unpack
# it by saving it into a file and typing "sh file".  To overwrite existing
# files, type "sh file -c".  You can also feed this as standard input via
# unshar, or by typing "sh <file", e.g..  If this archive is complete, you
# will see the following message at the end:
#		"End of archive 1 (of 2)."
# Contents:  README graph.c graph.h mymalloc.c nihongo1 nihongo1.sc
#   parse.c.h qstructs.h quiz-with screen.h thumbdown.bi thumbup.bi
#   zhongwen1 zhongwen1.sc
# Wrapped by tadguy@ab20 on Wed Apr 10 10:57:36 1991
PATH=/bin:/usr/bin:/usr/ucb ; export PATH
if test -f 'README' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'README'\"
else
echo shar: Extracting \"'README'\" \(6623 characters\)
sed "s/^X//" >'README' <<'END_OF_FILE'
X20 March 1991
X
XQuiz 1.0
X
X1. INTRODUCTION
X
XThis is the first release of quiz, a simple question-answer program
Xsimilar to the unix program /usr/games/quiz.  It is useful for
Xmemorizing vocabulary or other information that can be related in
Xpairs, for example, country names and their capital cities.
X
XGiven an input file of questions and answers, quiz will ask the user
Xquestions and grade the user's answers.  The program can be run from
XCLI or workbench.  (I haven't made a nice icon for it yet.)   You can
Xuse data files from /usr/games/quiz as well.  Simply type:
X
X CLI> quiz [quizfile] [-switch] [-help] [-ignorecase]
X
XArgument order doesn't matter and you can abbreviate the options to a
Xsingle letter (i.e. "-s").  Options:
X
X   -switch: Asks the answer and expects question.
X
X   -ignorecase: case doesn't matter
X
X   -help: displays a brief help message and exits
X
XQuiz records and can graph previous sessions to show your progress
Xover time.
X
X2. EXAMPLE SESSION
X
XAs an example, try:
X
X  1> quiz nihongo1
X
XQuiz will open up a new screen.  Since we have specified a question
Xfile, quiz begins by quizzing us right away.  Type your answer to the
Xquestion in the text gadget.  Quiz will ask all of the questions from
Xthe data file in a random order until you get them all right.  If you
Xmiss any particular question more than four times (#define'd as
XMAXWRONG in "qstructs.h") quiz will assume you are hopeless on that
Xquestion and not ask it again.  You now know enough to use the basic
Xfeatures of quiz.  Read on only if you want details.
X
XAfter you have answered all the questions, a list of the questions you
Xmissed and your score will be printed on the CLI from which you
Xstarted quiz.
X
X3. COMMANDS
X
XTo load a new file, type the file name in the same text gadget that is
Xused for answers.  Then select "Load" from the main menu or use
X"Right-Amiga L".  The session will begin immediately.  After a session
Xis complete, you can rerun it by selecting "Begin" from the main menu
Xor by using the keyboard equivalent (Right-Amiga b).  "Quit" from the
Xmain menu will end the quiz session.
X
X4. HISTORY GRAPHING
X
XAfter the first time you answer a question file, subsequent sessions
Xwill show the history of your progress in one of two ways.  The
Xdefault graph is a bar graph that shows how often you answered each
Xquestion incorrectly.  I.e., the higher the bar, the more times you
Xhave missed that question.  Clicking on a question's bar will make
Xquiz switch to that question immediately.  The previously displayed
Xquestion will be asked again later.  Switch to the questions graph by
Xselecting "Graph ?'s" from the Options menu (or use Right-Amiga ?).
X
XQuestions not yet answered are shown in flesh-color.  Questions
Xanswered correcty the first time are shown in sky blue.  Those that
Xhave been missed at least once are shown in a kind of reddish-brown.
X
XThe other graph shows your total score across many sessions for a
Xparticular data file.  Select this graph from the Options menu "Graph
XTrials" selection (or use Right-Amiga t).  Clicking on a bar in this
Xmode has no meaning.
X
XQuiz saves history information for question file "quizdata" in
X"quizdata.sc".  In order to save history information, there must be
Xroom on the quiz data volume and it must be writable.
X
X5. OTHER OPTIONS
X
XOther options are available from the Options menu as follows:
X
X  5.1  Switch      (Right-Amiga s)
X       Simply switches the question and answer.  Thus you will be given
X       the answer and have to provide the question.  (No fair using
X       this to cheat.)
X
X  5.2  Ignore Case (Right-Amiga i)
X       If Ignore Case is selected, case does not matter.  I.e., "CaT"
X       would match "cat".  Default is that case DOES matter.
X
X  5.3  Abort       (Right-Amiga a)
X       Selecting abort causes the current trial to end.  A history
X       entry will not be written.
X
X6. THE QUESTION FILE
X
XA quiz data file contains lines of the form:
X
Xquestion:answer
X
XIn the simplest case, this could be something like:
X
XLargest state in the US:Alaska
X
XYou can specify more than one match by using '|'.  For example:
X
XFirst President of the US:George Washington|George|Washington
X
XThus any of "George", "Washington" or "George Washington" would be a
Xcorrect response to this question.  In addition, '{' and '}' can be
Xused to save typing and disk space.  Brackets can be nested to any
Xdepth.  Trailing and leading white space is deleted in an entry and in
Xthe user's answer.
X
XQuiz {Author|Programmer}:{Curtis|C{.} {R}} Eubanks
X
XThis question patterns matches: (only one will be displayed as the
Xquestion)
X
X  Quiz Author
X  Quiz Programmer
X
Xand the answer pattern:
X  Curtis Eubanks
X  C Eubanks
X  C. Eubanks
X  C R Eubanks
X  C. R Eubanks
X
XNote that {.} matches both the empty string and '.'.
X
XSeveral example files are included.  When you finish a quiz session, a
Xscore file is written: "quizfile.sc" and appended to each additional
Xtime the program is run with quizfile.  Each line of this file contains
Xa list of the missed questions.
X
X7. THE THUMB
X
XThe thumb doesn't mean anything yet, but if you click on it, it changes
Xstate.  Use it to boost your morale or something.
X
X8.  THE CODE
X
XThis was written on a plain Amiga 1000 over a year ago.  I compiled it
Xwith Lattice 3.10.  To compile, execute the following lattice commands:
X
X 1> lc -ac screen
X 1> lc quiz parse mymalloc graph
X 1> blink with quiz-with
X
XThis program is public domain.  I wouldn't mind getting a $10 or $15
Xdonation if you find it useful, but I don't require it.  If I ever
Xmake an significant update, anyone who sends me $15 or more will
Xreceive the new version.  This program can be freely distributed as
Xlong as all of the files in this directory are included.  If you make
Xany changes to the code, please let me know before redistributing.
X
XI hope you enjoy "quiz" and that you find it useful---it has been for
Xme. 
XThere are undoubtedly bugs in the code.  If you find any, please let
Xme know.  (If possible, provide a fix.)  I have not tested this code on
Xanything other than an Amiga 1000.  Also drop me a note if you find
Xerrors in this documentation, or if you feel any part is unclear/not
Xdetailed enough/too detailed. 
X
XAny questions or comments are always welcome.  Mail to any of the
Xfollowing will get to me (if you are sending money in US dollars, it
Xis better to send it to the US address):
X
X   creubank@is.crl.sony.co.jp   creubank@media-lab.media.mit.edu
X
X   Curtis Eubanks               Curtis Eubanks
X   Mezon Marukyo Rm 201         c/o Vernon Eubanks
X   5-38-10 Minami-magome        6984 Y Lightning Ranch Rd.
X   Oota-ku, Tokyo 143 JAPAN     Hereford, AZ 85616 USA
END_OF_FILE
if test 6623 -ne `wc -c <'README'`; then
    echo shar: \"'README'\" unpacked with wrong size!
fi
# end of 'README'
fi
if test -f 'graph.c' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'graph.c'\"
else
echo shar: Extracting \"'graph.c'\" \(11010 characters\)
sed "s/^X//" >'graph.c' <<'END_OF_FILE'
X/***
X *** graph.c
X *** routines to draw quiz graph
X ***
X *** Curtis Eubanks 3 December 1989
X ***
X ***/
X
X#include <intuition/intuition.h>
X#define GLOBALVAR extern
X#include "qstructs.h"
X#include "graph.h"
X/*---------------------*/
X/*  stuff in screen.h  */
X/*---------------------*/
Xextern struct Border gtop; /* border structure for graph */
Xextern short gbotpts[], gtoppts[];
Xextern struct RastPort *rp;
X
X/*---------------------*/
X/* functions in quiz.c */
X/*---------------------*/
Xextern int readfile();
Xextern int countlines();
Xextern QuizState qstate;
Xextern void ilistAdd();
Xextern ilist *Makeilist();
Xextern char **extractlines();
Xextern void NonFatalError();
X
X/*-------------------------*/
X/* functions in mymalloc.c */
X/*-------------------------*/
Xextern char *mymalloc();
X
X/*------------------*/
X/* stuff in parse.h */
X/*------------------*/
Xextern void remwh();
X
X/**********************/
Xint numspaces(), readscore();
Xvoid printstats(), SetWorstQuestion();
Xvoid cleargraph(), drawgraph();
Xvoid UpdateCurrentQ();
Xint *AddTrial(), whichquestion();
X
X/* buffer to hold score file */
Xchar *scbuff = NULL;
X
Xtypedef struct _ScoreData {
X   short numtrials;
X   short num_questions;  /* greatest index of a missed question        */
X   short worst_trial;    /* the worst trial                            */
X   short most_missed;    /* max # of questions missed in one trial     */
X   short worst_question; /* the number of times the worst question was */
X                         /* missed--not the index!                     */
X   ilist *trial_data;    /* data for # questions missed for each trial */
X                         /* this is an ilist because we want to add a  */
X                         /* new value every time a trial is run        */
X   int   *quest_data;    /* data for each question  --                 */
X                         /* # times missed over all trials             */
X} ScoreData;
XScoreData sdata;
X
X/* count the number of spaces in a string      */
X/* returns -1 if the string is the null string */
Xint numspaces(s)
X  char *s;
X{
X int n=0;
X if (*s == '\0') return -1;
X while (*s) { if (*s == ' ') n++; s++; }
X return n;
X} /* numspaces */
X
X/* read in .sc file.  If one doesn't exist or otherwise unsuccessful,
X   returns 0.  Otherwise returns 1 */
X
Xint readscore(num)
X  int num; /* # of questions in question file */
X{
X  char scorefile[MAXFILENAME+3];
X  char **lines;
X  int n,i,j,/*greatest=-1*/;
X  int worstt = -1, worstq = -1, worsttnum=0;
X
X  int    an_int;
X  char  *sptr;
X  ilist *iptr;
X
X  strcpy(scorefile,qstate.File);
X  strcat(scorefile, ".sc");
X#ifdef DEBUG
Xprintf("Readfile: num is %d\n",num);
X#endif
X  if (readfile(scorefile, &scbuff)==0) return 0;
X
X  /* successful read */
X  n = countlines(scbuff);
X#ifdef DEBUG
Xprintf("n=%d num=%d\n",n,num);
X#endif
X
X  lines = extractlines(n, scbuff);
X#ifdef DEBUG
Xprintf("lines=%d\n",lines);
X#endif
X
X  /* We want to be able to present the graph in two ways---
X     by the total number of items missed each time and for each
X     item, the number of times it was missed over all trials:
X
X       | *                 item1 |****
X# of   | *                 item2 |*
Xmissed | **                item3 |
Xitems  | ***      *        item4 |*********
X       |_***__*___**__     item5 |***_________
X         trial                     #times missed
X
X     Because of this, we should represent the data in two ways.
X  */
X  sdata.numtrials = n;
X  sdata.num_questions = num;
X  iptr = NULL;
X /*  sdata.trial_data = Makeilist(0); old->Allocate(n * sizeof(int));*/
X  for (i=0;i<n;i++) {
X    int num_missed;
X    remwh(lines[i]); /* space at the end */
X    num_missed = numspaces(lines[i])+1;
X    if (iptr) {
X      ilistAdd(iptr, num_missed);
X      if (num_missed > worstt) worstt = num_missed, worsttnum=i;
X      } /* if */
X    else {
X    sdata.trial_data = Makeilist(num_missed);
X    iptr = sdata.trial_data;
X    worstt = num_missed; /* worsttnum already = 0 */
X    } /* else */
X
X    /* just speeds things up for ilistAdd */
X     if (iptr->next) iptr = iptr->next;        /* does nothing first time */
X
X    } /* i */
X  sdata.worst_trial = worsttnum; sdata.most_missed = worstt;
X  sdata.quest_data = (int *)Allocate(num * sizeof(int)); /* zeroed */
X
X  for (iptr = sdata.trial_data,i=0;iptr;iptr=iptr->next, i++) {
X    sptr = lines[i];
X    for (j = 0; j < iptr->i; j++) {
X      sscanf(sptr, "%d", &an_int);
X      if (an_int>num) NonFatalError("Warning: score file is corrupt!\n");
X      else sdata.quest_data[an_int]++;
X      while ((*sptr != ' ')&&(*sptr != '\n')) sptr++;
X      sptr++; /* point to next integer */
X      } /* j */
X    } /* iptr, i */
X  /* and once more just for fun! */
X  for (i=0;i<num;i++)
X    if (sdata.quest_data[i] > worstq) worstq = sdata.quest_data[i];
X  sdata.worst_question = worstq;
X
X/* printstats();*/
X cleargraph();
X drawgraph();
X return BYQUESTION;
X} /* readscore */
X
X/* update sdata by adding the data from a new trial.  If this is the first
X   trial, we also set qstate.GraphType */
Xint *AddTrial(numwrong,numq)
X   int numwrong,numq; /* number wrong this trial */
X{
X  int i, worstt=-1, worsttnum = 0;
X  ilist *iptr;
X  sdata.numtrials++;
X
X  if (qstate.GraphType) {
X    ilistAdd(sdata.trial_data, numwrong);
X    /* need to set sdata.worst_trial as well! */
X    if (numwrong > sdata.most_missed) sdata.most_missed = numwrong;
X    for (i=0;i<sdata.num_questions;i++)
X      if (sdata.quest_data[i] > sdata.worst_question)
X         sdata.worst_question = sdata.quest_data[i];
X    } /* if */
X  else {
X    sdata.numtrials = 1;
X    sdata.trial_data = Makeilist(numwrong);
X    sdata.num_questions = numq;
X    sdata.quest_data = (int *)Allocate(sdata.num_questions * sizeof(int));
X    sdata.worst_trial = 0;
X    sdata.worst_question = 0;
X    qstate.GraphType = BYQUESTION;
X    } /* else */
X
X    /* find worst trial */
X   iptr = sdata.trial_data; i = 0; worstt = iptr->i;
X   while (iptr) {
X     if (iptr->i > worstt) worstt = iptr->i,worsttnum = i;
X     i++;
X     iptr = iptr->next;
X     } /* while iptr */
X
X   sdata.worst_trial = worsttnum;
X   sdata.most_missed = worstt;
X
X   return sdata.quest_data;
X} /* AddTrial */
X
X/* sets the worst question */
Xvoid SetWorstQuestion(n)
X  int n;
X{ sdata.worst_question = (short)n; } /* SetWorstQuestion */
X
Xvoid printstats()
X{
X int i, t=0;
X ilist *iptr;
X printf(" %d trials\n", sdata.numtrials);
X printf(" %d questions\n", sdata.num_questions);
X printf(" worst trial   : %d\n", sdata.worst_trial);
X printf(" worst question: %d\n", sdata.worst_question);
X printf(" trials\n");
X iptr = sdata.trial_data;
X while (iptr) {
X   printf("%d\t",t++);
X   for (i=0;i<iptr->i;i++) printf("*"); printf("\n");
X   iptr = iptr->next;
X   } /* while */
X printf("questions\n");
X for (i=0;i<sdata.num_questions;i++) {
X   for (t=0;t<sdata.quest_data[i];t++) printf("*"); printf("\n");
X   } /* for */
X}  /* printstats */
X
X#define GREY7 25 /* 888 */
X/* clear the graph area */
Xvoid cleargraph() {
X   SetDrMd(rp, JAM1);
X   SetAPen(rp, GREY7);
X   RectFill(rp, (int)gtoppts[2], (int)gtoppts[3],
X            (int)gbotpts[2], (int)gbotpts[3]);
X} /* cleargraph */
X/* Draw the graph represented by the current ScoreData structure */
X#define GRAPHCOLOR 19
X#define SELECTCOLOR 0
X#define WRONGCOLOR 16 /* red   */ 
X#define RIGHTCOLOR 10 /* green */
Xvoid drawgraph() {
X
X  /* The amount of screen that we have available for use is defined
X     in graph.h.  We (well, *I*) will center the the graph in this
X     box.  We have to find a reasonable number of elements with a
X     reasonable width */
X
X   short startx, i, width, height;
X   ilist *iptr;
X
X   SetAPen(rp, GRAPHCOLOR);
X   SetDrMd(rp, JAM1);
X   if (qstate.GraphType == BYTRIAL) {
X#if 0
X     if ((sdata.numtrials * BESTWIDTH) < GRAPHW) /* no need to muck w/stuff */
X#endif
X
X       DrawBorder(rp,&gtop,0,0);
X       width = (short)((float)GRAPHW / (float)sdata.numtrials);
X       if (width == 0) return;
X       height = (short) ((float)GRAPHH / (float)sdata.most_missed);
X       startx = GRAPHX + GRAPHW/2 - (sdata.numtrials*width)/2;
X       for (iptr=sdata.trial_data;iptr;startx+=width,iptr=iptr->next)
X         RectFill(rp, startx, GRAPHY+GRAPHH-height*iptr->i,
X                  startx+width-1, GRAPHY+GRAPHH);
X      } /* if BYTRIAL */
X
X   else if (qstate.GraphType == BYQUESTION) {
X      DrawBorder(rp, &gtop, 0, 0);
X      width = (short)((float)GRAPHW / (float)sdata.num_questions);
X      if (width == 0) return;
X      height = (short) ((float)GRAPHH / (float)sdata.worst_question);
X      startx = GRAPHX + GRAPHW/2 - (sdata.num_questions*width)/2;
X      if ((history == NULL) || (hindices==NULL)) return;
X      for (i=0; i < sdata.num_questions; i++,) {
X         if (history[i] == RIGHT)
X           SetAPen(rp, RIGHTCOLOR);
X         else if (history[i])
X           SetAPen(rp, WRONGCOLOR);
X         else
X           SetAPen(rp, GRAPHCOLOR);
X         RectFill(rp, startx+width*hindices[i],
X                  GRAPHY+GRAPHH-height*sdata.quest_data[hindices[i]],
X                  startx+(hindices[i]+1)*width-1, GRAPHY+GRAPHH);
X         } /* for */
X         if (qstate.Asking) {
X           SetAPen(rp, SELECTCOLOR);
X           RectFill(rp, startx+width*currentquestion,
X                  GRAPHY+GRAPHH-height*sdata.quest_data[currentquestion],
X                  startx+(currentquestion+1)*width-1, GRAPHY+GRAPHH);
X           } /* if */
X   } /* if BYQUESTION */
X} /* drawgraph */
X
X/* change graph colors to reflect new current color */
X/* *note*: sets currentquestion to new!!!           */
Xvoid UpdateCurrentQ(old,new)
X   int old, new;
X{
X   short startx, width, height, oindex=-1,i;
X   currentquestion = new;
X   if (qstate.GraphType != BYQUESTION) return;
X 
X   width = (short)((float)GRAPHW / (float)sdata.num_questions);
X   if (width == 0) return;
X   height = (int) ((float)GRAPHH / (float)sdata.worst_question);
X   startx = GRAPHX + GRAPHW/2 - (sdata.num_questions*width)/2;
X   /* draw old in graph color */
X   /* this is really bad */
X   for (i=0; oindex == -1; i++) if (hindices[i]==old) oindex = i;
X
X   if (history[oindex]==RIGHT) SetAPen(rp, RIGHTCOLOR);
X   else if (history[oindex]) SetAPen(rp, WRONGCOLOR);
X   else SetAPen(rp, GRAPHCOLOR);
X
X   RectFill(rp, startx+width*old, GRAPHY+GRAPHH -
X            height*sdata.quest_data[old], startx+width*(old+1)-1,
X            GRAPHY+GRAPHH);
X
X  /* and new */
X   SetAPen(rp, SELECTCOLOR);
X   RectFill(rp, startx+width*new, GRAPHY+GRAPHH -
X            height*sdata.quest_data[new], startx+width*(new+1)-1,
X            GRAPHY+GRAPHH);
X
X} /* UpdateCurrentQ */
X
X/* find which question is pointed to by x, y, if any.  Return the index,
X   or -1 if none */
Xint whichquestion(x,y)
X    SHORT x, y;
X{
X  short startx, endx, width;
X  if ((x < GRAPHX) || (x > GRAPHX+GRAPHW) ||
X      (y < GRAPHY) || (y > GRAPHY+GRAPHH)) return -1;
X  width = (short)((float)GRAPHW / (float)sdata.num_questions);
X  startx = GRAPHX + GRAPHW/2 - (sdata.num_questions*width)/2;
X  if (x < startx) return -1;
X
X  endx = startx + sdata.num_questions * width;
X  if (x > endx) return -1;
X
X  return (int) ((float)(x-startx) / (float) width);
X} /* which question */
END_OF_FILE
if test 11010 -ne `wc -c <'graph.c'`; then
    echo shar: \"'graph.c'\" unpacked with wrong size!
fi
# end of 'graph.c'
fi
if test -f 'graph.h' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'graph.h'\"
else
echo shar: Extracting \"'graph.h'\" \(181 characters\)
sed "s/^X//" >'graph.h' <<'END_OF_FILE'
X#define GRAPHW 150
X#define GRAPHH 50
X#define GRAPHX 150
X#define GRAPHY 15
X#define BESTWIDTH 4
X/* graph types */
X#define NOGRAPH      0
X#define BYTRIAL      1
X#define BYQUESTION   2
END_OF_FILE
if test 181 -ne `wc -c <'graph.h'`; then
    echo shar: \"'graph.h'\" unpacked with wrong size!
fi
# end of 'graph.h'
fi
if test -f 'mymalloc.c' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'mymalloc.c'\"
else
echo shar: Extracting \"'mymalloc.c'\" \(7288 characters\)
sed "s/^X//" >'mymalloc.c' <<'END_OF_FILE'
X/***
X ***  mymalloc.c
X ***
X ***  Curtis Eubanks
X ***  2 November 1989
X ***
X ***/
X
X/*#define DEBUG*/
X#ifndef NULL
X#include <stdio.h>
X#endif
X#include <exec/types.h>
X#include <exec/memory.h>
X#define GLOBALVAR extern
X#include "qstructs.h"
X/***
X mymalloc is my first stab at decreasing the memory fragmentation that
X results from allocating a large number of small memory chunks.
X
X mymalloc contains a list of free memory chunks (initially NULL).  The
X first time mymalloc(numbytes) is called, it will allocated a chunk of
X size (numbytes + INITCHUNKSIZE) bytes.  The bytesfree field in this
X initial chunk is set to INITCHUNKSIZE.
X
X On successive calls, mymalloc tries to allocate enough the requested
X size from the first element of the memory chunk list.  If there isn't
X enough room, a new chunk is created of size (numbytes +
X INITCHUNKSIZE).  The list of chunks is kept sorted so that requests
X for small amounts of memory can be efficiently allocated.  Whenever
X the bytesfree field of a memory chunk is less than MINFREE, that
X chunk is removed from the available memory chunk list.
X
X If numbytes < 1 or if there isn't enough system memory, mymalloc
X returns NULL.  Otherwise, a pointer to the new (zeroed) memory is
X returned.
X
X My malloc rounds numbytes to sizeof(int) so that the returned pointer is
X word-aligned.
X***/
X
X#define MINFREE 1
X#define INITCHUNKSIZE 4096
X
Xextern char *AllocMem();
Xchar *mymalloc();
X
Xstruct memchunk {
X  char *chunkptr;
X  int bytesfree;
X};
X
Xstruct chunklist {
X  struct memchunk *chunk;
X  struct chunklist *next,*prev;
X};
X
Xstatic struct chunklist *availmem = NULL;
X
Xchar *mymalloc(numbytes)
X  int numbytes;			/* number of bytes to allocate */
X{
X  char *rtn;
X  struct chunklist *curchunk;
X
X#ifdef DEBUG
Xprintf("myalloc called with %d; availmem is %d; *availmem is %d\n",
X        numbytes, availmem, *availmem);
X#endif
X  if (numbytes<1) return(NULL);
X  /* long word align */
X  if (numbytes % sizeof(int)) numbytes += sizeof(int) - numbytes % sizeof(int);
X
X  if (availmem==NULL) {			/* first time? */
X
X    availmem = (struct chunklist *)
X      AllocMem(sizeof(struct chunklist),MEMF_CLEAR);
X    if (availmem == NULL)
X      FatalError("Out of memory!  Couldn't allocate %ld bytes\n",
X                  sizeof(struct chunklist));
X    CleanUp(ALLOC_MSG, (char *)availmem, sizeof(struct chunklist));
X
X
X    availmem->next = NULL;
X    availmem->prev = NULL;
X
X    availmem->chunk = (struct memchunk *)
X       AllocMem(sizeof(struct memchunk),MEMF_CLEAR);
X    if (availmem->chunk == NULL)
X      FatalError("Out of memory!  Couldn't allocate %ld bytes\n",
X                  sizeof(struct memchunk));
X    CleanUp(ALLOC_MSG, (char *)availmem->chunk, sizeof(struct memchunk));
X
X    availmem->chunk->chunkptr =
X      AllocMem(numbytes + INITCHUNKSIZE,MEMF_CLEAR);
X    if (availmem->chunk->chunkptr==NULL) return(NULL);
X    CleanUp(ALLOC_MSG, (char *)availmem->chunk->chunkptr,
X            numbytes + INITCHUNKSIZE);
X
X    availmem->chunk->bytesfree = INITCHUNKSIZE;
X    rtn = availmem->chunk->chunkptr;
X    availmem->chunk->chunkptr += numbytes;
X#ifdef DEBUG
X  {
X   int numchunk = 0;
X   struct chunklist *last;
X   last = availmem;
X   printf("Availmem:\n");
X   if (!last) printf(" [chunklist empty]\n");
X   while (last) {
X     numchunk++;
X     printf("  chunk %ld = %ld, prev=%ld, next=%ld,\n\tptr=%d, free=%ld\n",
X            numchunk, last, last->prev, last->next, last->chunk->chunkptr,
X            last->chunk->bytesfree);
X     last=last->next;
X     } /* while last */
X  } /* DEBUG */
X#endif
X
X    return(rtn);
X    } /* if availmem==NULL */
X
X  curchunk = availmem;
X  /* step through memory list looking for enough memory */
X  while (curchunk) {
X    if (curchunk->chunk->bytesfree >= numbytes) {
X      /* found enough! */
X      rtn = curchunk->chunk->chunkptr;
X      curchunk->chunk->chunkptr += numbytes; /* forgot this! */
X      curchunk->chunk->bytesfree -= numbytes;
X
X      /* We're not done yet.  Have to sort the chunklist.  The only
X         modified chunk is curchunk, so it's the only chunk that may
X         have to be repositioned. */
X
Xreposcheck:
X      if (   (curchunk != availmem) /* I love it */
X          && (curchunk->prev->chunk->bytesfree >
X              curchunk->chunk->bytesfree))
X        { /* have to reposition curchunk */
X          /* <-a<->b<->c ==> <-b<->a<->c */
X	  struct chunklist *a, *b, *c;
X          b = curchunk;    a = b->prev;    c = b->next;
X          /* detach b */
X          a->next = c;
X          if (c) c->prev = a;
X          /* reattach b */
X          b->prev = a->prev; /* might be NULL */
X          b->next = a;
X          a->prev = b;
X          if (b->prev == NULL) availmem = b;
X          curchunk = b;
X          goto reposcheck;       /* may have to do it again */
X        }
X#ifdef DEBUG
X  {
X   int numchunk = 0;
X   struct chunklist *last;
X   last = availmem;
X   printf("Availmem:\n");
X   if (!last) printf(" [chunklist empty]\n");
X   while (last) {
X     numchunk++;
X     printf("  chunk %ld = %ld, prev=%ld, next=%ld,\n\tptr=%d, free=%ld\n",
X            numchunk, last, last->prev, last->next, last->chunk->chunkptr,
X            last->chunk->bytesfree);
X     last=last->next;
X     } /* while last */
X  } /* DEBUG */
X#endif
X
X       return(rtn);
X    } /* if there's enough memory in this chunk */
X  curchunk = curchunk->next;
X  } /* while curchunk */
X  /* didn't find memory, must allocate more */
X  {
X  struct chunklist *newchunk, *last;
X
X  newchunk = (struct chunklist *)
X    AllocMem(sizeof (struct chunklist),MEMF_CLEAR);
X  if (newchunk == NULL)
X    FatalError("Out of memory!  Couldn't allocate %ld bytes\n",
X      sizeof(struct chunklist));
X  CleanUp(ALLOC_MSG, (char *)newchunk, sizeof(struct chunklist));
X
X  newchunk->chunk = (struct memchunk *)
X     AllocMem(sizeof(struct memchunk),MEMF_CLEAR);
X  if (newchunk->chunk==NULL)
X    FatalError("Out of memory!  Couldn't allocate %ld bytes\n",
X      sizeof(struct memchunk));
X  CleanUp(ALLOC_MSG, (char *)newchunk->chunk, sizeof(struct memchunk));
X
X  newchunk->chunk->chunkptr =
X    AllocMem(numbytes + INITCHUNKSIZE,MEMF_CLEAR);
X  if (newchunk->chunk->chunkptr==NULL) return(NULL);
X  CleanUp(ALLOC_MSG, (char *)newchunk->chunk->chunkptr,
X          numbytes + INITCHUNKSIZE);
X
X  newchunk->chunk->bytesfree = INITCHUNKSIZE;
X  /* and add it to the list */
X  last = availmem;
X  while (last->next) last = last->next;
X  last->next = newchunk;
X  newchunk->prev = last;
X  newchunk->next = NULL; /* should already be */
X  rtn = newchunk->chunk->chunkptr;
X  newchunk->chunk->chunkptr += numbytes;
X#ifdef DEBUG
X  {
X   int numchunk = 0;
X   struct chunklist *last;
X   last = availmem;
X   printf("Availmem:\n");
X   if (!last) printf(" [chunklist empty]\n");
X   while (last) {
X     numchunk++;
X     printf("  chunk %ld = %ld, prev=%ld, next=%ld,\n\tptr=%d, free=%ld\n",
X            numchunk, last, last->prev, last->next, last->chunk->chunkptr,
X            last->chunk->bytesfree);
X     last=last->next;
X     } /* while last */
X  } /* DEBUG */
X#endif
X
X  return(rtn);
X  }
X} /* mymalloc */
X
X/* This is a hack.  It doesn't really free the memory, but, by setting
X   availmem to NULL, mymalloc thinks that there is no free memory and
X   will allocate new memory.  It is necessary for the memory to be freed
X   elsewhere! */
Xvoid ForgetMemory()
X  {
X   availmem = NULL;
X  } /* ForgetMemory */
END_OF_FILE
if test 7288 -ne `wc -c <'mymalloc.c'`; then
    echo shar: \"'mymalloc.c'\" unpacked with wrong size!
fi
# end of 'mymalloc.c'
fi
if test -f 'nihongo1' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'nihongo1'\"
else
echo shar: Extracting \"'nihongo1'\" \(528 characters\)
sed "s/^X//" >'nihongo1' <<'END_OF_FILE'
Xto come out (album, movie):dete{ }kuru
Xpiece/song:kyoku
Xfirecracker:bakuchiku
Xbattery:denchi
Xtoy:omocha
XTGIF:hana{ }kin
Xto be audible:kikoeru
Xto turn:mawasu|magaru
Xto get tired of x:{x ni} akiru
Xforget it (said to yourself):ki{ }ni shinai
Xchange (money):{o}tsuri
Xsubway entrance/exit area:kaisatsu{ }guchi
Xto return (not kaeru):modoru
Ximpossible:muri|fukano{o|u}
Xto eat (male):kuu
Xto loaf around the house:goro{ }goro {suru}
Xto dry:kansou {suru}
Xdirection:ho{o|u}{ko{o|u}|men}
Xmethod:ho{o|u}ho{o|u}
Xto get lost:{michi ni} mayou
END_OF_FILE
if test 528 -ne `wc -c <'nihongo1'`; then
    echo shar: \"'nihongo1'\" unpacked with wrong size!
fi
# end of 'nihongo1'
fi
if test -f 'nihongo1.sc' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'nihongo1.sc'\"
else
echo shar: Extracting \"'nihongo1.sc'\" \(7 characters\)
sed "s/^X//" >'nihongo1.sc' <<'END_OF_FILE'
X0 3 9 
END_OF_FILE
if test 7 -ne `wc -c <'nihongo1.sc'`; then
    echo shar: \"'nihongo1.sc'\" unpacked with wrong size!
fi
# end of 'nihongo1.sc'
fi
if test -f 'parse.c.h' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'parse.c.h'\"
else
echo shar: Extracting \"'parse.c.h'\" \(464 characters\)
sed "s/^X//" >'parse.c.h' <<'END_OF_FILE'
Xextern void slistAdd();
Xextern struct slist *Makeslist();
Xint slistSize();
Xextern void remwh();
Xextern char *findfirstbrace();
Xextern char *findlevel();
Xextern void deletebrackets();
Xextern char *snarfbrackets();
Xextern void printslist();
Xextern struct slist *FindOrs();
Xextern struct slist *findors();
Xextern int checkbrackets();
Xextern struct slist *joinslists();
Xextern char *findmatchbrace();
Xextern struct slist *expandslist();
Xextern struct slist *expand();
END_OF_FILE
if test 464 -ne `wc -c <'parse.c.h'`; then
    echo shar: \"'parse.c.h'\" unpacked with wrong size!
fi
# end of 'parse.c.h'
fi
if test -f 'qstructs.h' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'qstructs.h'\"
else
echo shar: Extracting \"'qstructs.h'\" \(1712 characters\)
sed "s/^X//" >'qstructs.h' <<'END_OF_FILE'
X/* messages sent from bhandlemsg() to quiz() */
X#define QUITNOW       -1
X#define IGNORE         0
X#define NEWSTRING      1
X#define SWITCHEM       2
X#define OPENNEWFILE    3
X#define STARTASKING    4
X#define ABORTNOW       5
X#define DISPLAYQ       6 /* display a new question */
X
X
X
X/**** cleanup messages ****/
X#define DONE_MSG 0
X#define ALLOC_MSG 1
X#define LOCK_MSG 2
X#define INIT_MSG 3
X#define NEWSCREEN_MSG 4
X#define NEWWINDOW_MSG 5
X#define LIB_MSG 6
X#define FREEONE_MSG 7
X#define FREEALL_MSG 8
X
X#define ALLOC_TYPE 1
X#define LOCK_TYPE 2
X#define SCREEN_TYPE 4
X#define WINDOW_TYPE 5
X#define LIB_TYPE 6
X
X#define MAXFILENAME 80
X#define SCORE_FILE_EXT ".sc"
X
X#define RIGHT 256
X#define MAXWRONG -4
X
X/***** type definitions ******/
X
Xtypedef struct _QuizState {
X   short Switch;         /* if 1, switch questions and answers */
X   short CaseSensitive;  /* if 1, case matters                 */
X   short Asking;         /* if 1, we are currently in ask mode */
X   short ShowingAns;     /* if 1, we are showing an answer     */
X   short GraphType;      /* if 0, we no graph (no score file)  */
X                         /* if 1, graph by trials              */
X                         /* if 2, graph by questions           */
X   char File[MAXFILENAME];
X   } QuizState;
X
XGLOBALVAR QuizState qstate;
XGLOBALVAR char *buf;
XGLOBALVAR int newquestion; /* a new question was selected */
XGLOBALVAR int currentquestion;
XGLOBALVAR short *history, *hindices;
X
X/* Resource List */
Xstruct ResListItem {
X  struct Node n;
X  char *ptr;
X  int size, type;
X};
X
X/* an slist is a linked list of strings */
Xstruct slist { char *s; struct slist *next; };
X
X/* linked list of ints */
Xtypedef struct _ilist { int i; struct _ilist *next; } ilist;
X
END_OF_FILE
if test 1712 -ne `wc -c <'qstructs.h'`; then
    echo shar: \"'qstructs.h'\" unpacked with wrong size!
fi
# end of 'qstructs.h'
fi
if test -f 'quiz-with' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'quiz-with'\"
else
echo shar: Extracting \"'quiz-with'\" \(190 characters\)
sed "s/^X//" >'quiz-with' <<'END_OF_FILE'
X;
X; Blink with file
X; quiz
X; 3 Nov 1989
X; 18 Nov 1989
X
XFROM
X   lib:c.o
X   quiz.o
X   parse.o
X   mymalloc.o
X   screen.o
X   graph.o
XLIB
X   lib:lc.lib
X   lib:amiga.lib
X   lib:lcm.lib
XTO
X   quiz
END_OF_FILE
if test 190 -ne `wc -c <'quiz-with'`; then
    echo shar: \"'quiz-with'\" unpacked with wrong size!
fi
# end of 'quiz-with'
fi
if test -f 'screen.h' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'screen.h'\"
else
echo shar: Extracting \"'screen.h'\" \(9874 characters\)
sed "s/^X//" >'screen.h' <<'END_OF_FILE'
X#include <exec/types.h>
X#include <intuition/intuition.h>
X#include <graphics/gfx.h>
X#include "thumbup.bi"
X#include "thumbdown.bi"
X#define GLOBALVAR extern
X#include "qstructs.h"
X
X#define DPEN 0
X#define BPEN 1
X#define MFPEN 0
X#define MBPEN 2
X
Xextern struct IntuitionBase *IntuitionBase;
Xextern struct GfxBase *GfxBase;
Xextern struct Screen *OpenScreen();
Xextern struct Window *OpenWindow();
Xstruct IntuiMessage *GetMsg();
X
X/* default DPaint colormap */
XUSHORT mycmap[] = {
X   0x0000,0x0eca,0x0e00,0x0a00,0x0d80,0x0fe0,0x08f0,0x0080,
X   0x00b6,0x00dd,0x00af,0x007c,0x000f,0x070f,0x0c0e,0x0c08,
X   0x0620,0x0e52,0x0a52,0x0fca,0x0333,0x0444,0x0555,0x0666,
X   0x0777,0x0888,0x0999,0x0aaa,0x0ccc,0x0ddd,0x0eee,0x0fff
X   };
X#define GREY1  0  /* 000 */  /* black */
X#define GREY2  20 /* 333 */
X#define GREY3  21 /* 444 */
X#define GREY4  22 /* 555 */
X#define GREY5  23 /* 666 */
X#define GREY6  24 /* 777 */
X#define GREY7  25 /* 888 */
X#define GREY8  26 /* 999 */
X#define GREY9  27 /* aaa */
X#define GREY10 28 /* ccc */
X#define GREY11 29 /* ddd */
X#define GREY12 30 /* eee */
X#define GREY13 31 /* fff */  /* white */
X
Xstruct TextAttr topaz = { "topaz.font", 8, 0, 0};
Xstruct NewScreen ns = {0,0,320,200,5,DPEN,BPEN,0,CUSTOMSCREEN,&topaz,
X                       "Quiz",NULL,NULL };
Xstruct Screen *qscreen = NULL;
X
Xstruct NewWindow /*errnw = { 0,15,100,50,DPEN,BPEN,CLOSEWINDOW|REFRESHWINDOW,
X                           SIMPLE_REFRESH|WINDOWCLOSE|WINDOWDRAG|WINDOWSIZING,
X                           NULL,NULL,"Error Window",NULL,NULL,30,30,100,40,
X                           CUSTOMSCREEN},*/
X backnw = {0,0,320,200,DPEN,GREY7,
X           REFRESHWINDOW|GADGETDOWN|GADGETUP|MENUPICK|ACTIVATE|MOUSEBUTTONS,
X           BACKDROP|SIMPLE_REFRESH|BORDERLESS,NULL,NULL,
X           "",NULL,NULL,0,0,0,0,CUSTOMSCREEN};
X
Xstruct Window *backwindow = NULL;
Xstruct RastPort *rp;
Xstruct ViewPort *vp;
Xstruct IntuiMessage *mes;
X
Xint maxqchars=0,baseheight=0;
X#define MAXQCHARS 120
X#define STRINGID 1
X#define IMAGEID 2
X
X#define BUFFLEN 128
Xchar sbuff[BUFFLEN], ubuff[BUFFLEN], *qtext=NULL, *atext=NULL, *ctext=NULL;
Xstruct StringInfo sStringInfo = {
X  /* Buffer, UndoBuffer  */ sbuff, ubuff,
X  /* BufferPos, MaxChars */ 0, BUFFLEN};
X
X#define CENTERX(width) (160-((width)/2))
X
X#define BORDWIDTH 3
X#define SGADW 280
X#define SGADH 8
X#define SGADX CENTERX(SGADW)
X#define SGADY 125
X#define QX (SGADX+3)
X/* position of "Correct Text" box */
X#define CX QX
X#define CY (SGADY+20)
X
X#define MAXLINES 5 /* maximum number of lines in question text */
X#define QY SGADY-MAXLINES*8-6
X#define MAXQX QX + SGADW
X
X#define IGADW 103
X#define IGADH 43
X#define IGADX 15      /*CENTERX(IGADW)*/
X#define IGADY 20
X
X#include "graph.h"     /* defines GRAPHW, GRAPHH, GRAPHX, GRAPHY */
X
Xshort gbotpts[] = { GRAPHX+GRAPHW+BORDWIDTH,GRAPHY-BORDWIDTH,
X                    GRAPHX+GRAPHW+BORDWIDTH,GRAPHY+GRAPHH+BORDWIDTH,
X                    GRAPHX-BORDWIDTH,GRAPHY+GRAPHH+BORDWIDTH };
Xshort gtoppts[] = { GRAPHX-BORDWIDTH,GRAPHY+GRAPHH+BORDWIDTH,
X                    GRAPHX-BORDWIDTH,GRAPHY-BORDWIDTH,
X                    GRAPHX+GRAPHW+BORDWIDTH,GRAPHY-BORDWIDTH };
X
Xshort botbordpts[] = { SGADW+BORDWIDTH,-BORDWIDTH,
X                       SGADW+BORDWIDTH,SGADH+BORDWIDTH,
X                       -BORDWIDTH,SGADH+BORDWIDTH };
Xshort topbordpts[] = { -BORDWIDTH,SGADH+BORDWIDTH,
X                       -BORDWIDTH,-BORDWIDTH,
X                       SGADW+BORDWIDTH,-BORDWIDTH };
X
Xshort iconbotpts[] = { IGADX+IGADW+BORDWIDTH,IGADY-BORDWIDTH,
X                       IGADX+IGADW+BORDWIDTH,IGADY+IGADH+BORDWIDTH,
X                       IGADX-BORDWIDTH,IGADY+IGADH+BORDWIDTH };
Xshort icontoppts[] = { IGADX-BORDWIDTH,IGADY+IGADH+BORDWIDTH,
X                       IGADX-BORDWIDTH,IGADY-BORDWIDTH,
X                       IGADX+IGADW+BORDWIDTH,IGADY-BORDWIDTH };
X
Xshort qpb[] = {0,0,0,0,0,0}, qpt[] = {0,0,0,0,0,0};
Xshort cpb[] = {0,0,0,0,0,0}, cpt[] = {0,0,0,0,0,0};
X
X/*   bottom and right side border of sgadget   */
Xstruct Border borderbot = {
X   /* LeftEdge, TopEdge */  0,0,
X   /* FrontPen, BackPen */  GREY2, 0,
X   /* DrawMode          */  JAM1,
X   /* Count             */  3,
X   /* *XY               */  botbordpts,
X   /* NextBorder        */  NULL
X   };
Xstruct Border bordertop = { 0,0,GREY11,0,JAM1,3,topbordpts,&borderbot };
Xstruct Border ibb       = { 0,0,GREY2, 0,JAM1,3,iconbotpts,NULL       };
Xstruct Border ibt       = { 0,0,GREY11,0,JAM1,3,icontoppts,&ibb       };
Xstruct Border qbot      = { 0,0,GREY2, 0,JAM1,3,qpb,NULL              };
Xstruct Border qtop      = { 0,0,GREY11,0,JAM1,3,qpt,&qbot             };
Xstruct Border cbot      = { 0,0,GREY2, 0,JAM1,3,cpb,NULL              };
Xstruct Border ctop      = { 0,0,GREY11,0,JAM1,3,cpt,&cbot             };
Xstruct Border gbot      = { 0,0,GREY2, 0,JAM1,3,gbotpts,NULL          };
Xstruct Border gtop      = { 0,0,GREY11,0,JAM1,3,gtoppts,&gbot         };
X
Xstruct Gadget igadget = {
X  /* NextGadget        */ NULL,
X  /* LeftEdge, TopEdge */ IGADX, IGADY,
X  /* Width, Height     */ IGADW, IGADH,
X  /* Flags             */ GADGHIMAGE|GADGIMAGE,
X  /* Activation        */ TOGGLESELECT|RELVERIFY,
X  /* GadgetType        */ BOOLGADGET,
X  /* GadgetRender      */ (APTR)(&thumbup),
X  /* SelectRender      */ (APTR)(&thumbdown),
X  /* GadgetText        */ NULL,
X  /* MutualExclude     */ 0,
X  /* SpecialInfo       */ NULL,
X  /* GadgetID          */ IMAGEID,
X  /* UserData          */ NULL };
X
Xstruct Gadget sgadget = { &igadget,SGADX,SGADY,SGADW,SGADH,GADGHCOMP,
X                         TOGGLESELECT|RELVERIFY,STRGADGET,(APTR)(&bordertop),
X                         NULL,NULL,0,(APTR)(&sStringInfo),STRINGID,NULL };
X
X#define PROJMENU 0
X#define OPTMENU 1
X#define MENU1WIDTH 73
X#define MENU2WIDTH 143
X#define MENUITEMHEIGHT 10
X
Xstruct IntuiText ProjMIQuitText =
X{
X  /* FrontPen, BackPen */ MFPEN, MBPEN,
X  /* DrawMode          */ JAM1,
X  /* LeftEdge, TopEdge */ 2, 0,
X  /* ITextFont         */ &topaz,
X  /* IText             */ "Quit     ",
X  /* NextText          */ NULL
X},
XProjMILoadText={MFPEN,MBPEN,JAM1,2,0,&topaz,"Load     ",NULL},
XProjMIAboutText={MFPEN,MBPEN,JAM1,2,0,&topaz,"About    ",NULL},
XProjMIBeginText={MFPEN,MBPEN,JAM1,2,0,&topaz,"Begin    ",NULL},
X
XOptMISwitchText={MFPEN,MBPEN,JAM1,2,0,&topaz,"  Switch       ",NULL},
XOptMIIgnoreText={MFPEN,MBPEN,JAM1,2,0,&topaz,"  Ignore case  ",NULL},
XOptMIAbortText={MFPEN,MBPEN,JAM1,2,0,&topaz, "  Abort        ",NULL},
XOptMITrialText={MFPEN,MBPEN,JAM1,2,0,&topaz, "  Graph trials ",NULL},
XOptMIQuestText={MFPEN,MBPEN,JAM1,2,0,&topaz, "  Graph ?'s    ",NULL};
X
X#if 0
Xstruct MenuItem ProjMINone = {
X/* NextItem              */ &MProjMIDumb,/*(struct MenuItem *)NULL,*/
X/* LeftEdge, TopEdge     */ 5, MENUITEMHEIGHT*2,
X/* Width, Height         */ MENU1WIDTH-5, 0,
X/* Flags                 */ ITEMENABLED|ITEMTEXT|HIGHBOX|COMMSEQ,
X/* MutualExclude         */ 0,
X/* ItemFill              */ (APTR)(&ProjMIQuitText),
X/* SelectFill            */ (APTR)NULL,
X/* Command               */ 'q',
X/* SubItem               */ (struct MenuItem *)NULL,
X/* NextSelect            */ 0
X};
X#endif
X
X#define QUITNUM 3
Xstruct MenuItem MProjMIQuit =
X { NULL,5,MENUITEMHEIGHT*3,MENU1WIDTH,MENUITEMHEIGHT,
X   ITEMENABLED|ITEMTEXT|HIGHBOX/*|COMMSEQ*/,0,(APTR)(&ProjMIQuitText),
X   (APTR)NULL,'\0',NULL,0};
X
X#define BEGINNUM 2
X#define BEGINMENUNUM (SHIFTITEM(BEGINNUM)|SHIFTSUB(NOSUB)) /* first menu */
Xstruct MenuItem MProjMIBegin =
X { &MProjMIQuit,5,MENUITEMHEIGHT*2,MENU1WIDTH,MENUITEMHEIGHT,
X   ITEMENABLED|ITEMTEXT|HIGHBOX|COMMSEQ,0,(APTR)(&ProjMIBeginText),
X   (APTR)NULL,'b',NULL,0};
X
X#define LOADNUM 1
Xstruct MenuItem MProjMILoad =
X { &MProjMIBegin,5,MENUITEMHEIGHT*1,MENU1WIDTH,MENUITEMHEIGHT,
X   ITEMENABLED|ITEMTEXT|HIGHBOX|COMMSEQ,0,(APTR)(&ProjMILoadText),
X   (APTR)NULL,'l',NULL,0};
X
X#define ABOUTNUM 0
Xstruct MenuItem MProjMIAbout =
X { &MProjMILoad,5,MENUITEMHEIGHT*0,MENU1WIDTH,MENUITEMHEIGHT,
X   ITEMENABLED|ITEMTEXT|HIGHBOX/*|COMMSEQ*/,0,(APTR)(&ProjMIAboutText),
X   (APTR)NULL,0,NULL,0};
X
X/* these two are mutually excluded */
X#define MENUBYQUESTION 4
X#define MENUBYTRIAL 3
X#define TRIALMENUNUM (SHIFTMENU(1)|SHIFTITEM(MENUBYTRIAL)|SHIFTSUB(NOSUB))
X#define QUESTMENUNUM (SHIFTMENU(1)|SHIFTITEM(MENUBYQUESTION)|SHIFTSUB(NOSUB))
X
Xstruct MenuItem MOptQuest =
X  {
X   NULL, 1, MENUITEMHEIGHT*4, MENU2WIDTH,
X   MENUITEMHEIGHT,
X   ITEMENABLED|ITEMTEXT|HIGHBOX|COMMSEQ|CHECKIT|MENUTOGGLE,
X   1<<MENUBYTRIAL,(APTR)(&OptMIQuestText),
X   (APTR)NULL, '?', NULL, 0};
X
Xstruct MenuItem MOptTrial =
X  {
X   &MOptQuest, 1, MENUITEMHEIGHT*3, MENU2WIDTH,
X   MENUITEMHEIGHT,
X   ITEMENABLED|ITEMTEXT|HIGHBOX|COMMSEQ|CHECKIT|MENUTOGGLE|CHECKED,
X   1<<MENUBYQUESTION,(APTR)(&OptMITrialText),
X   (APTR)NULL, 't', NULL, 0};
X
X#define ABORTNUM 2
Xstruct MenuItem MOptAbort =
X { &MOptTrial,1,MENUITEMHEIGHT*2,MENU2WIDTH,
X   MENUITEMHEIGHT,
X   ITEMENABLED|ITEMTEXT|HIGHBOX|COMMSEQ,
X   0,(APTR)(&OptMIAbortText),
X   (APTR)NULL,'a',NULL,0};
X
X#define IGNORENUM 1
Xstruct MenuItem MOptIgnore =
X { &MOptAbort,1,MENUITEMHEIGHT*1,MENU2WIDTH,
X   MENUITEMHEIGHT,
X   ITEMENABLED|ITEMTEXT|HIGHBOX|COMMSEQ|CHECKIT|MENUTOGGLE,
X   0,(APTR)(&OptMIIgnoreText),
X   (APTR)NULL,'i',NULL,0};
X
X#define SWITCHNUM 0
Xstruct MenuItem MOptSwitch =
X { &MOptIgnore,1,MENUITEMHEIGHT*0,MENU2WIDTH,
X   MENUITEMHEIGHT,
X   ITEMENABLED|ITEMTEXT|HIGHBOX|COMMSEQ|CHECKIT|MENUTOGGLE,
X   0,(APTR)(&OptMISwitchText),
X   (APTR)NULL,'s',NULL,0};
X
Xstruct Menu *menustrip[3];
X
Xstruct Menu m1 = {
X     /* NextMenu           */ NULL,/*&menustrip[1],*/
X     /* LeftEdge, TopEdge  */ 1, 0,
X     /* Width, Height      */ MENU1WIDTH, 0,
X     /* Flags              */ MENUENABLED,
X     /* MenuName           */ "Project",
X     /* FirstItem          */ &MProjMIAbout
X };
X
Xstruct Menu m2 = { NULL, 90, 0, MENU2WIDTH, 0, MENUENABLED,
X                   "Options", &MOptSwitch };
X
X/* no room for another menu in lo res :-(
Xstruct Menu m3 = { NULL, 180, 0, MENU3WIDTH, 0, MENUENABLED,
X                   "Graph", &MGraphByTrial };
X*/
END_OF_FILE
if test 9874 -ne `wc -c <'screen.h'`; then
    echo shar: \"'screen.h'\" unpacked with wrong size!
fi
# end of 'screen.h'
fi
if test -f 'thumbdown.bi' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'thumbdown.bi'\"
else
echo shar: Extracting \"'thumbdown.bi'\" \(10965 characters\)
sed "s/^X//" >'thumbdown.bi' <<'END_OF_FILE'
X/* thumbdown.bi */
X
Xextern UWORD thumbdown_data[];
X
X
X/* IMAGE STRUCTURE */
X
Xstruct Image thumbdown = {
X   0, 0, 103, 43, 5, &thumbdown_data[0], 31, 0, NULL};
X
X/* IMAGE DATA */
X
XUWORD thumbdown_data[7 * 43 * 5] = {
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0003,0xc000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0007,0xffc0,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x000f,0xfffe,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x000f,0xffff,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x007f,0xffff,0xf800,0x0000,0x0000,0x0000,0x0000,
X0x00f7,0xffff,0xfc00,0x0000,0x0000,0x0000,0x0000,
X0x01f8,0x3fff,0xfe00,0x00ee,0x77f9,0xc000,0x0000,
X0x01ff,0xffff,0xffff,0xf7ff,0xffff,0xf000,0x0000,
X0x01ff,0xffff,0xffbf,0xffff,0xffff,0xfe00,0x0000,
X0x00ff,0xffff,0xffbf,0xffff,0xffff,0xfe00,0x0000,
X0x037f,0xffff,0xfeff,0xffff,0xffff,0xfff0,0x0000,
X0x07c3,0xffff,0xff3f,0xffff,0xffff,0xfffe,0x0000,
X0x0ffd,0xffff,0xffff,0xffff,0xffff,0xfffe,0x0000,
X0x0fff,0xffff,0xff7f,0xffff,0xffff,0xffff,0x0000,
X0x0fff,0xffff,0xfeff,0xffff,0xffff,0xffff,0x8000,
X0x07ff,0xffff,0xfcff,0xffff,0xffff,0xffff,0x8000,
X0x03ff,0xffff,0xfc1f,0xffff,0xffff,0xffff,0xc000,
X0x0e03,0xffff,0xf807,0xffff,0xffff,0xffff,0x8000,
X0x1fff,0xffff,0xf000,0x3bff,0xffff,0xffff,0xc000,
X0x3fff,0xffff,0xf000,0x003f,0xffff,0xffff,0xe000,
X0x3fff,0xffff,0xe000,0x0003,0xffff,0xffff,0xe000,
X0x0fff,0xffff,0xe000,0x0001,0xffff,0xffff,0xe000,
X0x03ff,0xff6f,0xc000,0x0000,0x3fff,0xffff,0xc000,
X0x003e,0xe03f,0x8000,0x0000,0x1fff,0xffff,0x8000,
X0x0000,0x003f,0x8000,0x0000,0x01ff,0xfff8,0x0000,
X0x0000,0x003f,0x0000,0x0000,0x00ff,0xfff0,0x0000,
X0x0000,0x003f,0x8000,0x0000,0x000f,0xffe0,0x0000,
X0x0000,0x003f,0x8000,0x0000,0x0000,0x0e00,0x0000,
X0x0000,0x003f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x000f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x000f,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0007,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0001,0xe000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0xc000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0003,0xc000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0007,0xffc0,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x000f,0xfffe,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x000f,0xffff,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x007f,0xffff,0xf800,0x0000,0x0000,0x0000,0x0000,
X0x00f7,0xffff,0xfc00,0x0000,0x0000,0x0000,0x0000,
X0x01f8,0x3fff,0xfe00,0x00ee,0x77f9,0xc000,0x0000,
X0x01ff,0xffff,0xffff,0xf7ff,0xffff,0xf000,0x0000,
X0x01ff,0xffff,0xffbf,0xffff,0xffff,0xfe00,0x0000,
X0x00ff,0xffff,0xffbf,0xffff,0xffff,0xfe00,0x0000,
X0x037f,0xffff,0xfeff,0xffff,0xffff,0xfff0,0x0000,
X0x07c3,0xffff,0xff3f,0xffff,0xffff,0xfffe,0x0000,
X0x0ffd,0xffff,0xffff,0xffff,0xffff,0xfffe,0x0000,
X0x0fff,0xffff,0xff7f,0xffff,0xffff,0xffff,0x0000,
X0x0fff,0xffff,0xfeff,0xffff,0xffff,0xffff,0x8000,
X0x07ff,0xffff,0xfcff,0xffff,0xffff,0xffff,0x8000,
X0x03ff,0xffff,0xfc1f,0xffff,0xffff,0xffff,0xc000,
X0x0e03,0xffff,0xf807,0xffff,0xffff,0xffff,0x8000,
X0x1fff,0xffff,0xf000,0x3bff,0xffff,0xffff,0xc000,
X0x3fff,0xffff,0xf000,0x003f,0xffff,0xffff,0xe000,
X0x3fff,0xffff,0xe000,0x0003,0xffff,0xffff,0xe000,
X0x0fff,0xffff,0xe000,0x0001,0xffff,0xffff,0xe000,
X0x03ff,0xff6f,0xc000,0x0000,0x3fff,0xffff,0xc000,
X0x003e,0xe03f,0x8000,0x0000,0x1fff,0xffff,0x8000,
X0x0000,0x003f,0x8000,0x0000,0x01ff,0xfff8,0x0000,
X0x0000,0x003f,0x0000,0x0000,0x00ff,0xfff0,0x0000,
X0x0000,0x003f,0x8000,0x0000,0x000f,0xffe0,0x0000,
X0x0000,0x003f,0x8000,0x0000,0x0000,0x0e00,0x0000,
X0x0000,0x003f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x000f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0xc000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0xc000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x000f,0xe000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0007,0xe000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0001,0xe000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0xc000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0003,0xc000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0007,0xffc0,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x000f,0xfffe,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x000f,0xffff,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x007f,0xffff,0xf800,0x0000,0x0000,0x0000,0x0000,
X0x00f7,0xffff,0xfc00,0x0000,0x0000,0x0000,0x0000,
X0x01f8,0x3fff,0xfe00,0x00ee,0x77f9,0xc000,0x0000,
X0x01ff,0xffff,0xffff,0xf7ff,0xffff,0xf000,0x0000,
X0x01ff,0xffff,0xffbf,0xffff,0xffff,0xfe00,0x0000,
X0x00ff,0xffff,0xffbf,0xffff,0xffff,0xfe00,0x0000,
X0x037f,0xffff,0xfeff,0xffff,0xffff,0xfff0,0x0000,
X0x07c3,0xffff,0xff3f,0xffff,0xffff,0xfffe,0x0000,
X0x0ffd,0xffff,0xffff,0xffff,0xffff,0xfffe,0x0000,
X0x0fff,0xffff,0xff7f,0xffff,0xffff,0xffff,0x0000,
X0x0fff,0xffff,0xfeff,0xffff,0xffff,0xffff,0x8000,
X0x07ff,0xffff,0xfcff,0xffff,0xffff,0xffff,0x8000,
X0x03ff,0xffff,0xfc1f,0xffff,0xffff,0xffff,0xc000,
X0x0e03,0xffff,0xf807,0xffff,0xffff,0xffff,0x8000,
X0x1fff,0xffff,0xf000,0x3bff,0xffff,0xffff,0xc000,
X0x3fff,0xffff,0xf000,0x003f,0xffff,0xffff,0xe000,
X0x3fff,0xffff,0xe000,0x0003,0xffff,0xffff,0xe000,
X0x0fff,0xffff,0xe000,0x0001,0xffff,0xffff,0xe000,
X0x03ff,0xff6f,0xc000,0x0000,0x3fff,0xffff,0xc000,
X0x003e,0xe03f,0x8000,0x0000,0x1fff,0xffff,0x8000,
X0x0000,0x003f,0x8000,0x0000,0x01ff,0xfff8,0x0000,
X0x0000,0x003f,0x0000,0x0000,0x00ff,0xfff0,0x0000,
X0x0000,0x003f,0x8000,0x0000,0x000f,0xffe0,0x0000,
X0x0000,0x003f,0x8000,0x0000,0x0000,0x0e00,0x0000,
X0x0000,0x003f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x000f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0xc000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0xc000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x000f,0xe000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0007,0xe000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0001,0xe000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0xc000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000};
END_OF_FILE
if test 10965 -ne `wc -c <'thumbdown.bi'`; then
    echo shar: \"'thumbdown.bi'\" unpacked with wrong size!
fi
# end of 'thumbdown.bi'
fi
if test -f 'thumbup.bi' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'thumbup.bi'\"
else
echo shar: Extracting \"'thumbup.bi'\" \(10955 characters\)
sed "s/^X//" >'thumbup.bi' <<'END_OF_FILE'
X/* thumbup.bi */
X
Xextern UWORD thumbup_data[];
X
X
X/* IMAGE STRUCTURE */
X
Xstruct Image thumbup = {
X   0, 0, 103, 43, 5, &thumbup_data[0], 31, 0, NULL};
X
X/* IMAGE DATA */
X
XUWORD thumbup_data[7 * 43 * 5] = {
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0007,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x000f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x000f,0xc000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x000f,0xc000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0xc000,0x0000,0x0000,0x0000,0x0000,
X0x07df,0x701f,0xc000,0x0000,0x0000,0x0000,0x0000,
X0x0fe7,0xffff,0xe000,0x0000,0x0000,0x0000,0x0000,
X0x1fff,0xffff,0xf000,0x0000,0x0000,0x0000,0x0000,
X0x1fff,0xffff,0xf000,0x0000,0x0000,0x0000,0x0000,
X0x1ff9,0xffff,0xf800,0x0000,0x0000,0x0000,0x0000,
X0x0ff0,0xffff,0xf800,0x0000,0x0000,0x0000,0x0000,
X0x061b,0xffff,0xfc00,0x00ee,0x77f5,0xc000,0x0000,
X0x01ff,0x7f7f,0xff0f,0xf7ff,0xffff,0xf000,0x0000,
X0x03ff,0x9f3f,0xfeff,0xffff,0xffff,0xfe00,0x0000,
X0x07ff,0x3f9f,0xfeff,0xffff,0xffff,0xfe00,0x0000,
X0x07ff,0x3fe7,0xffff,0xffff,0xffff,0xfff0,0x0000,
X0x07ff,0xdff1,0xff7f,0xffff,0xffff,0xfffe,0x0000,
X0x03f3,0xc7dd,0xffff,0xffff,0xffff,0xfffe,0x0000,
X0x01a7,0xc79f,0xff7f,0xffff,0xffff,0xffff,0x0000,
X0x007f,0xffbf,0xffff,0xffff,0xffff,0xffff,0x8000,
X0x00ff,0xffff,0xffff,0xffff,0xffff,0xffff,0x8000,
X0x00ff,0xc7ff,0xffff,0xffff,0xffff,0xffff,0xc000,
X0x00ff,0x7bff,0xff07,0xffff,0xffff,0xffff,0x8000,
X0x007c,0xf9ff,0xfe00,0x3bff,0xffff,0xffff,0xc000,
X0x003f,0xfbff,0xfc00,0x003f,0xffff,0xffff,0xe000,
X0x0007,0xffff,0x8000,0x0003,0xffff,0xffff,0xe000,
X0x0007,0xffff,0x0000,0x0001,0xffff,0xffff,0xe000,
X0x0003,0xffe0,0x0000,0x0000,0x3fff,0xffff,0xc000,
X0x0001,0xe000,0x0000,0x0000,0x1fff,0xffff,0x8000,
X0x0000,0x0000,0x0000,0x0000,0x01ff,0xfff8,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x00ff,0xfff0,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x000f,0xfde0,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0c00,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0007,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x000f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x000f,0xc000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x000f,0xc000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0xc000,0x0000,0x0000,0x0000,0x0000,
X0x07df,0x701f,0xc000,0x0000,0x0000,0x0000,0x0000,
X0x0fe7,0xffff,0xe000,0x0000,0x0000,0x0000,0x0000,
X0x1fff,0xffff,0xf000,0x0000,0x0000,0x0000,0x0000,
X0x1fff,0xffff,0xf000,0x0000,0x0000,0x0000,0x0000,
X0x1fff,0xffff,0xf800,0x0000,0x0000,0x0000,0x0000,
X0x0fff,0xffff,0xf800,0x0000,0x0000,0x0000,0x0000,
X0x061f,0xffff,0xfc00,0x00ee,0x77f5,0xc000,0x0000,
X0x01ff,0x7f7f,0xff0f,0xf7ff,0xffff,0xf000,0x0000,
X0x03ff,0xff3f,0xfeff,0xffff,0xffff,0xfe00,0x0000,
X0x07ff,0xff9f,0xfeff,0xffff,0xffff,0xfe00,0x0000,
X0x07ff,0xffe7,0xffff,0xffff,0xffff,0xfff0,0x0000,
X0x07ff,0xdff1,0xff7f,0xffff,0xffff,0xfffe,0x0000,
X0x03f3,0xffdd,0xffff,0xffff,0xffff,0xfffe,0x0000,
X0x01a7,0xff9f,0xff7f,0xffff,0xffff,0xffff,0x0000,
X0x007f,0xffbf,0xffff,0xffff,0xffff,0xffff,0x8000,
X0x00ff,0xffff,0xffff,0xffff,0xffff,0xffff,0x8000,
X0x00ff,0xc7ff,0xffff,0xffff,0xffff,0xffff,0xc000,
X0x00ff,0x7fff,0xff07,0xffff,0xffff,0xffff,0x8000,
X0x007c,0xffff,0xfe00,0x3bff,0xffff,0xffff,0xc000,
X0x003f,0xffff,0xfc00,0x003f,0xffff,0xffff,0xe000,
X0x0007,0xffff,0x8000,0x0003,0xffff,0xffff,0xe000,
X0x0007,0xffff,0x0000,0x0001,0xffff,0xffff,0xe000,
X0x0003,0xffe0,0x0000,0x0000,0x3fff,0xffff,0xc000,
X0x0001,0xe000,0x0000,0x0000,0x1fff,0xffff,0x8000,
X0x0000,0x0000,0x0000,0x0000,0x01ff,0xfff8,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x00ff,0xfff0,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x000f,0xfde0,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0c00,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x0007,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x000f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x0000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x000f,0xc000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x000f,0xc000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0x8000,0x0000,0x0000,0x0000,0x0000,
X0x0000,0x001f,0xc000,0x0000,0x0000,0x0000,0x0000,
X0x07df,0x701f,0xc000,0x0000,0x0000,0x0000,0x0000,
X0x0fe7,0xffff,0xe000,0x0000,0x0000,0x0000,0x0000,
X0x1fff,0xffff,0xf000,0x0000,0x0000,0x0000,0x0000,
X0x1fff,0xffff,0xf000,0x0000,0x0000,0x0000,0x0000,
X0x1fff,0xffff,0xf800,0x0000,0x0000,0x0000,0x0000,
X0x0fff,0xffff,0xf800,0x0000,0x0000,0x0000,0x0000,
X0x061f,0xffff,0xfc00,0x00ee,0x77f5,0xc000,0x0000,
X0x01ff,0x7f7f,0xff0f,0xf7ff,0xffff,0xf000,0x0000,
X0x03ff,0xff3f,0xfeff,0xffff,0xffff,0xfe00,0x0000,
X0x07ff,0xff9f,0xfeff,0xffff,0xffff,0xfe00,0x0000,
X0x07ff,0xffe7,0xffff,0xffff,0xffff,0xfff0,0x0000,
X0x07ff,0xdff1,0xff7f,0xffff,0xffff,0xfffe,0x0000,
X0x03f3,0xffdd,0xffff,0xffff,0xffff,0xfffe,0x0000,
X0x01a7,0xff9f,0xff7f,0xffff,0xffff,0xffff,0x0000,
X0x007f,0xffbf,0xffff,0xffff,0xffff,0xffff,0x8000,
X0x00ff,0xffff,0xffff,0xffff,0xffff,0xffff,0x8000,
X0x00ff,0xc7ff,0xffff,0xffff,0xffff,0xffff,0xc000,
X0x00ff,0x7fff,0xff07,0xffff,0xffff,0xffff,0x8000,
X0x007c,0xffff,0xfe00,0x3bff,0xffff,0xffff,0xc000,
X0x003f,0xffff,0xfc00,0x003f,0xffff,0xffff,0xe000,
X0x0007,0xffff,0x8000,0x0003,0xffff,0xffff,0xe000,
X0x0007,0xffff,0x0000,0x0001,0xffff,0xffff,0xe000,
X0x0003,0xffe0,0x0000,0x0000,0x3fff,0xffff,0xc000,
X0x0001,0xe000,0x0000,0x0000,0x1fff,0xffff,0x8000,
X0x0000,0x0000,0x0000,0x0000,0x01ff,0xfff8,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x00ff,0xfff0,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x000f,0xfde0,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0c00,0x0000,
X0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000};
END_OF_FILE
if test 10955 -ne `wc -c <'thumbup.bi'`; then
    echo shar: \"'thumbup.bi'\" unpacked with wrong size!
fi
# end of 'thumbup.bi'
fi
if test -f 'zhongwen1' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'zhongwen1'\"
else
echo shar: Extracting \"'zhongwen1'\" \(516 characters\)
sed "s/^X//" >'zhongwen1' <<'END_OF_FILE'
Xrice cracker/senbei:jian{1|-}bing{3|\/|~}
X{be} jealous:chi{1|-}cu{4|\}
Xgive up all hope|despair:jue{2|/}wang{4|\}
Xshow loving care for:guan{1|-}huai{2|/}
Xsetting sun:xi{1|-}yang{2|/}
Xdusk:huang{2|/}hun{1|-}
Xshort in duration|brief:duan{3|\/|~}zan{4|\}
Xbring to mind|recall|recollect:hui{2|/}yi{4|\}
Xeach other|one another:bi{3|\/|~}ci{3|\/|~}
Xloneliness:gu{1|-}ji{4|\}
X{to} remain:liu{2|/}xia{4|\}
Xas if|seem to:fang{3|\/|~}fu{2|/}
Xput up with|tolerate:rong{2|/}ren{3|\/|~}
X{promise to}undertake:cheng{2|/}nuo{4|\}
X
END_OF_FILE
if test 516 -ne `wc -c <'zhongwen1'`; then
    echo shar: \"'zhongwen1'\" unpacked with wrong size!
fi
# end of 'zhongwen1'
fi
if test -f 'zhongwen1.sc' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'zhongwen1.sc'\"
else
echo shar: Extracting \"'zhongwen1.sc'\" \(23 characters\)
sed "s/^X//" >'zhongwen1.sc' <<'END_OF_FILE'
X13 3 8 2 
X12 2 8 
X
X5 
X
END_OF_FILE
if test 23 -ne `wc -c <'zhongwen1.sc'`; then
    echo shar: \"'zhongwen1.sc'\" unpacked with wrong size!
fi
# end of 'zhongwen1.sc'
fi
echo shar: End of archive 1 \(of 2\).
cp /dev/null ark1isdone
MISSING=""
for I in 1 2 ; do
    if test ! -f ark${I}isdone ; then
	MISSING="${MISSING} ${I}"
    fi
done
if test "${MISSING}" = "" ; then
    echo You have unpacked both archives.
    rm -f ark[1-9]isdone
else
    echo You still need to unpack the following archives:
    echo "        " ${MISSING}
fi
##  End of shell archive.
exit 0
-- 
Mail submissions (sources or binaries) to <amiga@uunet.uu.net>.
Mail comments to the moderator at <amiga-request@uunet.uu.net>.
Post requests for sources, and general discussion to comp.sys.amiga.misc.