All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class ncsa.awt.draw.TextInput

java.lang.Object
   |
   +----ncsa.awt.draw.DrawingPrimitive
           |
           +----ncsa.awt.draw.TextInput

public class TextInput
extends DrawingPrimitive
A class that implements a TextInput string DrawingPrimitive


Variable Index

 o text

Constructor Index

 o TextInput()

Method Index

 o describe()
 o drawPoints(Graphics)
Draws the TextInput string in the given graphics context
 o keyDownAction(int)
Add this key stroke to the text string
 o keyTypedAction(KeyEvent)
 o mouseDownAction(int, int)
Initializes the data structures for this primitive on mouse down
 o mouseDragAction(int, int)
Updates the data structures for this primitive during a mouse drag
 o mouseUpAction(int, int)
Updates the data structures for this primitive during a mouse up
 o move(Point, int, int)
Move this primitive from the current location to a new (x,y)
 o setBoundingBox(Graphics, Vector)
Set the bounding box for this primitive.
 o setBoundingBox(Vector)
Initialize a bounding_box which contains this set of points

Variables

 o text
 protected String text

Constructors

 o TextInput
 public TextInput()

Methods

 o drawPoints
 public void drawPoints(Graphics g)
Draws the TextInput string in the given graphics context

Parameters:
g - the graphics context
Overrides:
drawPoints in class DrawingPrimitive
 o setBoundingBox
 public void setBoundingBox(Vector pnts)
Initialize a bounding_box which contains this set of points

Overrides:
setBoundingBox in class DrawingPrimitive
 o setBoundingBox
 public void setBoundingBox(Graphics g,
                            Vector pnts)
Set the bounding box for this primitive. The Graphics context is required to obtain the FontMetrics for this DrawingPrimitive.

Parameters:
g - the graphics context
pnts - the vector containing the DrawingPrimitive location
 o mouseDownAction
 public void mouseDownAction(int x,
                             int y)
Initializes the data structures for this primitive on mouse down

Parameters:
x - the x coordinate
y - the y coordinate
Overrides:
mouseDownAction in class DrawingPrimitive
 o mouseDragAction
 public void mouseDragAction(int x,
                             int y)
Updates the data structures for this primitive during a mouse drag

Parameters:
x - the x coordinate
y - the y coordinate
Overrides:
mouseDragAction in class DrawingPrimitive
 o mouseUpAction
 public void mouseUpAction(int x,
                           int y)
Updates the data structures for this primitive during a mouse up

Parameters:
x - the x coordinate
y - the y coordinate
Overrides:
mouseUpAction in class DrawingPrimitive
 o move
 public void move(Point start,
                  int x,
                  int y)
Move this primitive from the current location to a new (x,y)

Parameters:
start - the reference Point at which this move started
x - the x coordinate
y - the y coordinate
Overrides:
move in class DrawingPrimitive
 o keyDownAction
 public void keyDownAction(int key)
Add this key stroke to the text string

Overrides:
keyDownAction in class DrawingPrimitive
 o keyTypedAction
 public void keyTypedAction(KeyEvent e)
 o describe
 public String describe()
Returns:
a string describing this text
Overrides:
describe in class DrawingPrimitive

All Packages  Class Hierarchy  This Package  Previous  Next  Index