|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.tigris.gef.presentation.Fig
org.tigris.gef.presentation.FigGroup
org.tigris.gef.presentation.FigNode
org.argouml.uml.diagram.ui.FigNodeModelElement
org.argouml.uml.diagram.static_structure.ui.FigComment
Class to display a UML comment in a diagram.
| Field Summary |
| Fields inherited from class org.argouml.uml.diagram.ui.FigNodeModelElement |
ABSTRACT, ACTIVE, invisibleAllowed, LEAF, notationProviderName, ROOT, ROWHEIGHT, SHADOW_COLOR_ALPHA, SHADOW_COLOR_VALUE, STEREOHEIGHT |
| Fields inherited from class org.tigris.gef.presentation.FigNode |
_blinkPorts, _highlight, ang135, ang225, ang315, ang45 |
| Fields inherited from class org.tigris.gef.presentation.Fig |
_allowsSaving, _context, _dashes, _dashPeriod, _dashStyle, _filled, _h, _w, _x, _y, an, annotationOwner, annotationStatus, BORDER, MIN_SIZE, plotter |
| Constructor Summary | |
FigComment()
The main constructor used for file loading. |
|
FigComment(GraphModel gm,
Object node)
Construct a new comment. |
|
| Method Summary | |
Object |
clone()
Clone this figure. |
void |
delayedVetoableChange(PropertyChangeEvent pce)
|
String |
getBody()
|
Point |
getClosestPoint(Point anotherPt)
|
Color |
getFillColor()
|
boolean |
getFilled()
|
Color |
getLineColor()
|
int |
getLineWidth()
|
Dimension |
getMinimumSize()
Get the minimum size for the note figure. |
Rectangle |
getNameBounds()
Always returns null as the FigComment does not display its name. |
boolean |
getUseTrapRect()
|
void |
keyPressed(KeyEvent ke)
|
void |
keyReleased(KeyEvent ke)
Not used, do nothing. |
void |
keyTyped(KeyEvent ke)
|
Selection |
makeSelection()
|
protected void |
modelChanged(PropertyChangeEvent mee)
This is called after any part of the UML ModelElement (the comment) has changed. |
void |
mouseClicked(MouseEvent me)
If the user double clicks on any part of this FigNode, pass it down to one of the internal Figs. |
void |
paint(Graphics g)
Overridden to paint shadows. |
String |
placeString()
Get the default text for this figure. |
void |
propertyChange(PropertyChangeEvent pve)
|
protected void |
setBoundsImpl(int px,
int py,
int w,
int h)
|
void |
setEnclosingFig(Fig encloser)
Updates the modelelement container if the fig is moved in or out another fig. |
void |
setFillColor(Color col)
|
void |
setFilled(boolean f)
|
void |
setLineColor(Color col)
|
void |
setLineWidth(int w)
|
void |
setOwner(Object own)
In ArgoUML, for every Fig, this setOwner() function may only be called twice: Once after the fig is created, with a non-null argument, and once at end-of-life of the Fig, with a null argument. |
void |
storeBody(String body)
Stores the body text in the associated model element. |
protected void |
textEdited(FigText ft)
This method is called after the user finishes editing a text field that is in the FigNodeModelElement. |
protected void |
textEditStarted(FigText ft)
This method is called when the user doubleclicked on the text field, and starts editing. |
protected void |
updateBounds()
set some new bounds. |
protected void |
updateStereotypeText()
Updates the text of the sterotype FigText. |
void |
vetoableChange(PropertyChangeEvent pce)
|
| Methods inherited from class org.tigris.gef.presentation.FigNode |
addFigEdge, bindPort, cleanUp, contains, deepHitPort, dispose, endTrans, getFigEdges, getFigEdges, getHighlight, getPortFig, getPortFigs, getPortSector, hidePorts, hitPort, hitPort, isBlinkPorts, mouseEntered, mouseExited, mousePressed, mouseReleased, paint, removeFigEdge, removePort, setBlinkPorts, setHighlight, showPorts, superTranslate, translateImpl, updateEdges |
| Methods inherited from class org.tigris.gef.presentation.FigGroup |
addFig, addFigs, deepSelect, elements, getDisplayedFigs, getExtraFrameSpace, getFigAt, getFigCount, getFigPosn, getFigs, getFont, getFontFamily, getFontSize, getPrivateData, getSubFigBounds, getTextColor, getTextFillColor, getTextFilled, hitFig, isReshapable, isRotatable, iterator, parseDynObjects, removeAll, removeFig, setExtraFrameSpace, setFigs, setFigs, setFont, setFontFamily, setFontSize, setPrivateData, setTextColor, setTextFillColor, setTextFilled |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface java.awt.event.MouseListener |
mouseEntered, mouseExited, mousePressed, mouseReleased |
| Methods inherited from interface org.argouml.cognitive.Highlightable |
getHighlight, setHighlight |
| Methods inherited from interface org.tigris.gef.di.GraphicElement |
getId, getOwner, routingRect |
| Constructor Detail |
public FigComment()
public FigComment(GraphModel gm,
Object node)
gm - the graphmodelnode - the underlying UML Comment| Method Detail |
public String placeString()
placeString in class FigNodeModelElementpublic Object clone()
clone in class FigNodeModelElementObject.clone()public void setOwner(Object own)
FigNodeModelElementHence, during the lifetime of this Fig object, the owner shall go from null to some UML object, and to null again.
setOwner in class FigNodeModelElementFig.setOwner(java.lang.Object)public void mouseClicked(MouseEvent me)
mouseClicked in interface MouseListenermouseClicked in class FigNodeModelElementMouseListener.mouseClicked(java.awt.event.MouseEvent)public void vetoableChange(PropertyChangeEvent pce)
vetoableChange in interface VetoableChangeListenervetoableChange in class FigNodeModelElementVetoableChangeListener.vetoableChange(java.beans.PropertyChangeEvent)public void delayedVetoableChange(PropertyChangeEvent pce)
delayedVetoableChange in interface DelayedVChangeListenerdelayedVetoableChange in class FigNodeModelElementDelayedVChangeListener.delayedVetoableChange(java.beans.PropertyChangeEvent)public void propertyChange(PropertyChangeEvent pve)
propertyChange in interface PropertyChangeListenerpropertyChange in class FigNodeModelElementPropertyChangeListener.propertyChange(java.beans.PropertyChangeEvent)public void keyPressed(KeyEvent ke)
keyPressed in interface KeyListenerkeyPressed in class FigNodeModelElementKeyListener.keyPressed(java.awt.event.KeyEvent)public void keyReleased(KeyEvent ke)
keyReleased in interface KeyListenerkeyReleased in class FigNodeModelElementKeyListener.keyReleased(java.awt.event.KeyEvent)public void keyTyped(KeyEvent ke)
keyTyped in interface KeyListenerkeyTyped in class FigNodeModelElementKeyListener.keyTyped(java.awt.event.KeyEvent)public Selection makeSelection()
makeSelection in class FigNodeModelElementFig.makeSelection()public void setLineColor(Color col)
Fig.setLineColor(java.awt.Color)public Color getLineColor()
Fig.getLineColor()public void setFillColor(Color col)
Fig.setFillColor(java.awt.Color)public Color getFillColor()
Fig.getFillColor()public void setFilled(boolean f)
Fig.setFilled(boolean)public boolean getFilled()
Fig.getFilled()public void setLineWidth(int w)
Fig.setLineWidth(int)public int getLineWidth()
Fig.getLineWidth()protected void textEdited(FigText ft)
FigNodeModelElement
textEdited in class FigNodeModelElementft - the FigText that has been edited and contains the new textFigNodeModelElement.textEdited(org.tigris.gef.presentation.FigText)protected void textEditStarted(FigText ft)
FigNodeModelElement
It is also possible to alter the text to be edited
already here, e.g. by adding the stereotype in front of the name,
by calling
notationProviderName.putValue("fullyHandleStereotypes",
true);, but that seems not user-friendly. See issue 3838.
textEditStarted in class FigNodeModelElementft - the FigText that will be edited and contains the start-textFigNodeModelElement.textEditStarted(org.tigris.gef.presentation.FigText)public void setEnclosingFig(Fig encloser)
FigNodeModelElement
setEnclosingFig in class FigNodeModelElementFig.setEnclosingFig(org.tigris.gef.presentation.Fig)public final void storeBody(String body)
body - The body text to store.public boolean getUseTrapRect()
Fig.getUseTrapRect()public Rectangle getNameBounds()
getNameBounds in class FigNodeModelElementpublic Dimension getMinimumSize()
protected void setBoundsImpl(int px,
int py,
int w,
int h)
Fig.setBounds(int, int, int, int)protected void updateBounds()
FigNodeModelElement
updateBounds in class FigNodeModelElementFigNodeModelElement.updateBounds()protected final void modelChanged(PropertyChangeEvent mee)
modelChanged in class FigNodeModelElementmee - the ModelElementEvent that caused the changeFigNodeModelElement.modelChanged(java.beans.PropertyChangeEvent)protected void updateStereotypeText()
FigNodeModelElement
updateStereotypeText in class FigNodeModelElementFigNodeModelElement.updateStereotypeText()public String getBody()
public Point getClosestPoint(Point anotherPt)
Fig.getClosestPoint(java.awt.Point)public void paint(Graphics g)
FigNodeModelElementTODO: If g is not a Graphics2D shadows cannot be painted. This is a problem when saving the diagram as SVG.
paint in class FigNodeModelElementg - is a Graphics that we paint this object on.Fig.paint(java.awt.Graphics)
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
| ArgoUML © 1996-2006 | ArgoUML Homepage | ArgoUML Developers' page | ArgoUML Cookbook |