CH.ifa.draw.figures
Class RectangleFigure
- java.lang.Object
-
- CH.ifa.draw.standard.AbstractFigure
-
- CH.ifa.draw.figures.AttributeFigure
-
- CH.ifa.draw.figures.RectangleFigure
-
- Direct Known Subclasses:
- DiamondFigure, TriangleFigure
public class RectangleFigure extends AttributeFigure
A rectangle figure.- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from interface CH.ifa.draw.framework.Figure
POPUP_MENU
-
-
Constructor Summary
Constructors Constructor and Description RectangleFigure()RectangleFigure(java.awt.Point origin, java.awt.Point corner)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description voidbasicDisplayBox(java.awt.Point origin, java.awt.Point corner)Sets the display box of a figure.java.awt.RectangledisplayBox()Gets the display box of a figure.voiddrawBackground(java.awt.Graphics g)Draws the background of the figure.voiddrawFrame(java.awt.Graphics g)Draws the frame of the figure.java.util.Vectorhandles()Returns the handles of a Figure that can be used to manipulate some of its attributes.voidread(StorableInput dr)Reads the Figure from a StorableInput.voidwrite(StorableOutput dw)Stores the Figure to a StorableOutput.-
Methods inherited from class CH.ifa.draw.figures.AttributeFigure
draw, getAttribute, getDefaultAttribute, getFillColor, getFrameColor, setAttribute
-
Methods inherited from class CH.ifa.draw.standard.AbstractFigure
addFigureChangeListener, addToContainer, canConnect, center, changed, clone, connectedTextLocator, connectionInsets, connectorAt, connectorVisibility, containsPoint, decompose, displayBox, displayBox, figures, findFigureInside, includes, invalidate, isEmpty, listener, moveBy, release, removeFigureChangeListener, removeFromContainer, size, willChange
-
-
-
-
Constructor Detail
-
RectangleFigure
public RectangleFigure()
-
RectangleFigure
public RectangleFigure(java.awt.Point origin, java.awt.Point corner)
-
-
Method Detail
-
basicDisplayBox
public void basicDisplayBox(java.awt.Point origin, java.awt.Point corner)Description copied from class:AbstractFigureSets the display box of a figure. This is the method that subclassers override. Clients usually call displayBox.- Specified by:
basicDisplayBoxin interfaceFigure- Specified by:
basicDisplayBoxin classAbstractFigure- Parameters:
origin- the new origincorner- the new corner- See Also:
AbstractFigure.displayBox(java.awt.Point, java.awt.Point)
-
handles
public java.util.Vector handles()
Description copied from class:AbstractFigureReturns the handles of a Figure that can be used to manipulate some of its attributes.- Specified by:
handlesin interfaceFigure- Specified by:
handlesin classAbstractFigure- Returns:
- a Vector of handles
- See Also:
Handle
-
displayBox
public java.awt.Rectangle displayBox()
Description copied from class:AbstractFigureGets the display box of a figure.- Specified by:
displayBoxin interfaceFigure- Specified by:
displayBoxin classAbstractFigure- See Also:
Figure.basicDisplayBox(java.awt.Point, java.awt.Point)
-
drawBackground
public void drawBackground(java.awt.Graphics g)
Description copied from class:AttributeFigureDraws the background of the figure.- See Also:
AttributeFigure.draw(java.awt.Graphics)
-
drawFrame
public void drawFrame(java.awt.Graphics g)
Description copied from class:AttributeFigureDraws the frame of the figure.- See Also:
AttributeFigure.draw(java.awt.Graphics)
-
write
public void write(StorableOutput dw)
Description copied from class:AttributeFigureStores the Figure to a StorableOutput.- Specified by:
writein interfaceStorable- Overrides:
writein classAttributeFigure
-
read
public void read(StorableInput dr) throws java.io.IOException
Description copied from class:AttributeFigureReads the Figure from a StorableInput.- Specified by:
readin interfaceStorable- Overrides:
readin classAttributeFigure- Throws:
java.io.IOException
-
-
DataMelt 3.0 © DataMelt by jWork.ORG