From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: "Eli Zaretskii" Newsgroups: gmane.emacs.help Subject: Re: Adjusting page length in "Print buffer" command Date: Sat, 15 Jan 2005 18:59:49 +0200 Message-ID: <01c4fb23$Blat.v2.2.2$c52cef20@zahav.net.il> References: <85oefrhmt0.fsf@obelix.seki.fr> NNTP-Posting-Host: deer.gmane.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7BIT X-Trace: sea.gmane.org 1105808960 4819 80.91.229.6 (15 Jan 2005 17:09:20 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sat, 15 Jan 2005 17:09:20 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat Jan 15 18:09:13 2005 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1CprQG-0007ag-00 for ; Sat, 15 Jan 2005 18:09:12 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Cprc1-0002Xp-UZ for geh-help-gnu-emacs@m.gmane.org; Sat, 15 Jan 2005 12:21:21 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Cprb4-0002Eh-4A for help-gnu-emacs@gnu.org; Sat, 15 Jan 2005 12:20:22 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Cprau-0002AM-Pd for help-gnu-emacs@gnu.org; Sat, 15 Jan 2005 12:20:14 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Cprau-000290-IW for help-gnu-emacs@gnu.org; Sat, 15 Jan 2005 12:20:12 -0500 Original-Received: from [192.114.186.24] (helo=legolas.inter.net.il) by monty-python.gnu.org with esmtp (Exim 4.34) id 1CprK0-0000A3-5o for help-gnu-emacs@gnu.org; Sat, 15 Jan 2005 12:02:44 -0500 Original-Received: from zaretski (tony04-52-44.inter.net.il [80.230.52.44]) by legolas.inter.net.il (MOS 3.5.6-GR) with ESMTP id DNR45254 (AUTH halo1); Sat, 15 Jan 2005 19:02:40 +0200 (IST) Original-To: help-gnu-emacs@gnu.org X-Mailer: emacs 21.3.50 (via feedmail 8 I) and Blat ver 2.2.2 In-reply-to: (message from Tim McNamara on Sat, 15 Jan 2005 09:57:29 -0600) 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: main.gmane.org gmane.emacs.help:23366 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:23366 > From: Tim McNamara > Date: Sat, 15 Jan 2005 09:57:29 -0600 > > > Please see if any of the options mentioned in the doc string of > > print-buffer help you get what you want: > > > > print-buffer is an interactive autoloaded Lisp function in > > `lpr'. It is bound to . > > (print-buffer) > > > > Paginate and print buffer contents. > > > > The variable `lpr-headers-switches' controls how to paginate. > > If it is nil (the default), we run the `pr' program (or whatever > > program `lpr-page-header-program' specifies) to paginate. > > `lpr-page-header-switches' specifies the switches for that > > program. > > > > Otherwise, the switches in `lpr-headers-switches' are used in > > the print command itself; we expect them to request pagination. > > > > See the variables `lpr-switches' and `lpr-command' for further > > customization of the printer command. > > I couldn't find this in Info, obviously looking in the wrong places. > Where is it? As I said, it's in the doc string of the print-buffer command. Type "C-h f print-buffer RET", and you will see it. In Emacs, every function and every variable have their documentation that is built right into Emacs. > So, I should be able to modify "lpr-headers-switches" to request a > different pagination, from what your post suggests- in effect, to call > "pr -l _lines_" when "print-buffer" is called? Yes. > Counting lines on the > printed pages, it looks like I need to modify the pagination to a > total of 50 or 51 lines. Can I modify "lpr-headers-switches" to do > this? Is this done directly by modifying the command or is this done > in my .emacs? The latter. > Is there a way to do this simply via "Customize Emacs" that I have > overlooked? Thru "Customize Emacs" should be possible. Did it fail for you? Another, a bit shorter, way is by "M-x customize-variable RET". Type "lpr-headers-switches" at the prompt, and then modify the value in the Custom buffer and use the displayed buttons to save it for this and future sessions.