meta data for this page
  •  

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
common:printing_guide [2009/02/24 16:22]
laakkone
common:printing_guide [2009/09/28 13:30]
paalanen A3 on old xerox
Line 3: Line 3:
 =====  Printers and PPD files  ===== =====  Printers and PPD files  =====
  
-;Xerox printer at 6531: http://​mediaserver.it.lut.fi/​media/​linux/​Xrn4025p.ppd +**The old Xerox printer at 6531 (not the copier)** --- {{:common:files:​xrn4025p.ppd.zip}} 
-;[[http://​157.24.24.16|HP Color Laser]] outside 6505: http://​mediaserver.it.lut.fi/​media/​linux/​hpcolor.ppd+  * setting A3 paper size: ''​lpoptions -p xerox6531 -o PageRegion=A3 -o InputSlot=Tray2''​ 
 + 
 +**[[http://​157.24.24.16|HP Color Laser]] outside 6505** --- {{:common:​files:​hpcolor.ppd.zip}}
  
 =====  Installing with CUPS  ===== =====  Installing with CUPS  =====
Line 15: Line 17:
 Go get the PPD file and save it somewhere: Go get the PPD file and save it somewhere:
  
-http://​mediaserver.it.lut.fi/​media/​linux/​Xrn4025p.ppd+{{:common:​files:​xrn4025p.ppd.zip}}
  
-Install ​the printer with command:+Unpack zip file and install ​the printer with command:
  
-<​code>​ lpadmin -p xerox6531 -v socket://​157.24.24.70:​9100/​ -D "the old xerox" -L "mail room 6531" -P <​nowiki>​Xrn4025p.ppd</​nowiki>​</​code>​+<​code>​ lpadmin -p xerox6531 -v socket://​157.24.24.70:​9100/​ -D "the old xerox" -L "mail room 6531" -P Xrn4025p.ppd</​code>​
  
 You can check your available printers as a user with: You can check your available printers as a user with:
  
- lpstat -t+  ​lpstat -t
  
 If it says your new printer is rejecting jobs and/or disabled, the following commands If it says your new printer is rejecting jobs and/or disabled, the following commands
 should be of help (as root): should be of help (as root):
  
- /​usr/​bin/​enable xerox6531 +  ​/​usr/​bin/​enable xerox6531 
- ​accept xerox6531+  accept xerox6531
  
 The ''​enable''​ command is with full path because ''​enable''​ is also a Bash builtin The ''​enable''​ command is with full path because ''​enable''​ is also a Bash builtin
Line 35: Line 37:
  
 To see what kind of options your new printer may offer, try: To see what kind of options your new printer may offer, try:
- lpoptions -p xerox6531 -l+  ​lpoptions -p xerox6531 -l
  
 =====  Two pages on one  ===== =====  Two pages on one  =====
Line 41: Line 43:
 Find and install package ''​psutils''​ to get ''​psnup''​. Find and install package ''​psutils''​ to get ''​psnup''​.
  
- psnup -2 docu.ps new_docu.ps+  ​psnup -2 docu.ps new_docu.ps
  
 =====  Duplex printing ​ ===== =====  Duplex printing ​ =====
Line 47: Line 49:
 At least the Xerox in the mail room can print duplex. At least the Xerox in the mail room can print duplex.
 For the "​normal"​ way: For the "​normal"​ way:
- lpr -Pxerox6531 -o sides=two-sided-long-edge file.ps+  ​lpr -Pxerox6531 -o sides=two-sided-long-edge file.ps
 For the other way: For the other way:
- lpr -Pxerox6531 -o sides=two-sided-short-edge file.ps+  ​lpr -Pxerox6531 -o sides=two-sided-short-edge file.ps
  
 NOTE: It has been noticed that some Postscript files refuse to print NOTE: It has been noticed that some Postscript files refuse to print
Line 62: Line 64:
 Open the PDF in Acrobat reader and print the wanted pages into a Postscript file. Open the PDF in Acrobat reader and print the wanted pages into a Postscript file.
 The file will likely "​compress"​ if you run it through ''​ps2ps''>​ The file will likely "​compress"​ if you run it through ''​ps2ps''>​
- ps2ps file.ps file2.ps+  ​ps2ps file.ps file2.ps
  
 Then, reorganize the pages to form a book: Then, reorganize the pages to form a book:
- psbook -q file2.ps file3.ps+  ​psbook -q file2.ps file3.ps
  
 Let's put two pages on one sheet, that is, make an A5 book: Let's put two pages on one sheet, that is, make an A5 book:
- psnup -2 file3.ps file4.ps+  ​psnup -2 file3.ps file4.ps
  
 Print the file in duplex: Print the file in duplex:
- lpr -Pxerox6531 -o sides=two-sided-short-edge file4.ps+  ​lpr -Pxerox6531 -o sides=two-sided-short-edge file4.ps
  
 =====  Prettyprinting code files  ===== =====  Prettyprinting code files  =====
Line 79: Line 81:
 <​code>​ <​code>​
 function m2ps { function m2ps {
-        while [[|"​$1" ​]]; do+        while [ "​$1"​ ]; do
                 enscript --ps-level=1 -r --word-wrap -2 -C -G -j "​$1"​ -o "​$1.ps"​                 enscript --ps-level=1 -r --word-wrap -2 -C -G -j "​$1"​ -o "​$1.ps"​
                 shift                 shift