xlator_call(8)
Name
xlator_call − shell script to invoke PostScript (TM) translators
Syntax
xlator_call datatype orientation pagesize width length indent
Description
This Bourne shell script can be called by the lpd line printer daemon to invoke the appropriate translator to convert each data type to PostScript (TM). The data type passed by lpd may be specified by using the lpr command with the −Ddatatype option, or by using the Da=datatype capability in the printcap file.
For a file in a data syntax to be translated to PostScript (TM), the xlator_call script must contain a case branch which recognises the data type string and calls a suitable filter. The supplied xlator_call recognises the ANSI, ASCII, Regis and Tektronix 4014 data types. An example shell script is shown below:
case $datatype in
ansi)
exec ansi_ps -F $pagesize -O $orientation -e "$@";;
ascii)
echo "(\004) cvn {} def"
exec ln03rof -w$width -l$length -i$indent;;
postscript)
exec cat;;
tek4014)
exec tek4014_ps -F $pagesize -O $orientation;;
regis)
exec regis_ps -F $pagesize -O $orientation;;
*)
echo "$0: Translator for data type $datatype not installed" >&2
esac
When the shell script is called, the path searched is:
/usr/local/lib/lpdfilters:/usr/ucb:/bin:/usr/bin:
/usr/lib:/usr/lib/lpdfilters
Arguments
datatype
The valid data types are: ansi, ascii, postscript, regis, tek4014 or any other for which a translator has been installed.
orientation
The valid orientations are: portrait or landscape.
pagesize
The valid page sizes are: letter, a, ledger, b, legal, executive, a5, a4, a3, b5 or b4.
width
The width (in characters) of the page.
length
The length (in lines) of the page.
indent
The amount (in spaces) the output is to be indented.
All the valid arguments are described in detail by the lpr(1) reference page.
Files
/usr/lib/lpdfilters/xlator_call The xlator_call script