JHotDraw 6.0b1

org.jhotdraw.figures
Class GroupFigure

java.lang.Object
  extended by org.jhotdraw.standard.AbstractFigure
      extended by org.jhotdraw.standard.CompositeFigure
          extended by org.jhotdraw.figures.GroupFigure
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, java.util.EventListener, Figure, FigureChangeListener, Storable

public class GroupFigure
extends CompositeFigure

A Figure that groups a collection of figures.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.jhotdraw.standard.CompositeFigure
_nHighestZ, _nLowestZ, fFigures
 
Constructor Summary
GroupFigure()
           
 
Method Summary
 void basicDisplayBox(java.awt.Point origin, java.awt.Point corner)
          Sets the display box of a figure.
 boolean canConnect()
          GroupFigures cannot be connected
 FigureEnumeration decompose()
          Decomposes a figure into its parts.
 java.awt.Rectangle displayBox()
          Gets the display box.
 HandleEnumeration handles()
          Gets the handles for the GroupFigure.
 void setAttribute(FigureAttributeConstant fac, java.lang.Object object)
          Sets the attribute of the GroupFigure as well as all contained Figures.
 void setAttribute(java.lang.String name, java.lang.Object value)
          Deprecated. see setAttribute(FigureAttributeConstant,Object)
 
Methods inherited from class org.jhotdraw.standard.CompositeFigure
add, addAll, addAll, basicMoveBy, bringToFront, containsFigure, draw, draw, figureAt, figureChanged, figureCount, figureInvalidated, figureRemoved, figureRequestRemove, figureRequestUpdate, figures, figures, figuresReverse, findFigure, findFigure, findFigure, findFigureInside, findFigureInsideWithout, findFigureWithout, getFigureFromLayer, getLayer, includes, init, orphan, orphanAll, orphanAll, read, release, remove, removeAll, removeAll, removeAll, replace, sendToBack, sendToLayer, write
 
Methods inherited from class org.jhotdraw.standard.AbstractFigure
addDependendFigure, addFigureChangeListener, addToContainer, center, changed, clone, connectedTextLocator, connectionInsets, connectorAt, connectorVisibility, containsPoint, displayBox, displayBox, getAttribute, getAttribute, getDecoratedFigure, getDependendFigures, getTextHolder, getZValue, invalidate, invalidateRectangle, isEmpty, listener, moveBy, removeDependendFigure, removeFigureChangeListener, removeFromContainer, setZValue, size, visit, willChange
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GroupFigure

public GroupFigure()
Method Detail

canConnect

public boolean canConnect()
GroupFigures cannot be connected

Specified by:
canConnect in interface Figure
Overrides:
canConnect in class AbstractFigure

displayBox

public java.awt.Rectangle displayBox()
Gets the display box. The display box is defined as the union of the contained figures.

Specified by:
displayBox in interface Figure
Specified by:
displayBox in class AbstractFigure
See Also:
Figure.basicDisplayBox(java.awt.Point, java.awt.Point)

basicDisplayBox

public void basicDisplayBox(java.awt.Point origin,
                            java.awt.Point corner)
Description copied from class: AbstractFigure
Sets the display box of a figure. This is the method that subclassers override. Clients usually call displayBox.

Specified by:
basicDisplayBox in interface Figure
Specified by:
basicDisplayBox in class AbstractFigure
Parameters:
origin - the new origin
corner - the new corner
See Also:
AbstractFigure.displayBox(java.awt.Point, java.awt.Point)

decompose

public FigureEnumeration decompose()
Description copied from class: AbstractFigure
Decomposes a figure into its parts. It returns a FigureEnumeration that contains itself.

Specified by:
decompose in interface Figure
Overrides:
decompose in class AbstractFigure
Returns:
an Enumeration with itself as the only element.

handles

public HandleEnumeration handles()
Gets the handles for the GroupFigure.

Specified by:
handles in interface Figure
Specified by:
handles in class AbstractFigure
Returns:
a type-safe iterator of handles
See Also:
Handle

setAttribute

public void setAttribute(java.lang.String name,
                         java.lang.Object value)
Deprecated. see setAttribute(FigureAttributeConstant,Object)

Sets the attribute of all the contained figures.

Specified by:
setAttribute in interface Figure
Overrides:
setAttribute in class AbstractFigure

setAttribute

public void setAttribute(FigureAttributeConstant fac,
                         java.lang.Object object)
Sets the attribute of the GroupFigure as well as all contained Figures.

Specified by:
setAttribute in interface Figure
Overrides:
setAttribute in class AbstractFigure

JHotDraw 6.0b1