home *** CD-ROM | disk | FTP | other *** search
- /*
- * output.c
- * Part of the !Virtual distribution
- * (c) bdb/nas/fo, 1992-3
- */
-
- #include "swis.h"
- #include "swiv.h"
- #include "wimp.h"
-
- #include "virtual.h"
- #include "lib.h"
- #include "output.h"
- #include "asm.h"
- #include "pager.h"
-
- void printflush(WKSP *w)
- { int *block=w->outblock;
- if (!w->outcount)
- return;
- block[5]=w->outcount;
- block[0]=(w->outcount|3)+25;
- block[3]=0;
- block[4]=0x808c1; /* 0x804c0; */
- swi(Wimp_SendMessage, IN(R0|R1|R2), 17, block, w->outtask );
- w->outcount=0;
- }
-
- void printc( WKSP *w, int c )
- {
- w->outbuf[w->outcount++]=c;
- if (w->outcount>=OUTMAX-2)
- printflush(w);
- }
-
- void outc(WKSP *w, int c )
- {
- w->outbuf[w->outcount++]=c;
- if (w->outcount>=OUTMAX-2)
- { Normal(w);
- printflush(w);
- FindPages(w);
- Virtual(w);
- }
- }
-