Examples
- To transform the ditroff file
myfileinto an AFP data stream file calledmyfile.afp, enter:d2afp myfile -o myfile.afp
- To create an AFP data stream output file from the troff file
doc.trfand print the output file using the InfoPrint logical printerservC-lp, enter:troff -Tafp doc.trf | d2afp | pdpr -p servC-lp
In this example, the
troffcommand searches the/usr/lib/font/devafpdirectory for the troff font and printer description files. The d2afp command also uses files in this directory.In the preceding example, the d2afp transform runs on the local system whether the printer,
servC-lpis a local or remote printer.Note: You could also use this command to perform the same function:troff -Tafp doc.trf | pdpr -p servC-lp -odatatype=ditroff
In this case, if the printer,
servC-lp, is local, the d2afp transform runs on the local system; however, if the printer is remote, the d2afp transform runs on the remote system. - To print the ditroff file
reporton an InfoPrint printer namedservD-lp, enter:pdpr -X ditroff.X report
In this example, the attributes file namedditroff.Xcontains these settings:document-format=ditroff printer-name-requested=servD-lp