PostScript printing code rewritten, based on NetPBM's 'pnmtops' tool by Jef Poskanzer.

PostScript printing now uses libprint to determine papersize, and scale and
  position image accordingly.  Thanks to Henry House.
"--papersize" option added to allow PostScript printing code to use a
  different size than libpaper reports as the user's or system's default.
This commit is contained in:
William Kendrick 2007-06-25 18:00:49 +00:00
parent 4b642d53d5
commit b16832d76a
10 changed files with 420 additions and 74 deletions

View file

@ -7,7 +7,7 @@ bill@newbreedsoftware.com
http://www.tuxpaint.org/
June 17, 2002 - June 19, 2007
June 17, 2002 - June 25, 2007
$Id$
@ -35,6 +35,16 @@ $Id$
Input Method (IM) Framework and Korean/Japanese IM implemented by:
Mark K. Kim <mkkim214@gmail.com>
PostScript printing code based loosely on NetPBM's "pnmtops",
copyright (c) 1989 by Jef Poskanzer.
License of "pnmtops.c":
Permission to use, copy, modify, and distribute this software and its
documentation for any purpose and without fee is hereby granted, provided
that the above copyright notice appear in all copies and that both that
copyright notice and this permission notice appear in supporting
documentation. This software is provided "as is" without express or
implied warranty.
* Graphics

View file

@ -4,12 +4,12 @@ Tux Paint - A simple drawing program for children.
Copyright (c) 2002-2007 by Bill Kendrick and others
bill@newbreedsoftware.com
http://www.newbreedsoftware.com/tuxpaint/
http://www.tuxpaint.org/
$Id$
2007.June.24 (0.9.17)
2007.June.25 (0.9.17)
* Interface Improvements:
-----------------------
@ -110,6 +110,18 @@ $Id$
* Split PostScript printing code (for Linux/Unix/etc.) into its own
source file. (Mac OS X, Windows and BeOS all had their own.)
* PostScript printing code rewritten, based on NetPBM's 'pnmtops' tool
by Jef Poskanzer.
* PostScript printing now uses libprint to determine papersize, and
scale and position image accordingly. (No longer depending on printer
to figure out its own paper size; not the recommended method.)
Thanks to Henry House <hajhouse@houseag.com>
* "--papersize" option added to allow PostScript printing code to
use a different size than libpaper reports as the user's or system's
default.
* Documentation Improvements:
---------------------------
* Discussed SVG Stamps in "Extending Tux Paint."

View file

@ -9,7 +9,7 @@
bill@newbreedsoftware.com
http://www.tuxpaint.org/
June 19, 2007
June 25, 2007
--------------------------------------------------------------------------
@ -196,6 +196,22 @@ Windows Users
Clicking 'Print' without holding [Alt] prints without showing a
dialog.
papersize=PAPERSIZE
(Platforms that use Tux Paint's internal PostScript generator --
not Windows, Mac OS X or BeOS.)
Tell Tux Paint what size PostScript to generate. If none is
specified, Tux Paint first checks your $PAPER environment
variable, then the file /etc/papersize, then uses the the
'libpaper' library's default paper size.
Valid paper sizes include: letter, legal, tabloid, executive,
note, statement, a0, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10,
b0, b1, b2 b3, b4, 10x14, 11x17, halfletter, halfexecutive,
halfnote, folio, quarto, ledger, archA, archB, archC, archD,
archE, flsa, flse, csheet, dsheet, esheet.
simpleshapes=yes
Disable the rotation step of the 'Shape' tool. Click, drag and
release is all that will be needed to draw a shape.
@ -563,6 +579,7 @@ Windows Users
--noprint
--printdelay=SECONDS
--printcfg
--papersize=PAPERSIZE
--simpleshapes
--uppercase
--grab

View file

@ -23,7 +23,7 @@ New Breed Software</p>
<a href="http://www.tuxpaint.org/">http://www.tuxpaint.org/</a></p>
<p>June 19, 2007</p>
<p>June 25, 2007</p>
</center>
@ -252,6 +252,30 @@ New Breed Software</p>
a dialog.</p>
</dd>
<dt><code><b>papersize=<i>PAPERSIZE</i></b></code></dt>
<dd>
<p><i>(Platforms that use Tux&nbsp;Paint's internal PostScript
generator &mdash; not Windows, Mac OS X or BeOS.)</i></p>
<p>Tell Tux&nbsp;Paint what size PostScript to generate.
If none is specified, Tux&nbsp;Paint first checks
your <code>$PAPER</code> environment variable, then
the file <code>/etc/papersize</code>, then uses the the
'libpaper' library's default paper size.</p>
<p>Valid paper sizes include:
letter, legal, tabloid, executive, note, statement,
a0, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10,
b0, b1, b2 b3, b4,
10x14, 11x17,
halfletter, halfexecutive, halfnote,
folio, quarto, ledger,
archA, archB, archC, archD, archE,
flsa, flse,
csheet, dsheet, esheet.
</p>
</dd>
<dt><code><b>simpleshapes=yes</b></code></dt>
<dd>
Disable the rotation step of the 'Shape' tool.
@ -882,6 +906,7 @@ New Breed Software</p>
--noprint<br>
--printdelay=<i>SECONDS</i><br>
--printcfg<br>
--papersize=<i>PAPERSIZE</i><br>
--simpleshapes<br>
--uppercase<br>
--grab<br>