lp 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187
  1. .TH LP 1
  2. .SH NAME
  3. lp \- printer output
  4. .SH SYNOPSIS
  5. .B lp
  6. [
  7. .I option ...
  8. ]
  9. [
  10. .I file ...
  11. ]
  12. .SH DESCRIPTION
  13. .I Lp
  14. is a generalized output printing service.
  15. It can be used to queue files for printing,
  16. check a queue, or kill jobs in a queue.
  17. The options are:
  18. .TF -p\ \fIproc\fP
  19. .TP
  20. .BI -d " dest"
  21. Select the destination printer.
  22. If
  23. .I dest
  24. is
  25. .LR ? ,
  26. list the currently available printers.
  27. In the absence of
  28. .LR -d ,
  29. the destination is taken from the environment variable
  30. .BR LPDEST .
  31. Destination
  32. .L stdout
  33. is the standard output.
  34. Destination
  35. .L safari
  36. is
  37. .L /dev/lpt1data
  38. line printer port on a 386 machine, assumed
  39. to be connected to a PostScript printer.
  40. Destinations
  41. .L hpdeskjet
  42. and
  43. .L bjc240l
  44. are also
  45. .L /dev/lpt1data
  46. but assumed to be connected to an HP Deskjet 670 or
  47. Canon BJC-240.
  48. .I Lp
  49. can print to any printer supported by
  50. Ghostscript using syntax
  51. .BI gs!device
  52. where
  53. .I device
  54. is a Ghostscript output device.
  55. See
  56. .IR gs (1)
  57. and the
  58. .L canonbjc240l
  59. entry in
  60. .LR /sys/lib/lp/devices .
  61. .TP
  62. .B -k
  63. Kill the job(s) given as subsequent arguments instead of file names
  64. for the given destination.
  65. .TP
  66. .BI -p " proc"
  67. The given processor is invoked.
  68. The default processor is
  69. .LR generic ,
  70. which tries to do the right thing for regular text,
  71. .IR troff (1)
  72. output, or
  73. .IR tex (1)
  74. output.
  75. If no processing is desired
  76. .L noproc
  77. may be specified.
  78. .TP
  79. .B -q
  80. Print the queue for the given destination.
  81. For some devices, include printer status.
  82. .TP
  83. .B -R
  84. Stops and restarts the printer daemon.
  85. If the printer is wedged, it is often useful to cycle the power on the printer
  86. before running this command.
  87. .PD
  88. .PP
  89. The remaining options may be used to affect the output at a given device.
  90. These options may not be applicable to all devices.
  91. .TF "-p\ \fIproc\fP"
  92. .TP
  93. .BI -c " n"
  94. Print
  95. .I n
  96. copies.
  97. .TP
  98. .BI -f " font"
  99. Set the font (default
  100. .LR CW.11 ).
  101. .TP
  102. .BI -H
  103. Suppress printing of header page.
  104. .TP
  105. .BI -i " n"
  106. Select paper input tray.
  107. .I n
  108. may be a number 0-9, the word
  109. .I man
  110. for the manual feed slot, and/or
  111. .I simplex
  112. or
  113. .I duplex
  114. to get single or double sided output.
  115. Multiple input tray options may be specified if they are
  116. separated by commas.
  117. .TP
  118. .BI -l " n"
  119. Set the number of lines per page to
  120. .IR n .
  121. .TP
  122. .B -L
  123. Print pages in landscape mode (i.e. turned 90 degrees).
  124. .TP
  125. .BI -m " v"
  126. Set magnification to
  127. .IR v .
  128. .TP
  129. .BI -n " n"
  130. Print
  131. .I n
  132. logical pages per physical page.
  133. .TP
  134. .BI -o " list"
  135. Print only pages whose page numbers appear in
  136. the comma-separated
  137. .I list
  138. of numbers and ranges.
  139. A range
  140. .IB n - m
  141. means pages
  142. .I n
  143. through
  144. .IR m ;
  145. a range
  146. .BI - n
  147. means from the beginning to page
  148. .IR n ;
  149. a range
  150. .IB n -
  151. means from page
  152. .I n
  153. to the end.
  154. .TP
  155. .B -r
  156. Reverse the order of page printing.
  157. .TP
  158. .BI -x " v"
  159. Set the horizontal
  160. offset of the print image, measured in inches.
  161. .TP
  162. .BI -y " v"
  163. Set the vertical
  164. offset of the print image, measured in inches.
  165. .SH EXAMPLES
  166. .TP 0
  167. .L
  168. eqn paper | troff -ms | lp -dsafari
  169. Typeset and print a paper containing equations.
  170. .TP
  171. .L
  172. pr -l100 file | lp -l100 -fCW.8
  173. Print a file in a small font at 100 lines per page.
  174. .TP
  175. .L
  176. lp -dstdout /dev/windows/3/window > doc.ps
  177. Convert an image to a postscript file.
  178. .SH SOURCE
  179. .B /rc/bin/lp
  180. .SH SEE ALSO
  181. .IR lp (8)
  182. .br
  183. P. Glick,
  184. ``A Guide to the Lp Printer Spooler''.
  185. .SH BUGS
  186. Not all options work with all output devices.
  187. Any user can kill any job.