From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Joe Fineman Newsgroups: gmane.emacs.help Subject: Re: Printing with emacs: Not working Date: Fri, 27 Feb 2009 20:24:21 -0500 Organization: A noiseless patient Spider Message-ID: References: <8dcb3b6f-ddbb-412a-a051-dd1624d960b2@r15g2000prh.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1235785250 26240 80.91.229.12 (28 Feb 2009 01:40:50 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 28 Feb 2009 01:40:50 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat Feb 28 02:42:07 2009 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1LdEDO-0004cD-K8 for geh-help-gnu-emacs@m.gmane.org; Sat, 28 Feb 2009 02:42:06 +0100 Original-Received: from localhost ([127.0.0.1]:55602 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LdEC3-0006XW-PL for geh-help-gnu-emacs@m.gmane.org; Fri, 27 Feb 2009 20:40:43 -0500 Original-Path: news.stanford.edu!headwall.stanford.edu!newsfeed.news2me.com!newsfeed.icl.net!newsfeed.fjserv.net!oleane.net!oleane!news.ecp.fr!news.motzarella.org!motzarella.org!news.motzarella.org!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 69 Original-X-Trace: news.eternal-september.org U2FsdGVkX1/a0cfxcTObrleL8gOGBF1W96e1FIAihWe+RyIxYb2mS/QSqYjtOSvq0887ePJeUAUxlBpW8YfqCe5sRvDWLG6C/tpN9OJSEiYbFvVSiBP06SlKss4YL9QoUeYV5sf7tJk= Original-X-Complaints-To: Please send complaints to abuse@motzarella.org with full headers Original-NNTP-Posting-Date: Sat, 28 Feb 2009 01:24:49 +0000 (UTC) X-Auth-Sender: U2FsdGVkX19v/sILx143y+WfK2HXXg382gaPngaoPm4= Cancel-Lock: sha1:vlfUmMA5X3V1IlQjjox8EgvsvqQ= sha1:t4dNbUjh9+1hIFF2+rdywpvI8+c= User-Agent: Gnus/5.101 (Gnus v5.10.10) Emacs/22.3 (windows-nt) Original-Xref: news.stanford.edu gnu.emacs.help:167164 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:62465 Archived-At: DaveLG526 writes: > I have been using emacs for about a month and really like it. It > wasn't till today that I tried to print something. I see this > message but nothig i sever printed: Spooling with options (page > headers are not supported)...done. I Am Not A Programmer. I have gotten so consistently frustrated trying to make lpr-buffer, lpr-region, tex-buffer, & tex-print work that I have resorted to the following workarounds: (defun lprl (r/b) "Print all or part of buffer with TeX literal mode." (interactive "cr(egion) or b(uffer)?") (save-window-excursion (let ((passage (if (equal r/b ?r) (buffer-substring (region-beginning) (region-end)) (buffer-substring (point-min) (point-max))))) (find-file "/usr/own/f/hdwe/printer/hp/Lpr-scratch.tex") (delete-region (point-min) (point-max)) (insert-file "~/tex/Tex-literal-hdr") (goto-char (point-max)) (insert passage) (goto-char (point-max)) (insert-file "~/tex/Tex-literal-ftr") (untabify (point-min) (point-max)) (goto-char (point-min)) (replace-regexp "\e.\\|\C-r" "") (save-buffer) (shell-command "latex /usr/own/f/hdwe/printer/hp/Lpr-scratch.tex") ;Doesn't understand tilde (shell-command "dvips -f /usr/own/f/hdwe/printer/hp/Lpr-scratch.dvi | gsprint - color - ") ))) ---------------------------------------------------------------------- Tex-literal-hdr: \documentclass[12pt]{article} \pagestyle{empty} \setlength{\oddsidemargin}{-.25in} \setlength{\topmargin}{-.75in} \setlength{\textheight}{9.5in} \setlength{\textwidth}{7in} ---------------------------------------------------------------------- Tex-literal-ftr: \end{verbatim} \end{document} ---------------------------------------------------------------------- \begin{document} \setlength{\baselineskip}{.1667in} \noindent \begin{verbatim} (defun lprt () "Print the TeX file in the current buffer." (interactive) (save-window-excursion (let ((file (buffer-string))) (find-file "~/hdwe/printer/hp/Lpr-scratch.tex") (delete-region (point-min) (point-max)) (insert file)) (save-buffer) (shell-command "latex /usr/own/f/hdwe/printer/hp/Lpr-scratch.tex") ;Doesn't understand tilde (shell-command "dvips -f /usr/own/f/hdwe/printer/hp/Lpr-scratch.dvi | gsprint - color - ") )) -- --- Joe Fineman joe_f@verizon.net ||: First you go to hell, then your body rots, and then you die. :||