Synergy Home Page

au.edu.swin.synergy.shapes
Class BRectangle

java.lang.Object
  |
  +--au.edu.swin.synergy.plugin.diagram.BDrawable
        |
        +--au.edu.swin.synergy.shapes.BRectShape
              |
              +--au.edu.swin.synergy.shapes.BRectangle

public class BRectangle
extends BRectShape
implements BSaveable

See Also:
Serialized Form

Field Summary
static float kDefaultStrokeSize
           
static String kName
           
 
Fields inherited from class au.edu.swin.synergy.shapes.BRectShape
doFill, doOutline, fillColour, kDefaultDoFill, kDefaultDoOutline, kDefaultFillColor, kDefaultLineColor, kDefaultOutlineColor, kDefaultShapeStyle, kDefaultStrokeCap, kDefaultStrokeJoin, kDefaultStrokeLimit, kDefaultStrokePhase, kDefaultStrokeWidth, kDefaultUseFillColor, kDefaultUseOutlineColor, kKeyDoFill, kKeyDoOutline, kKeyFillColor, kKeyLineColor, kKeyOutlineColor, kKeyShapeStyle, kKeyStrokeCap, kKeyStrokeDash, kKeyStrokeJoin, kKeyStrokeLimit, kKeyStrokePhase, kKeyStrokeWidth, kKeyUseFillColor, kKeyUseOutlineColor, lineColour, lineSize, local, outlineColour, shapeStyle, sizerNum, stroke, tmpXformed, useFillColour, useOutlineColour, xformed
 
Fields inherited from class au.edu.swin.synergy.plugin.diagram.BDrawable
bounds, iconOOZ, kBackward, kDefaultName, kDefaultStatus, kEmptyFlag, kForward, kHighlightFlag, kHitBounds, kHitSizer, kKeyName, kKeyStatus, kNotHit, kSelectedFlag, kSizerCtrlPoint1, kSizerCtrlPoint2, kSizerEndArc, kSizerHalfH, kSizerHalfW, kSizerNorthEast, kSizerNorthWest, kSizerSouthEast, kSizerSouthWest, kSizerStartArc, lastFrame, name, paintCount, pos, sizerColour, statusFlag, tmpBounds
 
Constructor Summary
  BRectangle()
           
protected BRectangle(BRectangle rect)
           
  BRectangle(int x, int y, int w, int h)
           
 
Method Summary
 boolean load(BDataFile file)
          loads the rectangle from a data file
 BDrawable newInstance()
          Creates and returns a new instance of the BDrawable object
 void renderFill(Graphics2D g2)
           
 void renderShape(Graphics2D g2)
          Renders the transformed coordinates of the drawable object to a Graphics2D
 boolean save(BDataFile file)
          saves the rectangle to a data file
 
Methods inherited from class au.edu.swin.synergy.shapes.BRectShape
checkSizerHit, checkXFormBounds, copy, dragAdd, dragResize, getFillColour, getLineColour, getPropertyPanel, getStroke, getStyle, paintIcon, render, renderOutlineAndSizers, renderRect, renderRectShape, setDoFill, setFillColour, setHighlighted, setLineColour, setLocalBounds, setLocalWH, setLocalXY, setOutlineColour, setSelected, setStroke, setStyle, startAdd, startResize, stopAdd, stopResize, transform, updateBounds
 
Methods inherited from class au.edu.swin.synergy.plugin.diagram.BDrawable
checkXFormHit, contains, continueAdd, copy, delete, doPasted, dragMove, getBasicStroke, getBounds, getColour, getIconHeight, getIconWidth, getName, getPos, incPos, intersects, isDeletable, isHighlighted, isInside, isSelected, isStatusFlag, isTransformed, setFlag, setName, setPos, setPos, snapToGrid, startMove, stopMove, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

kName

public static final String kName

kDefaultStrokeSize

public static final float kDefaultStrokeSize
Constructor Detail

BRectangle

public BRectangle(int x,
                  int y,
                  int w,
                  int h)

BRectangle

public BRectangle()

BRectangle

protected BRectangle(BRectangle rect)
Method Detail

renderFill

public void renderFill(Graphics2D g2)
Overrides:
renderFill in class BRectShape

renderShape

public void renderShape(Graphics2D g2)
Renders the transformed coordinates of the drawable object to a Graphics2D
Parameters:
Graphics2D - g2 - the place to render the object to.
Overrides:
renderShape in class BRectShape

newInstance

public BDrawable newInstance()
Creates and returns a new instance of the BDrawable object
Returns:
a new instance of this BDrawable object.
Overrides:
newInstance in class BRectShape

load

public boolean load(BDataFile file)
loads the rectangle from a data file
Specified by:
load in interface BSaveable
Parameters:
file - the file to load the rectangle from
Overrides:
load in class BRectShape

save

public boolean save(BDataFile file)
saves the rectangle to a data file
Specified by:
save in interface BSaveable
Parameters:
file - the file to save the rectangle to
Overrides:
save in class BRectShape

Synergy Home Page