JHotDraw 7.2

Interface DecoratedFigure

All Superinterfaces:
java.lang.Cloneable, DOMStorable, Figure, java.io.Serializable
All Known Implementing Classes:
AbstractAttributedDecoratedFigure, ImageFigure, LabelFigure, NodeFigure, TextAreaFigure, TextFigure

public interface DecoratedFigure
extends Figure

This interface is implemented by Figures that can be Decorated with another Figure.

Design pattern:
Name: Decorator.
Role: Component.
Partners: Figure as Decorator.

2.0 2008-01-10 This interface extends now the Figure interface.
1.0 January 5, 2007 Created.
Werner Randelshofer

Method Summary
 Figure getDecorator()
          Gets the decorator for this figure.
 void setDecorator(Figure newValue)
          Sets a decorator Figure, for example a visual adornment to this Figure.
Methods inherited from interface org.jhotdraw.draw.Figure
addFigureListener, addNotify, canConnect, changed, clone, contains, createHandles, draw, findCompatibleConnector, findConnector, findFigureInside, getActions, getAttribute, getAttributes, getAttributesRestoreData, getBounds, getConnectors, getCursor, getDecomposition, getDrawingArea, getEndPoint, getLayer, getPreferredSize, getStartPoint, getTool, getToolTipText, getTransformRestoreData, handleDrop, handleMouseClick, includes, isRemovable, isSelectable, isTransformable, isVisible, remap, removeFigureListener, removeNotify, requestRemove, restoreAttributesTo, restoreTransformTo, setAttribute, setBounds, transform, willChange
Methods inherited from interface org.jhotdraw.xml.DOMStorable
read, write

Method Detail


void setDecorator(Figure newValue)
Sets a decorator Figure, for example a visual adornment to this Figure. Set this to null, if no decorator is desired. The decorator uses the same logical bounds as this Figure plus AttributeKeys.DECORATOR_INSETS. The decorator does not handle events. The decorator is drawn when the figure is drawn.


Figure getDecorator()
Gets the decorator for this figure.

Copyright 1996-2009 (c) by the authors and contributors of the JHotDraw project.
Some rights reserved.