Compuprint 914 Especificações Página 142

  • Descarregar
  • Adicionar aos meus manuais
  • Imprimir
  • Página
    / 374
  • Índice
  • MARCADORES
  • Avaliado. / 5. Com base em avaliações de clientes
Vista de página 141
4-28
Guide to Printers and Printing
lineout(fileptr) /*** Format a Line ***/
FILE *fileptr;
{
int ch, charcount = 0;
for (ch = 0; ch < Indent; ch++)
pioputchar(’ ’);
while ((ch=piogetc(fileptr)) != ’\n’ && ch != EOF
&& charcount < Pgwidth) {
charcount++;
pioputchar(c);
}
vpos += Vincr;
return(charcount);
}
passthru() /*** Pass–through Option ***/
{
int ch;
while ((ch = piogetc(stdin)) != EOF)
pioputchar(ch);
if (piodatasent && Do_formfeed)
(void) piocmdout(FF_CMD, NULL, 0, NULL);
return(0);
}
restore() /*** Restore the Printer ***/
{
if (Restoreprinter)
(void) piocmdout(REST_CMD, NULL, 0, NULL);
return(0);
}
Compile and Link the Print Formatter
Use an editor to create an imports file named sample.imp. The file should contain the
following:
#!
main
piogetvals
piogetopt
piomsgout
pioexit
piomode
piodatasent
piopgskip
statusfile
piocmdout
piogetstr
Use an editor to create an exports file named sample.exp. The file should contain the
following:
#!
setup
initialize
passthru
restore
lineout
Enter the following to compile and link the formatter:
cc –o sample –bI:sample.imp –bE:sample.exp sample.c
Vista de página 141
1 2 ... 137 138 139 140 141 142 143 144 145 146 147 ... 373 374

Comentários a estes Manuais

Sem comentários