Article View: gnu.emacs.help
Article #189592Re: Print-buffer under VMS?
From: Marc Nozell
Date: Wed, 02 Jan 1991 16:19
Date: Wed, 02 Jan 1991 16:19
56 lines
2613 bytes
2613 bytes
In article <1990Dec31.101727.1@nerus.pfc.mit.edu>, mrl@nerus.pfc.mit.edu writes...
>Is it possible to use the print-buffer command under VMS? Presently, it
>tries to use the LPR.EL procedure which is for UNIX. Is there an equivalent
>LPR.EL for VMS? Thanks.
> Mark
I use the following to make print-buffer and print-region work.
Change VMS-print-command to suit your tastes.
-marc
(load-library "lpr")
(defvar VMS-print-command
"print/delete/para=(lay=lps$singleholes)/queue=$printer_1 "
"*Command used to print on VMS. The /delete qualifier is important.")
(defun print-region-1 (start end switches)
"Nozell's print region 1"
(let ((name (concat (buffer-name) " Emacs buffer"))
(width tab-width))
(save-excursion
(message "Spooling...")
(if (/= tab-width 8)
(let ((oldbuf (current-buffer)))
(set-buffer (get-buffer-create " *spool temp*"))
(widen)
(erase-buffer)
(insert-buffer-substring oldbuf start end)
(setq tab-width width)
(untabify (point-min) (point-max))
(setq start (point-min) end (point-max))))
(setq nozbuf (get-buffer-create "*print file*"))
(copy-to-buffer "*print file*" start end)
(set-buffer nozbuf)
(write-file "sys$login:delete-me.txt")
(send-command-to-subprocess 1
(concat VMS-print-command " sys$login:delete-me.txt/name=""GNUprintbuffer""")
)
(message (concat "Spooling " (buffer-file-name) "..."))
(kill-buffer "delete-me.txt")
(message "Spooling...done"))))
---
Marc Nozell nozell@star.enet.dec.com
VMS Development nozell%star.enet.dec@decwrl.dec.com
System Management Engineering Group decwrl!star.enet.dec.com!nozell
Digital Equipment Corp 42 49 N / 71 31 W
110 Spit Brook Road ZK03-2/Y05, Nashua NH 03063
The views expressed are my own.
Technical Details
Message-ID:
<18607@shlump.nac.dec.com>Path:
arc1-ca.pugleaf.net!gmdzi!unido!mcsun!uunet!spool2.mu.edu!sdd.hp.com!zaphod.mps.ohio-state.edu!swrinde!ucsd!ucbvax!bloom-beacon!deccrl!news.crl.dec.com!pa.dec.com!rust.zso.dec.com!shlump.nac.dec.com!star.enet.dec.com!nozellShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103b8b,bccff6eeeb9b754 X-Google-Attributes: gid103b8b,public X-Google-ArrivalTime: 1991-01-02 13:00:28 PST Path: arc1-ca.pugleaf.net!gmdzi!unido!mcsun!uunet!spool2.mu.edu!sdd.hp.com!zaphod.mps.ohio-state.edu!swrinde!ucsd!ucbvax!bloom-beacon!deccrl!news.crl.dec.com!pa.dec.com!rust.zso.dec.com!shlump.nac.dec.com!star.enet.dec.com!nozell From: nozell@star.enet.dec.com (Marc Nozell) Newsgroups: gnu.emacs.help Subject: Re: Print-buffer under VMS? Keywords: VMS, print-buffer, print-region Message-ID: <18607@shlump.nac.dec.com> Date: 2 Jan 91 16:19:02 GMT Sender: newsdaemon@shlump.nac.dec.com Organization: Digital Equipment Corporation Lines: 56 Posted: Wed Jan 2 10:19:02 1991