This package provides utilities to add a print screen (text and image) capability to Java GUI windows.

The package is designed to provide automatic capabilities without any coding and enhance capabilities with additional coding in the GUI. That is, a text version of the screen will be automatically produced, but you can enhance its appearance by implementing appropriate interfaces in your GUI objects.

The easiest way to use this class is to include the following code when constructing the applications menus:

import com.saic.div491.printscreen.PrintScreenFactory;

...

PrintScreenFactory prtScreen = new PrintScreenFactory( this );

fileMenu.add( prtScreen.makeScreenSaveJMenu() );

fileMenu.add( prtScreen.makeScreenPrintJMenu() );

fileMenu.add( prtScreen.makeScreenPreviewJMenu() );

editMenu.add( prtScreen.makeScreenCopyJMenu() );

That code will create sub-menus allowing the user to create versions of the screen in any of unformatted text, html, xml, and a jpeg image.

If you implement the {@link com.saic.isd.printscreen.IPrintScreenText IPrintScreenText} interface on any GUI component descending from java.awt.Component, then the text inserted for that component and all of its children will be produced by the component and not by the automatic walking provisions.

If you need to make custom menus, then you can get the actions to use for your menu from: {@link com.saic.isd.printscreen.PrintScreenFactory#getAction PrintScreenFactory.getAction()}

The following research was consulted in developing this package: New Data Transfer Capabilities, John Zukowski, Java Developer Connection, November 2001
Advanced Programming for the JavaTM 2 Platform, Chapter 6 Continued: Advanced Printing, Java Developer Connection
Java Tip 77: Enable copy and paste functionality between Swing's JTables and Excel, Java World
Java Tip 61: Cut, copy, and paste in Java, Java World
Unfurling Java's data transfer API, Java World
Printing in Java, Part 1, Java World
Java 2 introduces print capability to the Swing Forum, Java World
Printing Images in Java 1.1

This open source library was developed by IMPACTS team of SAIC Division 491. Principal contributors include: Gerhard Beck, Charlie Meiburg, and Alvin Rearick.

Copyright (c) 2004 SAIC. All rights reserved.

Subject to the GNU LESSER GENERAL PUBLIC LICENSE, Version 2.1, February 1999 http://www.gnu.org/copyleft/lesser.html

THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE SAIC OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.