ciips.animation
Class Legend

java.lang.Object
  extended byciips.animation.Drawable
      extended byciips.animation.Legend
All Implemented Interfaces:
DrawingObj

public class Legend
extends Drawable

This is just another example implementation of the DrawingObj interface. It creates a small Legend describing the color code used in the drawing panel. This class has to be modified for different application. The draw method has to be re-implemented to reflex a particular application. This drawing object can be added to the drawing panel by:

	drawingPanel.addDrawingObj(new Legend(x, y));
 

See Also:
ComBox, IntMatrix

Field Summary
 
Fields inherited from class ciips.animation.Drawable
colour, DEFAULT_START, grey, highlight, label, x, y
 
Constructor Summary
Legend(int x, int y, java.awt.Dimension d)
          Construct a legend object on the same drawing panel with the topleft corner specified by the parameters.
 
Method Summary
 void draw(java.awt.Graphics g)
          This method draws the details of the legend object on the appropriate graphical context, normally the drawing panel.
 
Methods inherited from class ciips.animation.Drawable
getCurrentColour, getX, getY, move, setGrey, setHighlight, setText
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Legend

public Legend(int x,
              int y,
              java.awt.Dimension d)
Construct a legend object on the same drawing panel with the topleft corner specified by the parameters.

Parameters:
x - Left most position of the legend object.
y - Right most position of the legend object.
Method Detail

draw

public void draw(java.awt.Graphics g)
This method draws the details of the legend object on the appropriate graphical context, normally the drawing panel. This method has to be modified for various application.

Specified by:
draw in interface DrawingObj
Specified by:
draw in class Drawable