|
JHotDraw 7.0.9 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jhotdraw.draw.AbstractFigure
org.jhotdraw.draw.AbstractAttributedFigure
org.jhotdraw.draw.AbstractAttributedDecoratedFigure
org.jhotdraw.draw.TextFigure
org.jhotdraw.samples.net.figures.NodeFigure
public class NodeFigure
NodeFigure.
Field Summary |
---|
Fields inherited from class org.jhotdraw.draw.TextFigure |
---|
editable, origin, textLayout |
Fields inherited from class org.jhotdraw.draw.AbstractFigure |
---|
changingDepth, listenerList |
Constructor Summary | |
---|---|
NodeFigure()
Creates a new instance. |
Method Summary | |
---|---|
NodeFigure |
clone()
Returns a clone of the figure. |
java.util.Collection<Handle> |
createHandles(int detailLevel)
Creates handles used to manipulate the figure. |
Connector |
findCompatibleConnector(Connector c,
boolean isStart)
Gets a compatible connector. |
Connector |
findConnector(java.awt.geom.Point2D.Double p,
ConnectionFigure figure)
Returns the Figures connector for the specified location. |
java.util.Collection |
getConnectors(ConnectionFigure prototype)
Returns all connectors of this Figure for the specified prototype of a ConnectionFigure. |
java.awt.geom.Rectangle2D.Double |
getFigureDrawingArea()
Gets the drawing area without taking the decorator into account. |
int |
getLayer()
Gets the layer of the figure. |
protected void |
readDecorator(DOMInput in)
|
void |
setAttribute(AttributeKey key,
java.lang.Object newValue)
Sets an attribute of the figure. |
protected void |
writeDecorator(DOMOutput out)
|
Methods inherited from class org.jhotdraw.draw.TextFigure |
---|
drawFill, drawStroke, drawText, figureContains, getBounds, getFillColor, getFont, getFontSize, getInsets, getLabelFor, getPreferredSize, getTabSize, getText, getTextColor, getTextColumns, getTextLayout, getTool, getTransformRestoreData, invalidate, isEditable, isTextOverflow, read, restoreTransformTo, setBounds, setEditable, setFontSize, setText, transform, validate, write |
Methods inherited from class org.jhotdraw.draw.AbstractAttributedDecoratedFigure |
---|
contains, draw, drawDecorator, drawFigure, getDecorator, getDrawingArea, setDecorator, updateDecoratorBounds |
Methods inherited from class org.jhotdraw.draw.AbstractAttributedFigure |
---|
applyAttributesTo, getAttribute, getAttributeKey, getAttributes, getAttributesRestoreData, getStroke, getStrokeMiterLimitFactor, hasAttribute, isAttributeEnabled, readAttributes, removeAttribute, restoreAttributesTo, setAttributeEnabled, setAttributes, writeAttributes |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.jhotdraw.draw.Figure |
---|
addFigureListener, addNotify, canConnect, changed, contains, draw, findFigureInside, getActions, getAttribute, getAttributes, getAttributesRestoreData, getCursor, getDecomposition, getDrawingArea, getEndPoint, getStartPoint, getToolTipText, handleDrop, handleMouseClick, includes, isInteractive, isVisible, remap, removeFigureListener, removeNotify, requestRemove, restoreAttributesTo, setVisible, willChange |
Constructor Detail |
---|
public NodeFigure()
Method Detail |
---|
public java.util.Collection getConnectors(ConnectionFigure prototype)
Figure
This is used by connection tools and connection handles to visualize the connectors when the user is about to create a ConnectionFigure to this Figure.
getConnectors
in interface Figure
getConnectors
in class AbstractFigure
prototype
- The prototype used to create a connection or null if
unknown. This allows for specific connectors for different
connection figures.public java.util.Collection<Handle> createHandles(int detailLevel)
Figure
createHandles
in interface Figure
createHandles
in class TextFigure
detailLevel
- The detail level of the handles. Usually this is 0 for
bounding box handles and 1 for point handles.
Handle
public java.awt.geom.Rectangle2D.Double getFigureDrawingArea()
TextFigure
getFigureDrawingArea
in class TextFigure
public Connector findConnector(java.awt.geom.Point2D.Double p, ConnectionFigure figure)
AbstractFigure
findConnector
in interface Figure
findConnector
in class AbstractFigure
p
- the location of the connector.figure
- The prototype used to create a connection or null if
unknown. This allows for specific connectors for different
connection figures.ChopRectangleConnector
public Connector findCompatibleConnector(Connector c, boolean isStart)
Figure
findCompatibleConnector
in interface Figure
findCompatibleConnector
in class AbstractFigure
public NodeFigure clone()
Figure
clone
in interface Figure
clone
in class TextFigure
public int getLayer()
Figure
FigureListener.figureChanged
event to
its figure listeners.
FIXME - Replace int value by a Layer object.
getLayer
in interface Figure
getLayer
in class AbstractFigure
protected void writeDecorator(DOMOutput out) throws java.io.IOException
writeDecorator
in class AbstractAttributedDecoratedFigure
java.io.IOException
protected void readDecorator(DOMInput in) throws java.io.IOException
readDecorator
in class AbstractAttributedDecoratedFigure
java.io.IOException
public void setAttribute(AttributeKey key, java.lang.Object newValue)
AbstractAttributedFigure
setAttribute
in interface Figure
setAttribute
in class AbstractAttributedFigure
AttributeKey.basicSet(org.jhotdraw.draw.Figure, T)
|
Copyright 1996-2007 (c) JHotDraw.org. Some rights reserved. |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |