Class Layer

java.lang.Object
  extended by java.awt.Component
      extended by java.awt.Container
          extended by java.awt.Window
              extended by java.awt.Frame
                  extended by javax.swing.JFrame
                      extended by Layer
All Implemented Interfaces:
java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable, javax.accessibility.Accessible, javax.swing.RootPaneContainer, javax.swing.WindowConstants

public class Layer
extends javax.swing.JFrame

Layer is used to create a new main canvas to draw upon The OS is windows. There is no implementation variances. There is no security constaints. There is no external secification.

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class javax.swing.JFrame
javax.swing.JFrame.AccessibleJFrame
 
Nested classes/interfaces inherited from class java.awt.Frame
java.awt.Frame.AccessibleAWTFrame
 
Nested classes/interfaces inherited from class java.awt.Window
java.awt.Window.AccessibleAWTWindow
 
Nested classes/interfaces inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
 
Nested classes/interfaces inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy
 
Field Summary
 AllLayers all
          paint is a TerpPaint value that holds the drawing board.
 javax.swing.JTextField area
          JTextField that determines the name of the layer that user types.
 javax.swing.JButton change
          JButton that determines the changing of the name of layer.
 javax.swing.JRadioButtonMenuItem current
          GUI JRadioButtonMenuItem for current layer.
 main_canvas layerCanvas
          layerCanvas is the main_canvas object for which each layer can draw.
 java.lang.String Name
          String to store the name of the layer.
 javax.swing.JLabel nameLab
          nameLab is JLabel that labels the name of the layer.
static int number
          number to store the position within the gridbagconstraints.
 javax.swing.JFrame popUp
          popUp is frame so for the remove function so that the name can be typed.
 javax.swing.JFrame temp
          JFrame that opens the temp for remove function.
 javax.swing.JCheckBox visible
          JCheckBox that determines visibility.
 
Fields inherited from class javax.swing.JFrame
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled
 
Fields inherited from class java.awt.Frame
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR
 
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
 
Fields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, HIDE_ON_CLOSE
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
Layer(main_canvas theCanvas)
          The Layer constructor is called by the AllLayer class when pressing the add button It should work with all operating systems and hardware.
 
Method Summary
 void cancelActionPerformed(java.awt.event.ActionEvent evt)
          This function operates when GUI user clicks on cancel Nothing is saved and the temporary frame for remove is disappeared.
 void changeActionPerformed(java.awt.event.ActionEvent evt)
          This function is called by change button on GUI It changes the name of the single layer It should work with all operating systems and hardware.
 void currentActionPerformed(java.awt.event.ActionEvent evt)
          This function sets the current layer to display It should work with all operating systems and hardware.
 void initComponents()
          This function initializes the GUI components of the Layer class and is only called by the Layer constructor It should work with all operating systems and hardware.
static void main(java.lang.String[] args)
          This is the main and does initializing.
 void okActionPerformed(java.awt.event.ActionEvent evt)
          This function operates when GUI user clicks on ok The function stores new name of the layer and changes the label to correct name It should work with all operating systems and hardware.
 void removeLayer()
          This function sets popUp frame to be not visible.
 
Methods inherited from class javax.swing.JFrame
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getJMenuBar, getLayeredPane, getRootPane, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setIconImage, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, update
 
Methods inherited from class java.awt.Frame
addNotify, finalize, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setResizable, setState, setTitle, setUndecorated
 
Methods inherited from class java.awt.Window
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getGraphicsConfiguration, getInputContext, getListeners, getLocale, getMostRecentFocusOwner, getOwnedWindows, getOwner, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isShowing, pack, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, setAlwaysOnTop, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setLocationByPlatform, setLocationRelativeTo, show, toBack, toFront
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paint, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusBackward, transferFocusDownCycle, validate, validateTree
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphics, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, reshape, resize, resize, setBackground, setBounds, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setMinimumSize, setName, setPreferredSize, setSize, setSize, setVisible, show, size, toString, transferFocus, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.awt.MenuContainer
getFont, postEvent
 

Field Detail

all

public AllLayers all
paint is a TerpPaint value that holds the drawing board.


current

public javax.swing.JRadioButtonMenuItem current
GUI JRadioButtonMenuItem for current layer.


layerCanvas

public main_canvas layerCanvas
layerCanvas is the main_canvas object for which each layer can draw.


popUp

public javax.swing.JFrame popUp
popUp is frame so for the remove function so that the name can be typed.


visible

public javax.swing.JCheckBox visible
JCheckBox that determines visibility.


change

public javax.swing.JButton change
JButton that determines the changing of the name of layer.


area

public javax.swing.JTextField area
JTextField that determines the name of the layer that user types.


temp

public javax.swing.JFrame temp
JFrame that opens the temp for remove function.


nameLab

public javax.swing.JLabel nameLab
nameLab is JLabel that labels the name of the layer.


number

public static int number
number to store the position within the gridbagconstraints.


Name

public java.lang.String Name
String to store the name of the layer.

Constructor Detail

Layer

public Layer(main_canvas theCanvas)
The Layer constructor is called by the AllLayer class when pressing the add button It should work with all operating systems and hardware. There are no variances and no security constraints.

Parameters:
theCanvas - main_canvas
Method Detail

initComponents

public void initComponents()
This function initializes the GUI components of the Layer class and is only called by the Layer constructor It should work with all operating systems and hardware. There are no variances and no security constraints.


removeLayer

public void removeLayer()
This function sets popUp frame to be not visible.


currentActionPerformed

public void currentActionPerformed(java.awt.event.ActionEvent evt)
This function sets the current layer to display It should work with all operating systems and hardware. There are no variances and no security constraints.

Parameters:
evt - ActionEvent

changeActionPerformed

public void changeActionPerformed(java.awt.event.ActionEvent evt)
This function is called by change button on GUI It changes the name of the single layer It should work with all operating systems and hardware. There are no variances and no security constraints.

Parameters:
evt - ActionEvent

okActionPerformed

public void okActionPerformed(java.awt.event.ActionEvent evt)
This function operates when GUI user clicks on ok The function stores new name of the layer and changes the label to correct name It should work with all operating systems and hardware. There are no variances and no security constraints.

Parameters:
evt - ActionEvent

cancelActionPerformed

public void cancelActionPerformed(java.awt.event.ActionEvent evt)
This function operates when GUI user clicks on cancel Nothing is saved and the temporary frame for remove is disappeared.

Parameters:
evt - ActionEvent

main

public static void main(java.lang.String[] args)
This is the main and does initializing.

Parameters:
args - String[]