aboutsummaryrefslogtreecommitdiffstats
path: root/lisp/printing.el
diff options
context:
space:
mode:
authorKaroly Lorentey2005-06-15 12:57:51 +0000
committerKaroly Lorentey2005-06-15 12:57:51 +0000
commitef85512e51f043d73788f00a2aed13cccde0682c (patch)
treefc1fa1378533250f260ef8eaa9a84ae882d9df84 /lisp/printing.el
parent8736257554f49445f7b4402ac7a9436b38ce6452 (diff)
parentef88a9999004e6c26148c8d280d6a41f623d7249 (diff)
downloademacs-ef85512e51f043d73788f00a2aed13cccde0682c.tar.gz
emacs-ef85512e51f043d73788f00a2aed13cccde0682c.zip
Merged from miles@gnu.org--gnu-2005 (patch 80-82, 350-422)
Patches applied: * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-350 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-351 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-352 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-353 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-354 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-355 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-356 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-357 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-358 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-359 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-360 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-361 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-362 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-363 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-364 Remove "-face" suffix from widget faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-365 Remove "-face" suffix from custom faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-366 Remove "-face" suffix from change-log faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-367 Remove "-face" suffix from compilation faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-368 Remove "-face" suffix from diff-mode faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-369 lisp/longlines.el (longlines-visible-face): Face removed * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-370 Remove "-face" suffix from woman faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-371 Remove "-face" suffix from whitespace-highlight face * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-372 Remove "-face" suffix from ruler-mode faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-373 Remove "-face" suffix from show-paren faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-374 Remove "-face" suffix from log-view faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-375 Remove "-face" suffix from smerge faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-376 Remove "-face" suffix from show-tabs faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-377 Remove "-face" suffix from highlight-changes faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-378 Remove "-face" suffix from and downcase info faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-379 Remove "-face" suffix from pcvs faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-380 Update uses of renamed pcvs faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-381 Tweak ChangeLog * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-382 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-383 Remove "-face" suffix from strokes-char face * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-384 Remove "-face" suffix from compare-windows face * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-385 Remove "-face" suffix from calendar faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-386 Remove "-face" suffix from diary-button face * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-387 Remove "-face" suffix from testcover faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-388 Remove "-face" suffix from viper faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-389 Remove "-face" suffix from org faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-390 Remove "-face" suffix from sgml-namespace face * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-391 Remove "-face" suffix from table-cell face * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-392 Remove "-face" suffix from tex-mode faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-393 Remove "-face" suffix from texinfo-heading face * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-394 Remove "-face" suffix from flyspell faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-395 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-396 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-397 Remove "-face" suffix from gomoku faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-398 Remove "-face" suffix from mpuz faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-399 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-400 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-401 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-402 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-403 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-404 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-405 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-406 Merge from gnus--rel--5.10 * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-407 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-408 Remove "-face" suffix from Buffer-menu-buffer face * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-409 Remove "-face" suffix from antlr-mode faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-410 Remove "-face" suffix from ebrowse faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-411 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-412 Remove "-face" suffix from flymake faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-413 Remove "-face" suffix from idlwave faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-414 Remove "-face" suffix from sh-script faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-415 Remove "-face" suffix from vhdl-mode faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-416 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-417 Remove "-face" suffix from which-func face * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-418 Remove "-face" suffix from cperl-mode faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-419 Remove "-face" suffix from ld-script faces * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-420 Fix cperl-mode font-lock problem * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-421 Tweak which-func face * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-422 Update from CVS * miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-80 Merge from emacs--cvs-trunk--0 * miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-81 Update from CVS * miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-82 Update from CVS git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-350
Diffstat (limited to 'lisp/printing.el')
-rw-r--r--lisp/printing.el363
1 files changed, 302 insertions, 61 deletions
diff --git a/lisp/printing.el b/lisp/printing.el
index ddfe6fd5cc0..868ea3fddf3 100644
--- a/lisp/printing.el
+++ b/lisp/printing.el
@@ -1,17 +1,17 @@
1;;; printing.el --- printing utilities 1;;; printing.el --- printing utilities
2 2
3;; Copyright (C) 2000, 2001, 2002, 2003, 2004 3;; Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005
4;; Free Software Foundation, Inc. 4;; Free Software Foundation, Inc.
5 5
6;; Author: Vinicius Jose Latorre <viniciusjl@ig.com.br> 6;; Author: Vinicius Jose Latorre <viniciusjl@ig.com.br>
7;; Maintainer: Vinicius Jose Latorre <viniciusjl@ig.com.br> 7;; Maintainer: Vinicius Jose Latorre <viniciusjl@ig.com.br>
8;; Time-stamp: <2004/11/21 20:56:53 vinicius> 8;; Time-stamp: <2005/06/11 19:51:32 vinicius>
9;; Keywords: wp, print, PostScript 9;; Keywords: wp, print, PostScript
10;; Version: 6.8.3 10;; Version: 6.8.4
11;; X-URL: http://www.cpqd.com.br/~vinicius/emacs/ 11;; X-URL: http://www.cpqd.com.br/~vinicius/emacs/
12 12
13(defconst pr-version "6.8.3" 13(defconst pr-version "6.8.4"
14 "printing.el, v 6.8.3 <2004/11/17 vinicius> 14 "printing.el, v 6.8.4 <2005/06/11 vinicius>
15 15
16Please send all bug fixes and enhancements to 16Please send all bug fixes and enhancements to
17 Vinicius Jose Latorre <viniciusjl@ig.com.br> 17 Vinicius Jose Latorre <viniciusjl@ig.com.br>
@@ -143,7 +143,7 @@ Please send all bug fixes and enhancements to
143;; One way to set variables is by calling `pr-customize', customize all 143;; One way to set variables is by calling `pr-customize', customize all
144;; variables and save the customization by future sessions (see Options 144;; variables and save the customization by future sessions (see Options
145;; section). Other way is by coding your settings on Emacs init file (that is, 145;; section). Other way is by coding your settings on Emacs init file (that is,
146;; .emacs file), see below for a first setting template that it should be 146;; ~/.emacs file), see below for a first setting template that it should be
147;; inserted on your ~/.emacs file (or c:/_emacs, if you're using Windows 9x/NT 147;; inserted on your ~/.emacs file (or c:/_emacs, if you're using Windows 9x/NT
148;; or MS-DOS): 148;; or MS-DOS):
149;; 149;;
@@ -259,9 +259,9 @@ Please send all bug fixes and enhancements to
259;; PostScript printer. So, please, don't include this printer in 259;; PostScript printer. So, please, don't include this printer in
260;; `pr-txt-printer-alist' (which see). 260;; `pr-txt-printer-alist' (which see).
261;; 261;;
262;; 5. Use gsprint instead of ghostscript to print monochrome PostScript files 262;; 5. You can use gsprint instead of ghostscript to print monochrome PostScript
263;; in Windows. The gsprint utility is faster than ghostscript to print 263;; files in Windows. The gsprint utility documentation says that it is more
264;; monochrome PostScript. 264;; efficient than ghostscript to print monochrome PostScript.
265;; 265;;
266;; To print non-monochrome PostScript file, the efficiency of ghostscript 266;; To print non-monochrome PostScript file, the efficiency of ghostscript
267;; is similar to gsprint. 267;; is similar to gsprint.
@@ -271,6 +271,31 @@ Please send all bug fixes and enhancements to
271;; For more information about gsprint see 271;; For more information about gsprint see
272;; `http://www.cs.wisc.edu/~ghost/gsview/gsprint.htm'. 272;; `http://www.cs.wisc.edu/~ghost/gsview/gsprint.htm'.
273;; 273;;
274;; As an example of gsprint declaration:
275;;
276;; (setq pr-ps-printer-alist
277;; '((A "gsprint" ("-all" "-twoup") "-printer " "my-b/w-printer-name")
278;; (B "gsprint" ("-all" "-twoup") nil "-printer my-b/w-printer-name")
279;; ;; some other printer declaration
280;; ))
281;;
282;; The example above declares that printer A prints all pages (-all) and two
283;; pages per sheet (-twoup). The printer B declaration does the same as the
284;; printer A declaration, the only difference is the printer name selection.
285;;
286;; There are other command line options like:
287;;
288;; -mono Render in monochrome as 1bit/pixel (only black and white).
289;; -grey Render in greyscale as 8bits/pixel.
290;; -color Render in color as 24bits/pixel.
291;;
292;; The default is `-mono'. So, printer A and B in the example above are
293;; using implicitly the `-mono' option. Note that in `-mono' no gray tone
294;; or color is printed, this includes the zebra stripes, that is, in `-mono'
295;; the zebra stripes are not printed.
296;;
297;; See also documentation for `pr-ps-printer-alist'.
298;;
274;; 299;;
275;; Using `printing' 300;; Using `printing'
276;; ---------------- 301;; ----------------
@@ -279,8 +304,10 @@ Please send all bug fixes and enhancements to
279;; using Windows 9x/NT or MS-DOS): 304;; using Windows 9x/NT or MS-DOS):
280;; 305;;
281;; (require 'printing) 306;; (require 'printing)
307;; ;; ...some user settings...
308;; (pr-update-menus t)
282;; 309;;
283;; When `printing' is loaded: 310;; During `pr-update-menus' evaluation:
284;; * On Emacs 20: 311;; * On Emacs 20:
285;; it replaces the Tools/Print menu by Tools/Printing menu. 312;; it replaces the Tools/Print menu by Tools/Printing menu.
286;; * On Emacs 21: 313;; * On Emacs 21:
@@ -885,6 +912,7 @@ Please send all bug fixes and enhancements to
885;; (lps_06b "print" nil nil "\\\\printers\\lps_06b") 912;; (lps_06b "print" nil nil "\\\\printers\\lps_06b")
886;; (lps_07c "print" nil "" "/D:\\\\printers\\lps_07c") 913;; (lps_07c "print" nil "" "/D:\\\\printers\\lps_07c")
887;; (lps_08c nil nil nil "\\\\printers\\lps_08c") 914;; (lps_08c nil nil nil "\\\\printers\\lps_08c")
915;; (b/w "gsprint" ("-all" "-twoup") "-printer " "b/w-pr-name")
888;; (LPT1 "" nil "" "LPT1:") 916;; (LPT1 "" nil "" "LPT1:")
889;; (PRN "" nil "" "PRN") 917;; (PRN "" nil "" "PRN")
890;; (standard "redpr.exe" nil "" "") 918;; (standard "redpr.exe" nil "" "")
@@ -923,6 +951,9 @@ Please send all bug fixes and enhancements to
923;; 951;;
924;; `pr-update-menus' Update utility, PostScript and text printer menus. 952;; `pr-update-menus' Update utility, PostScript and text printer menus.
925;; 953;;
954;; `pr-menu-bind' Install `printing' menu in the menubar.
955;;
956;;
926;; Below are some URL where you can find good utilities. 957;; Below are some URL where you can find good utilities.
927;; 958;;
928;; * For `printing' package: 959;; * For `printing' package:
@@ -934,7 +965,7 @@ Please send all bug fixes and enhancements to
934;; 965;;
935;; gs, gv `http://www.gnu.org/software/ghostscript/ghostscript.html' 966;; gs, gv `http://www.gnu.org/software/ghostscript/ghostscript.html'
936;; enscript `http://people.ssh.fi/mtr/genscript/' 967;; enscript `http://people.ssh.fi/mtr/genscript/'
937;; psnup `http://www.dcs.ed.ac.uk/home/ajcd/psutils/index.html' 968;; psnup `http://www.knackered.org/angus/psutils/'
938;; mpage `http://www.mesa.nl/pub/mpage/' 969;; mpage `http://www.mesa.nl/pub/mpage/'
939;; 970;;
940;; * For Windows system: 971;; * For Windows system:
@@ -943,7 +974,7 @@ Please send all bug fixes and enhancements to
943;; `http://www.gnu.org/software/ghostscript/ghostscript.html' 974;; `http://www.gnu.org/software/ghostscript/ghostscript.html'
944;; gsprint `http://www.cs.wisc.edu/~ghost/gsview/gsprint.htm'. 975;; gsprint `http://www.cs.wisc.edu/~ghost/gsview/gsprint.htm'.
945;; enscript `http://people.ssh.fi/mtr/genscript/' 976;; enscript `http://people.ssh.fi/mtr/genscript/'
946;; psnup `http://www.dcs.ed.ac.uk/home/ajcd/psutils/index.html' 977;; psnup `http://gnuwin32.sourceforge.net/packages/psutils.htm'
947;; redmon `http://www.cs.wisc.edu/~ghost/redmon/' 978;; redmon `http://www.cs.wisc.edu/~ghost/redmon/'
948;; 979;;
949;; 980;;
@@ -1400,7 +1431,27 @@ Examples:
1400 (prt_07c nil nil \"/D:\\\\\\\\printers\\\\prt_07c\") 1431 (prt_07c nil nil \"/D:\\\\\\\\printers\\\\prt_07c\")
1401 (PRN \"\" nil \"PRN\") 1432 (PRN \"\" nil \"PRN\")
1402 (standard \"redpr.exe\" nil \"\") 1433 (standard \"redpr.exe\" nil \"\")
1403 )" 1434 )
1435
1436Useful links:
1437
1438* Information about the print command (print.exe)
1439 `http://www.computerhope.com/printhlp.htm'
1440
1441* RedMon - Redirection Port Monitor (redpr.exe)
1442 `http://www.cs.wisc.edu/~ghost/redmon/index.htm'
1443
1444* Redirection Port Monitor (redpr.exe on-line help)
1445 `http://www.cs.wisc.edu/~ghost/redmon/en/redmon.htm'
1446
1447* UNIX man pages: lpr (or type `man lpr')
1448 `http://bama.ua.edu/cgi-bin/man-cgi?lpr'
1449 `http://www.mediacollege.com/cgi-bin/man/page.cgi?section=all&topic=lpr'
1450
1451* UNIX man pages: lp (or type `man lp')
1452 `http://bama.ua.edu/cgi-bin/man-cgi?lp'
1453 `http://www.mediacollege.com/cgi-bin/man/page.cgi?section=all&topic=lp'
1454"
1404 :type '(repeat 1455 :type '(repeat
1405 (list :tag "Text Printer" 1456 (list :tag "Text Printer"
1406 (symbol :tag "Printer Symbol Name") 1457 (symbol :tag "Printer Symbol Name")
@@ -1448,6 +1499,7 @@ function (see it for documentation) to update PostScript printer menu."
1448 ;; (lps_06b "print" nil nil "\\\\printers\\lps_06b") 1499 ;; (lps_06b "print" nil nil "\\\\printers\\lps_06b")
1449 ;; (lps_07c "print" nil "" "/D:\\\\printers\\lps_07c") 1500 ;; (lps_07c "print" nil "" "/D:\\\\printers\\lps_07c")
1450 ;; (lps_08c nil nil nil "\\\\printers\\lps_08c") 1501 ;; (lps_08c nil nil nil "\\\\printers\\lps_08c")
1502 ;; (b/w "gsprint" ("-all" "-twoup") "-printer " "b/w-pr-name")
1451 ;; (LPT1 "" nil "" "LPT1:") 1503 ;; (LPT1 "" nil "" "LPT1:")
1452 ;; (PRN "" nil "" "PRN") 1504 ;; (PRN "" nil "" "PRN")
1453 ;; (standard "redpr.exe" nil "" "") 1505 ;; (standard "redpr.exe" nil "" "")
@@ -1486,6 +1538,7 @@ COMMAND Name of the program for printing a PostScript file. On MS-DOS
1486 \"lpr\" 1538 \"lpr\"
1487 \"lp\" 1539 \"lp\"
1488 \"cp\" 1540 \"cp\"
1541 \"gsprint\"
1489 1542
1490SWITCHES List of sexp's to pass as extra options for PostScript printer 1543SWITCHES List of sexp's to pass as extra options for PostScript printer
1491 program. It is recommended to set NAME (see text below) 1544 program. It is recommended to set NAME (see text below)
@@ -1495,6 +1548,9 @@ SWITCHES List of sexp's to pass as extra options for PostScript printer
1495 '(\"-#3\" \"-l\") 1548 '(\"-#3\" \"-l\")
1496 nil 1549 nil
1497 1550
1551 . for gsprint.exe
1552 '(\"-all\" \"-twoup\")
1553
1498PRINTER-SWITCH A string that specifies PostScript printer name switch. If 1554PRINTER-SWITCH A string that specifies PostScript printer name switch. If
1499 it's necessary to have a space between PRINTER-SWITCH and NAME, 1555 it's necessary to have a space between PRINTER-SWITCH and NAME,
1500 it should be inserted at the end of PRINTER-SWITCH string. 1556 it should be inserted at the end of PRINTER-SWITCH string.
@@ -1511,6 +1567,9 @@ PRINTER-SWITCH A string that specifies PostScript printer name switch. If
1511 . for print.exe 1567 . for print.exe
1512 \"/D:\" 1568 \"/D:\"
1513 1569
1570 . for gsprint.exe
1571 \"-printer \"
1572
1514NAME A string that specifies a PostScript printer name. 1573NAME A string that specifies a PostScript printer name.
1515 On Unix-like systems, a string value should be a name 1574 On Unix-like systems, a string value should be a name
1516 understood by lpr's -P option (or lp's -d option). 1575 understood by lpr's -P option (or lp's -d option).
@@ -1526,7 +1585,7 @@ NAME A string that specifies a PostScript printer name.
1526 . for cp.exe 1585 . for cp.exe
1527 \"\\\\\\\\host\\\\share-name\" 1586 \"\\\\\\\\host\\\\share-name\"
1528 1587
1529 . for print.exe 1588 . for print.exe or gsprint.exe
1530 \"/D:\\\\\\\\host\\\\share-name\" 1589 \"/D:\\\\\\\\host\\\\share-name\"
1531 \"\\\\\\\\host\\\\share-name\" 1590 \"\\\\\\\\host\\\\share-name\"
1532 \"LPT1:\" 1591 \"LPT1:\"
@@ -1575,10 +1634,80 @@ Examples:
1575 (lps_06b \"print\" nil nil \"\\\\\\\\printers\\\\lps_06b\") 1634 (lps_06b \"print\" nil nil \"\\\\\\\\printers\\\\lps_06b\")
1576 (lps_07c \"print\" nil \"\" \"/D:\\\\\\\\printers\\\\lps_07c\") 1635 (lps_07c \"print\" nil \"\" \"/D:\\\\\\\\printers\\\\lps_07c\")
1577 (lps_08c nil nil nil \"\\\\\\\\printers\\\\lps_08c\") 1636 (lps_08c nil nil nil \"\\\\\\\\printers\\\\lps_08c\")
1637 (b/w1 \"gsprint\" (\"-all\" \"-twoup\") \"-printer \" \"b/w-pr-name\")
1638 (b/w2 \"gsprint\" (\"-all\" \"-twoup\") nil \"-printer \\\\\\\\printers\\\\lps_06a\")
1578 (LPT1 \"\" nil \"\" \"LPT1:\") 1639 (LPT1 \"\" nil \"\" \"LPT1:\")
1579 (PRN \"\" nil \"\" \"PRN\") 1640 (PRN \"\" nil \"\" \"PRN\")
1580 (standard \"redpr.exe\" nil \"\" \"\") 1641 (standard \"redpr.exe\" nil \"\" \"\")
1581 )" 1642 )
1643
1644
1645gsprint:
1646
1647You can use gsprint instead of ghostscript to print monochrome PostScript files
1648in Windows. The gsprint utility documentation says that it is more efficient
1649than ghostscript to print monochrome PostScript.
1650
1651To print non-monochrome PostScript file, the efficiency of ghostscript is
1652similar to gsprint.
1653
1654Also the gsprint utility comes together with gsview distribution.
1655
1656As an example of gsprint declaration:
1657
1658 (setq pr-ps-printer-alist
1659 '((A \"gsprint\" (\"-all\" \"-twoup\") \"-printer \" \"lps_015\")
1660 (B \"gsprint\" (\"-all\" \"-twoup\") nil \"-printer lps_015\")
1661 ;; some other printer declaration
1662 ))
1663
1664The example above declares that printer A prints all pages (-all) and two pages
1665per sheet (-twoup). The printer B declaration does the same as the printer A
1666declaration, the only difference is the printer name selection.
1667
1668There are other command line options like:
1669
1670 -mono Render in monochrome as 1bit/pixel (only black and white).
1671 -grey Render in greyscale as 8bits/pixel.
1672 -color Render in color as 24bits/pixel.
1673
1674The default is `-mono'. So, printer A and B in the example above are using
1675implicitly the `-mono' option. Note that in `-mono' no gray tone or color is
1676printed, this includes the zebra stripes, that is, in `-mono' the zebra stripes
1677are not printed.
1678
1679
1680Useful links:
1681
1682* GSPRINT - Ghostscript print to Windows printer
1683 `http://www.cs.wisc.edu/~ghost/gsview/gsprint.htm'
1684
1685* Introduction to Ghostscript
1686 `http://www.cs.wisc.edu/~ghost/doc/intro.htm'
1687
1688* How to use Ghostscript
1689 `http://www.cs.wisc.edu/~ghost/doc/cvs/Use.htm'
1690
1691* Information about the print command (print.exe)
1692 `http://www.computerhope.com/printhlp.htm'
1693
1694* RedMon - Redirection Port Monitor (redpr.exe)
1695 `http://www.cs.wisc.edu/~ghost/redmon/index.htm'
1696
1697* Redirection Port Monitor (redpr.exe on-line help)
1698 `http://www.cs.wisc.edu/~ghost/redmon/en/redmon.htm'
1699
1700* UNIX man pages: lpr (or type `man lpr')
1701 `http://bama.ua.edu/cgi-bin/man-cgi?lpr'
1702 `http://www.mediacollege.com/cgi-bin/man/page.cgi?section=all&topic=lpr'
1703
1704* UNIX man pages: lp (or type `man lp')
1705 `http://bama.ua.edu/cgi-bin/man-cgi?lp'
1706 `http://www.mediacollege.com/cgi-bin/man/page.cgi?section=all&topic=lp'
1707
1708* GNU utilities for Win32 (cp.exe)
1709 `http://unxutils.sourceforge.net/'
1710"
1582 :type '(repeat 1711 :type '(repeat
1583 (list 1712 (list
1584 :tag "PostScript Printer" 1713 :tag "PostScript Printer"
@@ -1674,7 +1803,37 @@ See also `pr-temp-dir' and `pr-ps-temp-file'."
1674 "gv") 1803 "gv")
1675 "*Specify path and name of the gsview/gv utility. 1804 "*Specify path and name of the gsview/gv utility.
1676 1805
1677See also `pr-path-alist'." 1806See also `pr-path-alist'.
1807
1808Useful links:
1809
1810* GNU gv manual
1811 `http://www.gnu.org/software/gv/manual/gv.html'
1812
1813* GSview Help
1814 `http://www.cs.wisc.edu/~ghost/gsview/gsviewen.htm'
1815
1816* GSview Help - Common Problems
1817 `http://www.cs.wisc.edu/~ghost/gsview/gsviewen.htm#Common_Problems'
1818
1819* GSview Readme (compilation & installation)
1820 `http://www.cs.wisc.edu/~ghost/gsview/Readme.htm'
1821
1822* GSview (main site)
1823 `http://www.cs.wisc.edu/~ghost/gsview/index.htm'
1824
1825* Ghostscript, Ghostview and GSview
1826 `http://www.cs.wisc.edu/~ghost/'
1827
1828* Ghostview
1829 `http://www.cs.wisc.edu/~ghost/gv/index.htm'
1830
1831* gv 3.5, June 1997
1832 `http://www.cs.wisc.edu/~ghost/gv/gv_doc/gv.html'
1833
1834* MacGSView (MacOS)
1835 `http://www.cs.wisc.edu/~ghost/macos/index.htm'
1836"
1678 :type '(string :tag "Ghostview Utility") 1837 :type '(string :tag "Ghostview Utility")
1679 :version "20" 1838 :version "20"
1680 :group 'printing) 1839 :group 'printing)
@@ -1686,7 +1845,22 @@ See also `pr-path-alist'."
1686 "gs") 1845 "gs")
1687 "*Specify path and name of the ghostscript utility. 1846 "*Specify path and name of the ghostscript utility.
1688 1847
1689See also `pr-path-alist'." 1848See also `pr-path-alist'.
1849
1850Useful links:
1851
1852* Ghostscript, Ghostview and GSview
1853 `http://www.cs.wisc.edu/~ghost/'
1854
1855* Introduction to Ghostscript
1856 `http://www.cs.wisc.edu/~ghost/doc/intro.htm'
1857
1858* How to use Ghostscript
1859 `http://www.cs.wisc.edu/~ghost/doc/cvs/Use.htm'
1860
1861* Printer compatibility
1862 `http://www.cs.wisc.edu/~ghost/doc/printer.htm'
1863"
1690 :type '(string :tag "Ghostscript Utility") 1864 :type '(string :tag "Ghostscript Utility")
1691 :version "20" 1865 :version "20"
1692 :group 'printing) 1866 :group 'printing)
@@ -1717,7 +1891,19 @@ To see ghostscript documentation for more information:
1717 - for full documentation, see in a browser the file 1891 - for full documentation, see in a browser the file
1718 c:/gstools/gs5.50/index.html, that is, the file index.html which is 1892 c:/gstools/gs5.50/index.html, that is, the file index.html which is
1719 located in the same directory as gswin32.exe. 1893 located in the same directory as gswin32.exe.
1720 - for brief documentation, type: gswin32.exe -h" 1894 - for brief documentation, type: gswin32.exe -h
1895
1896Useful links:
1897
1898* Introduction to Ghostscript
1899 `http://www.cs.wisc.edu/~ghost/doc/intro.htm'
1900
1901* How to use Ghostscript
1902 `http://www.cs.wisc.edu/~ghost/doc/cvs/Use.htm'
1903
1904* Printer compatibility
1905 `http://www.cs.wisc.edu/~ghost/doc/printer.htm'
1906"
1721 :type '(repeat (string :tag "Ghostscript Switch")) 1907 :type '(repeat (string :tag "Ghostscript Switch"))
1722 :version "20" 1908 :version "20"
1723 :group 'printing) 1909 :group 'printing)
@@ -2184,7 +2370,35 @@ Examples:
2184 2370
2185 '((psnup \"c:/psutils/psnup\" (\"-q\") \"-P%s\" \"-%d\" \"-l\" nil nil \" \" 2371 '((psnup \"c:/psutils/psnup\" (\"-q\") \"-P%s\" \"-%d\" \"-l\" nil nil \" \"
2186 nil (pr-file-duplex . nil) (pr-file-tumble . nil)) 2372 nil (pr-file-duplex . nil) (pr-file-tumble . nil))
2187 )" 2373 )
2374
2375Useful links:
2376
2377* mpage download (GNU or Unix)
2378 `http://www.mesa.nl/pub/mpage/'
2379
2380* mpage documentation (GNU or Unix - or type `man mpage')
2381 `http://www.cs.umd.edu/faq/guides/manual_unix/node48.html'
2382 `http://www.rt.com/man/mpage.1.html'
2383
2384* psnup (Windows, GNU or Unix)
2385 `http://www.knackered.org/angus/psutils/'
2386 `http://gershwin.ens.fr/vdaniel/Doc-Locale/Outils-Gnu-Linux/PsUtils/'
2387
2388* psnup (PsUtils for Windows)
2389 `http://gnuwin32.sourceforge.net/packages/psutils.htm'
2390
2391* psnup documentation (GNU or Unix - or type `man psnup')
2392 `http://linux.about.com/library/cmd/blcmdl1_psnup.htm'
2393 `http://amath.colorado.edu/computing/software/man/psnup.html'
2394
2395* GNU Enscript (Windows, GNU or Unix)
2396 `http://people.ssh.com/mtr/genscript/'
2397
2398* GNU Enscript documentation (Windows, GNU or Unix)
2399 `http://people.ssh.com/mtr/genscript/enscript.man.html'
2400 (on GNU or Unix, type `man enscript')
2401"
2188 :type '(repeat 2402 :type '(repeat
2189 (list :tag "PS File Utility" 2403 (list :tag "PS File Utility"
2190 (symbol :tag "Utility Symbol") 2404 (symbol :tag "Utility Symbol")
@@ -2845,43 +3059,65 @@ See `pr-ps-printer-alist'.")
2845 ))) 3059 )))
2846 3060
2847 3061
2848(cond 3062(defvar pr-menu-print-item "print"
2849 ((featurep 'xemacs) ; XEmacs 3063 "Non-nil means that menu binding was not done.
2850 ;; Menu binding
2851 (pr-xemacs-global-menubar
2852 (pr-x-add-submenu nil (cons "Printing" pr-menu-spec) "Apps")))
2853 3064
3065Used by `pr-menu-bind' and `pr-update-menus'.")
2854 3066
2855 (t ; GNU Emacs 3067
2856 ;; Menu binding 3068(defun pr-menu-bind ()
2857 (require 'easymenu) 3069 "Install `printing' menu in the menubar.
2858 ;; Replace existing "print" item by "Printing" item. 3070
2859 ;; If you're changing this file, you'll load it a second, 3071On Emacs 20, it replaces the Tools/Print menu by Tools/Printing menu.
2860 ;; third... time, but "print" item exists only in the first load. 3072
2861 (defvar pr-menu-print-item "print") 3073On Emacs 21 and 22, it replaces the File/Print* menu entries by File/Print
3074menu.
3075
3076Calls `pr-update-menus' to adjust menus."
3077 (interactive)
2862 (cond 3078 (cond
2863 ;; Emacs 20 3079 ((featurep 'xemacs) ; XEmacs
2864 ((string< emacs-version "21.") 3080 ;; Menu binding
2865 (easy-menu-change '("tools") "Printing" pr-menu-spec pr-menu-print-item) 3081 (pr-xemacs-global-menubar
2866 (when pr-menu-print-item 3082 (pr-x-add-submenu nil (cons "Printing" pr-menu-spec) "Apps"))
2867 (easy-menu-remove-item nil '("tools") pr-menu-print-item) 3083 (setq pr-menu-print-item nil))
2868 (setq pr-menu-print-item nil 3084
2869 pr-menu-bar (vector 'menu-bar 'tools 3085
2870 (pr-get-symbol "Printing"))))) 3086 (t ; GNU Emacs
2871 ;; Emacs 21 3087 ;; Menu binding
2872 (pr-menu-print-item 3088 (require 'easymenu)
2873 (easy-menu-change '("file") "Print" pr-menu-spec "print-buffer") 3089 ;; Replace existing "print" item by "Printing" item.
2874 (let ((items '("print-buffer" "print-region" 3090 ;; If you're changing this file, you'll load it a second,
2875 "ps-print-buffer-faces" "ps-print-region-faces" 3091 ;; third... time, but "print" item exists only in the first load.
2876 "ps-print-buffer" "ps-print-region"))) 3092 (cond
2877 (while items 3093 ;; Emacs 20
2878 (easy-menu-remove-item nil '("file") (car items)) 3094 ((string< emacs-version "21.")
2879 (setq items (cdr items))) 3095 (easy-menu-change '("tools") "Printing" pr-menu-spec pr-menu-print-item)
2880 (setq pr-menu-print-item nil 3096 (when pr-menu-print-item
2881 pr-menu-bar (vector 'menu-bar 'file 3097 (easy-menu-remove-item nil '("tools") pr-menu-print-item)
2882 (pr-get-symbol "Print"))))) 3098 (setq pr-menu-print-item nil
2883 (t 3099 pr-menu-bar (vector 'menu-bar 'tools
2884 (easy-menu-change '("file") "Print" pr-menu-spec))))) 3100 (pr-get-symbol "Printing")))))
3101 ;; Emacs 21 & 22
3102 (t
3103 (let* ((has-file (lookup-key global-map (vector 'menu-bar 'file)))
3104 (item-file (if has-file '("file") '("files"))))
3105 (cond
3106 (pr-menu-print-item
3107 (easy-menu-change item-file "Print" pr-menu-spec "print-buffer")
3108 (let ((items '("print-buffer" "print-region"
3109 "ps-print-buffer-faces" "ps-print-region-faces"
3110 "ps-print-buffer" "ps-print-region")))
3111 (while items
3112 (easy-menu-remove-item nil item-file (car items))
3113 (setq items (cdr items)))
3114 (setq pr-menu-print-item nil
3115 pr-menu-bar (vector 'menu-bar
3116 (if has-file 'file 'files)
3117 (pr-get-symbol "Print")))))
3118 (t
3119 (easy-menu-change item-file "Print" pr-menu-spec))))))))
3120 (pr-update-menus t))
2885 3121
2886 3122
2887;; Key binding 3123;; Key binding
@@ -4712,12 +4948,20 @@ If FORCE is non-nil, update menus doesn't matter if `pr-ps-printer-alist',
4712otherwise, update PostScript printer menu iff `pr-ps-printer-menu-modified' is 4948otherwise, update PostScript printer menu iff `pr-ps-printer-menu-modified' is
4713non-nil, update text printer menu iff `pr-txt-printer-menu-modified' is 4949non-nil, update text printer menu iff `pr-txt-printer-menu-modified' is
4714non-nil, and update PostScript File menus iff `pr-ps-utility-menu-modified' is 4950non-nil, and update PostScript File menus iff `pr-ps-utility-menu-modified' is
4715non-nil." 4951non-nil.
4952
4953If menu binding was not done, calls `pr-menu-bind'."
4716 (interactive "P") 4954 (interactive "P")
4717 (pr-update-var 'pr-ps-name pr-ps-printer-alist) 4955 (if pr-menu-print-item ; since v6.8.4
4718 (pr-update-var 'pr-txt-name pr-txt-printer-alist) 4956 ;; There was no menu binding yet, so do it now!
4719 (pr-update-var 'pr-ps-utility pr-ps-utility-alist) 4957 ;; This is a hack to be compatible with old versions of printing.
4720 (pr-do-update-menus force)) 4958 ;; So, user does not need to change printing calling in init files.
4959 (pr-menu-bind)
4960 ;; Here menu binding is ok.
4961 (pr-update-var 'pr-ps-name pr-ps-printer-alist)
4962 (pr-update-var 'pr-txt-name pr-txt-printer-alist)
4963 (pr-update-var 'pr-ps-utility pr-ps-utility-alist)
4964 (pr-do-update-menus force)))
4721 4965
4722 4966
4723(defvar pr-ps-printer-menu-modified t 4967(defvar pr-ps-printer-menu-modified t
@@ -6434,9 +6678,6 @@ COMMAND.exe, COMMAND.bat and COMMAND.com in this order."
6434;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 6678;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
6435 6679
6436 6680
6437(pr-update-menus t)
6438
6439
6440(provide 'printing) 6681(provide 'printing)
6441 6682
6442 6683