home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: gnu.emacs.help
- Path: sparky!uunet!elroy.jpl.nasa.gov!sdd.hp.com!spool.mu.edu!umn.edu!news
- From: goepping@msi-s23.msi.umn.edu (Jason Goeppinger [Math])
- Subject: Re: lpr-buffer
- In-Reply-To: alexeev@math.utah.edu's message of 12 Sep 92 16:47:01
- Message-ID: <GOEPPING.92Sep14150137@msi-s23.msi.umn.edu>
- Sender: news@news2.cis.umn.edu (Usenet News Administration)
- Nntp-Posting-Host: s23.msi.umn.edu
- Organization: MSI
- References: <ALEXEEV.92Sep12164701@solitude.math.utah.edu>
- Distribution: gnu
- Date: Mon, 14 Sep 1992 21:01:37 GMT
- Lines: 34
-
- In article <ALEXEEV.92Sep12164701@solitude.math.utah.edu> alexeev@math.utah.edu (Valery A. Alexeev) writes:
-
- This might be a very simple question but I couldn't figure it myself
- whatever I tried it was wrong.
- I cannot print anything from within emacs using M-x lpr-buffer or M-x
- lpr-region. Reason: when I normally print text files, I have to
- convert them to Postscript first, so I type something like
-
- lptops -backwards | lpr -Pjwb120 file.txt
-
- So I tried to change lpr-command in lpr.el from "lpr" to
- "lptops -backwards | lpr" and lpr-switches to "-Pjwb120", well it
- does't know the program "lptops -backwards | lpr", so it won't work.
-
- Would some kind soul point me the solution ?
-
- A hack I would use would be to write a script that you could save as an
- executable in your path (assuming you're using Un*x. . .) like
-
- #!/bin/csh -f
-
- lptops -backwards | lpr -Pjwb120 $argv
-
-
- And save it with a name like mylpr in a directory found in your 'path'
- shell variable. (Dont forget to change the execute permission: chmod u+x
- mylpr). Then you can use the command you've written whenever you need to
- print and you can use it as the lpr-command. Perhaps someone has a better
- solution, but I think this one will do the trick.
-
- --
-
- Jason Goeppinger
- (goepping@s1.msi.umn.edu)
-