NOT RELEASED YET

PS Viewer 2.0 Release Notes

Release Notes Version: $Revision: 1.2 $.

The most recent version of this file is available here. Release notes for all versions of the PS Viewer are available here.

The PS Viewer is a Level 2 PostScript viewer which can either be used stand-alone or is embeddable in a user application.

The Viewer will handle most PostScript commands, but some restrictions apply, see our bug database.

CompliancePostScript Compliance

This viewer implements most of the PostScript Level 2 commands and some of the Level 3 commands. For a description of PostScript see the PostScript Language Reference Manual, Third Edition from Adobe Systems Inc.

ChangesMajor changes in the PS Viewer 1.1.0

  • FREEHEP-393: Command Line Argument parsing now uses org.freehep.util.argv package.
  • FREEHEP-400: A PSDevice class was added with a VirtualDevice and a PanelDevice to cope with the PageBoundingBox, BoundingBox and multiple pages, including the Raster erasePage operation. It also allows for zooming into the page (-s) and specifying a translation (-tx, -ty).
  • FREEHEP-398: One page from a multiple page PS file can be viewed (-p), but the document still needs to be fully read up to the page to be displayed. In future we may want to add DSC handling to split documents into pages.
  • FREEHEP-151: MatrixOperators DefaultMatrix and InitMatrix should keep using the Identity Matrix.
  • FREEHEP-126: ArithmeticOperators now return PSDouble if the result is not in an PSInteger range.
  • FREEHEP-160: PathBBox now handles explicitly set BoundingBox.
  • FREEHEP-167 (partial): SetBBox now in use.
  • FREEHEP-150: ScaleFont and MakeFont return a copy of the font.
  • FREEHEP-159: CharPath now uses boolean "strokepath" to create a stroked path if necessary.
  • FREEHEP-401: Fonts only turned upside-down when glyphs are produced. CurrentFont now returns proper font and matrix, MakeFont takes size of previous CurrentFont call into account.
  • FREEHEP-143: CvI and CvRS report RangeCheck errors.
  • FREEHEP-125: Document Structuring Conventions (DSC) level 3.0 implemented to parse for instance BoundingBox and Page.
  • FREEHEP-402: Scanner ignores lines starting with @ so that @PCL can be left in the PostScript file.
  • FREEHEP-403: PSName ignores names starting with an "ESC" character.
  • FREEHEP-404: ClassCastException fixed in Copy command when PackedArrays are used.

LicenseLicense

The PS Viewer is part of the FreeHEP Java Library, an "Open Source" library distributed under the terms of the LGPL. If you have questions about the licensing please send a mail to: developers@freehep.org.

InstallationInstalling the PS Viewer

Download the PS Viewer and unpack. The distribution creates the following directory structure:

PSViewer-version            containing license and release notes
PSViewer-version/bin        containing run scripts
PSViewer-version/examples   containing examples
PSViewer-version/lib        containing jar files

CompilationCompiling the PS Viewer

The current distribution does not contain source files.

To (re-)build the PS Viewer you need to get PSViewer-2.0-src.zip or .tar.gz file from the ftp://ftp.slac.stanford.edu/software/freehep/PSViewer/v2.0/ directory.

To compile it, follow the general instructions for Building the Java FreeHEP Library and compile only the psviewer.jar file using the command:

ant -Djar=psviewer

To build the distribution kit:

cd org/freehep/postscript
gmake dist

BuildingBuilding an Application with the PS Viewer

Set the environment variable PSVIEWER_HOME to your unpacked PSViewer distribution.

Add the following libraries (all in $PSVIEWER_HOME/lib) to your CLASSPATH:

freehep-psviewer.jar
freehep-graphicsio.jar
freehep-graphics2d.jar
freehep-base.jar

Now you can compile your application using the PS Viewer, and run it.

RunningRunning the PS Viewer

Set the environment variable PSVIEWER_HOME to your unpacked PSViewer distribution.

Add $PSVIEWER_HOME/bin to your PATH and run:

psviewer

or

psviewer -h

to get a description of the options.

FeaturesFeatures/Limitations of the Current Release

The following limitations exist:

  • All outstanding issues in the Bug Database.
  • All images using 12 bits/component probably will not work.
  • The distribution kits contain some CVS directories and files, please ignore.
  • The freehep-base.jar file (and especially its sources) are dependent on some external jar files which are not strictly needed for the PS Viewer. Please ignore for now. In a later release we will shrink freehep-base.jar and get rid of these dependencies.

BugReportingReporting Bugs

To report bugs or request enhancements you may use the FreeHEP bug database.

ExamplesExamples

The PSViewer/examples directory contains:

  • EmbedPSViewer.java which shows how to embed 2 PSViewers in one application
  • PStoSWF.java which shows how to build a converter from PostScript to Macromedia Flash Format (SWF).