Document Sections:
Project Definitions and Requirements
Project Definitions and Requirements
Project Information:
Software |
APT |
Project |
APT |
OPR Number |
|
Document Author |
Frank Tanner |
WBS |
P0002.539.00.03.001 |
Revision History |
|
Currently, there is not mechanism for undoing changes in the VTT or in the APT architecture in general. The inability to undo changes in the VTT is very inconvenient to users. In the grander overall architecture of APT, a consistent, coherent undo function could benefit all of the tools within the APT suite. Tools such as the ETC, Exposure planners, and others could benefit from an easy to use architecture.
There currently is no Undo/Redo functionality in APT.
Add an Undo and associated Redo function to the APT.
Initially, the undo feature will be implemented for the VTT. Although the top level classes and interfaces will be associated with the APT architecture as a whole, the VTT will be the first tool to implement undoable functionality. However, the Undo menu item will be visible to all users of APT regardless of the tool being used. When “Undo” functionality is unavailable, the menu item will be disabled.
There are no external dependencies for this enhancement.
The undo feature will have similar capabilities to those found in many highly graphical applications. There will also be an associated Redo capability implemented with the Undo. The Redo will not be very robust. Both the Undo and Redo capabilities are outlined in the requirements that follow.
There are three classes of requirements for this document:
1) Those items that will definitely be included in the initial version of the Undo feature.
2) Those items which may be implemented as Undoable
3) Those items which will not be initially implemented
An UndoManager (which will be described later) will be able to keep track of Undoable events. However, there will be certain circumstances in which the UndoManager will need to reset its list of events. Those circumstances are as follows:
Some background information regarding Swing’s Undo/Redo functionality may be beneficial in understanding the rest of this document. Please see the following links for background information:
· TextComponentDemo example – http://java.sun.com/docs/books/tutorial/uiswing/components/example-swing/TextComponentDemo.java
· UndoableEditListener implementation – http://java.sun.com/docs/books/tutorial/uiswing/events/undoableeditlistener.html
· General Rules for Implementing Undo and Redo – http://java.sun.com/docs/books/tutorial/uiswing/components/generaltext.html#undo
· Undo API information:
o http://java.sun.com/products/jdk/1.2/docs/api/javax/swing/undo/UndoableEdit.html
o http://java.sun.com/products/jdk/1.2/docs/api/javax/swing/undo/UndoManager.html
Note, the above examples show Undo as implemented for text documents. It does not entail using Undo/Redo functionality for a more global architecture as it will be used for APT. Please keep this in mind when reading the examples and reviewing this document.