uchicago.src.sim.gui
Class OvalItem

java.lang.Object
  extended by uchicago.src.sim.gui.DrawableItem
      extended by uchicago.src.sim.gui.OvalItem
All Implemented Interfaces:
NonGridDrawable
Direct Known Subclasses:
OvalNetworkItem, OvalNode

public abstract class OvalItem
extends DrawableItem

An oval shaped DrawableItem.

Version:
$Revision: 1.7 $ $Date: 2004/11/03 19:50:59 $
Author:
Nick Collier
See Also:
DrawableItem

Field Summary
protected  boolean recalcBorder
           
 
Fields inherited from class uchicago.src.sim.gui.DrawableItem
allowResizing, borderColor, borderWidth, color, font, height, hollow, label, labelColor, recalc, stroke, width
 
Constructor Summary
OvalItem()
           
 
Method Summary
 void calcSize(SimGraphics g)
          Calcuates the true size in pixels of this object, including the border.
 boolean contains(java.awt.Point p)
          Does this OvalItem contain the specified point (using screen coordinates).
 void draw(SimGraphics g)
          Draws this OvalItem.
 
Methods inherited from class uchicago.src.sim.gui.DrawableItem
allowResizing, getBorderColor, getBorderWidth, getColor, getFont, getHeight, getLabelColor, getWidth, isHollow, setBorderColor, setBorderWidth, setColor, setFont, setHeight, setHollow, setLabel, setLabelColor, setSize, setSize, setWidth
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface uchicago.src.sim.gui.NonGridDrawable
getX, getY
 

Field Detail

recalcBorder

protected boolean recalcBorder
Constructor Detail

OvalItem

public OvalItem()
Method Detail

calcSize

public void calcSize(SimGraphics g)
Calcuates the true size in pixels of this object, including the border.

Overrides:
calcSize in class DrawableItem

draw

public void draw(SimGraphics g)
Draws this OvalItem.

Parameters:
g - the graphics context to draw with.

contains

public boolean contains(java.awt.Point p)
Does this OvalItem contain the specified point (using screen coordinates).

Parameters:
p - the point to test for.
Returns:
true if this OvalItem contains the point, otherwise false