org.openbp.cockpit.modeler.figures.tag
Class HorizontalRotatingTagFigure

java.lang.Object
  extended by CH.ifa.draw.standard.AbstractFigure
      extended by CH.ifa.draw.standard.CompositeFigure
          extended by org.openbp.cockpit.modeler.figures.tag.AbstractTagFigure
              extended by org.openbp.cockpit.modeler.figures.tag.HorizontalRotatingTagFigure
All Implemented Interfaces:
CH.ifa.draw.framework.Figure, CH.ifa.draw.framework.FigureChangeListener, CH.ifa.draw.util.Storable, java.io.Serializable, java.lang.Cloneable, java.util.EventListener, ChildFigure, Expandable, ShadowDropper, UpdatableFigure, LayoutableTag, VisualElement, InteractionClient
Direct Known Subclasses:
SimpleTextTagFigure, SocketFigure

public class HorizontalRotatingTagFigure
extends AbstractTagFigure

Horizontally oriented tag figure that may rotate around its parent. Uses a left-right MultiplexLayouter to layout the tag contents (i. e. the tag contents will be flipped vertically if the tag is moved to the other side of its parent figure.

Author:
Stephan Moritz
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class org.openbp.cockpit.modeler.figures.tag.AbstractTagFigure
AbstractTagFigure.TagContent
 
Field Summary
 
Fields inherited from class org.openbp.cockpit.modeler.figures.tag.AbstractTagFigure
angle, content, CONTENT_DATA, CONTENT_FLOW, CONTENT_ICON, CONTENT_INTERACTION, CONTENT_STATIC, CONTENT_TEXT, CONTENT_USER1, CONTENT_USER2, contentState, currentContentState, DECO_TAGCONTENTTYPE, layouter, origin, parent, presentationFigure, shadowFigure, visualStatus
 
Fields inherited from class CH.ifa.draw.standard.CompositeFigure
_nHighestZ, _nLowestZ, fFigures
 
Fields inherited from interface org.openbp.cockpit.modeler.figures.VisualElement
VISUAL_DISPLAY_ALL, VISUAL_DND_PARTICIPANT, VISUAL_VISIBLE
 
Fields inherited from interface CH.ifa.draw.framework.Figure
POPUP_MENU
 
Constructor Summary
HorizontalRotatingTagFigure(NodeFigure parent, java.lang.Object modelObject)
          Constructor.
 
Method Summary
protected  void initTagLayouter()
          Creates the layouter for this tag.
protected  java.awt.Rectangle positionDisplayBox(java.awt.Rectangle rect)
          Positions the display box of the tag relative to its parent figure.
 
Methods inherited from class org.openbp.cockpit.modeler.figures.tag.AbstractTagFigure
addContent, addContentAt, applyContentState, basicDisplayBox, basicMoveBy, basicSetAngle, canConnect, changed, checkDecoratedContentState, compactDisplayBox, connectorAt, containsPoint, createPresentationFigure, determine2WayOrientation, determineDecoratedContentState, displayBox, dragActionTriggered, dragEnded, dragStarted, draw, findFigure, findFigureInside, getAllDropRegions, getAllImportersAt, getAngle, getCenterFigure, getCenterFigureBox, getContent, getContentFigureAt, getContentState, getDrawing, getDropRegions, getFillColor, getImportersAt, getLayouter, getNumberOfContents, getOrigin, getParent, getParentElement, getPresentationFigure, getShadow, getSubClients, getVisualStatus, handleEvent, handles, importData, initContent, initPresentationFigure, initShadow, invalidate, isVerticalOrientation, isVisible, layoutTag, moveContent, read, setAngle, setContentState, setDrawing, setFillColor, setLayouter, setOrigin, setParent, setVisible, setVisualStatus, updateFigure, updatePresentationFigure, write
 
Methods inherited from class CH.ifa.draw.standard.CompositeFigure
add, addAll, addAll, bringToFront, draw, figureAt, figureChanged, figureCount, figureInvalidated, figureRemoved, figureRequestRemove, figureRequestUpdate, figures, figures, figuresReverse, findFigure, findFigure, findFigureInsideWithout, findFigureWithout, getFigureFromLayer, getLayer, includes, init, orphan, orphanAll, orphanAll, release, remove, removeAll, removeAll, removeAll, replace, sendToBack, sendToLayer
 
Methods inherited from class CH.ifa.draw.standard.AbstractFigure
addFigureChangeListener, addToContainer, center, clone, connectedTextLocator, connectionInsets, connectorVisibility, decompose, displayBox, displayBox, getAttribute, getZValue, isEmpty, listener, moveBy, removeFigureChangeListener, removeFromContainer, setAttribute, setZValue, size, willChange
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface CH.ifa.draw.framework.FigureChangeListener
figureChanged, figureInvalidated, figureRemoved, figureRequestRemove, figureRequestUpdate
 
Methods inherited from interface CH.ifa.draw.framework.Figure
addFigureChangeListener, addToContainer, center, clone, connectedTextLocator, connectionInsets, connectorVisibility, decompose, displayBox, displayBox, figures, getAttribute, getZValue, includes, isEmpty, listener, moveBy, release, removeFigureChangeListener, removeFromContainer, setAttribute, setZValue, size, willChange
 

Constructor Detail

HorizontalRotatingTagFigure

public HorizontalRotatingTagFigure(NodeFigure parent,
                                   java.lang.Object modelObject)
Constructor.

Parameters:
parent - Parent figure
modelObject - Model object this tag represents or null
Method Detail

initTagLayouter

protected void initTagLayouter()
Creates the layouter for this tag. By default, this is a left-right MultiplexLayouter

Overrides:
initTagLayouter in class AbstractTagFigure

positionDisplayBox

protected java.awt.Rectangle positionDisplayBox(java.awt.Rectangle rect)
Positions the display box of the tag relative to its parent figure. The method will place the display box adjacent to the parent at the given rotation angle.

Overrides:
positionDisplayBox in class AbstractTagFigure
Parameters:
rect - Rectangle object that contains the size of the figure
Returns:
The new display box rectangle of the presentation figure


Copyright © 2011. All Rights Reserved.