com.mindfusion.diagramming
Class DiagramApplet

java.lang.Object
  extended by java.awt.Component
      extended by java.awt.Container
          extended by java.awt.Panel
              extended by java.applet.Applet
                  extended by javax.swing.JApplet
                      extended by com.mindfusion.diagramming.AppletEx
                          extended by com.mindfusion.diagramming.DiagramApplet
All Implemented Interfaces:
DiagramListener, java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable, java.util.EventListener, javax.accessibility.Accessible, javax.swing.RootPaneContainer

public class DiagramApplet
extends AppletEx
implements DiagramListener

The DiagramApplet class implements a Java applet that hosts a Diagram instance inside a scroll pane.

The hosted diagram can be accessed via the getDiagram() method. The diagram view can be accessed through the getDiagramView() method.

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class javax.swing.JApplet
javax.swing.JApplet.AccessibleJApplet
 
Nested classes/interfaces inherited from class java.applet.Applet
java.applet.Applet.AccessibleApplet
 
Nested classes/interfaces inherited from class java.awt.Panel
java.awt.Panel.AccessibleAWTPanel
 
Nested classes/interfaces inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
 
Nested classes/interfaces inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy
 
Field Summary
 java.lang.Object _behaviors
           
 java.lang.Object _events
           
 java.lang.Object control
           
 boolean disabled
           
 java.lang.Object dispose
           
 boolean hasInitialized
           
 boolean hasStarted
           
 
Fields inherited from class javax.swing.JApplet
accessibleContext, rootPane, rootPaneCheckingEnabled
 
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
DiagramApplet()
          Initializes a new instance of the DiagramApplet class.
 
Method Summary
 void actionRecorded(UndoEvent e)
          Raised when an action is recorded in the undo buffer.
 void actionRecording(UndoValidationEvent e)
          A validation event raised before an action is recorded in the undo buffer.
 void actionRedone(UndoEvent e)
          Raised when an action is redone.
 void actionUndone(UndoEvent e)
          Raised when an action is undone.
 void cellClicked(CellEvent e)
          Called when a table cell is clicked.
 void cellDoubleClicked(CellEvent e)
          Raised when the user double-clicks a table's cell.
 void cellTextEdited(EditCellTextEvent e)
          Raised when the user edits the text of a table's cell.
 void cellTextEditing(CellValidationEvent e)
          A validation event that lets you prevent users from editing the text of a table's cell.
 void clicked(DiagramEvent e)
          Raised when the user clicks the diagram at a point where no items are located.
 void containerChildAdded(ContainerChildEvent e)
          Raised when a node is added to a ContainerNode, either programmatically or by the user.
 void containerChildRemoved(ContainerChildEvent e)
          Raised when a node is removed from a ContainerNode, either programmatically or by the user.
 void containerFolded(NodeEvent e)
          Raised when the user folds a container by clicking the arrow-up button in the container's caption area.
 void containerUnfolded(NodeEvent e)
          Raised when the user unfolds a container by clicking the arrow-down button in the container's caption area.
 boolean copyToClipboard()
          Copies the current selection of items to a local clipboard.
 boolean copyToClipboard(boolean groups)
          Copies the current selection of items to a local clipboard.
protected  DiagramView createDiagramView()
          Creates a new DiagramView object.
 boolean cutToClipboard()
          Cuts the currently selected items to a local clipboard.
 boolean cutToClipboard(boolean groups)
          Cuts the currently selected items to a local clipboard.
 void deserializeTag(SerializeTagEvent e)
          Raised when the tag of a diagram item must be deserialized from XML format.
 void doubleClicked(DiagramEvent e)
          Raised when the user double-clicks the diagram at a point where no items are located.
 void drawAnchorPoint(DrawAnchorPointEvent e)
          Raised when an anchor point must be custom drawn.
 void drawBackground(DiagramEvent e)
          Raised to let you custom draw the diagram background.
 void drawCell(DrawCellEvent e)
          Raised when a table's cell must be custom drawn.
 void drawForeground(DiagramEvent e)
          Raised to let you custom draw the diagram foreground.
 void drawLink(DrawLinkEvent e)
          Raised when a diagram link must be custom drawn.
 void drawNode(DrawNodeEvent e)
          Raised when a diagram node must be custom drawn.
 void enterInplaceEditMode(InPlaceEditEvent e)
          Called when entering inplace-edit mode.
 void expandButtonClicked(NodeEvent e)
          Raised when the user clicks the [±] button of a expandable node.
 Diagram getDiagram()
          Gets the Diagram whose content is displayed inside the DiagramView hosted inside this applet.
 DiagramView getDiagramView()
          Gets the DiagramView hosted inside this applet.
 boolean getHasStarted()
          Returns whether start() method has completed successfully.
 ScriptHelper getScriptHelper()
          Returns an object providing helper methods useful when accessing the JDiagram API from JavaScript.
 void groupDestroyed(GroupEvent e)
          Raised when a Group object is destroyed.
 void imageLoaded(ImageLoadedEvent e)
          Called when image download initiated with Diagram.setImageUrl completes
 void init()
          Called by the browser after creating the applet instance.
 void initializeLink(LinkEvent e)
          Raised when the user starts drawing a new link, just after the DiagramLink instance is created.
 void initializeNode(NodeEvent e)
          Raised when the user starts drawing a new node, just after the DiagramNode instance is created.
 void itemAdded(ItemEvent e)
          Raised when an item is added to the diagram, either programmatically or interactively.
 void itemRemoved(ItemEvent e)
          Raised when an item is removed from the diagram, either programmatically or interactively.
 void leaveInplaceEditMode(InPlaceEditEvent e)
          Called when an inplace edit is accepted or rejected
 void linkActivated(LinkEvent e)
          Raised when a link becomes the activeItem.
 void linkClicked(LinkEvent e)
          Raised when the user clicks a link.
 void linkCreated(LinkEvent e)
          Raised when the user draws a new link.
 void linkCreating(LinkValidationEvent e)
          A validation event raised while the user is drawing a new link.
 void linkDeactivated(LinkEvent e)
          Raised when a link is no longer the active Item.
 void linkDeleted(LinkEvent e)
          Raised when a link is deleted, either programmatically or by the user.
 void linkDeleting(LinkValidationEvent e)
          Raised when the user tries to delete a link, this event lets you cancel the operation.
 void linkDeselected(LinkEvent e)
          Raised when a link is deselected, either programmatically or by the user.
 void linkDoubleClicked(LinkEvent e)
          Raised when the user double-clicks a link.
 void linkModified(LinkEvent e)
          Raised when the user moves any control point of a link.
 void linkModifying(LinkValidationEvent e)
          A validation event raised while the user is modifying a link.
 void linkMouseEnter(LinkEvent e)
          Called when the mouse pointer enters a link.
 void linkMouseLeave(LinkEvent e)
          Called when the mouse pointer leaves a link.
 void linkRouted(LinkEvent e)
          Raised when a link is routed by the auto-routing algorithm.
 void linkSelected(LinkEvent e)
          Raised when a link is selected, either programmatically or by the user.
 void linkSelecting(LinkValidationEvent e)
          Raised when the user tries to select a link, this event lets you cancel the operation.
 void linkStartModifying(LinkValidationEvent e)
          A validation event raised when the user starts modifying a link.
 void linkTextEdited(EditLinkTextEvent e)
          Raised when the user edits the text of a link.
 void linkTextEditing(LinkValidationEvent e)
          A validation event that lets you approve or reject changes made to the text of a link.
 void loadFromString(java.lang.String data)
          Loads the diagram from a string created by saveToString(boolean).
 java.awt.Image loadImage(java.lang.String url)
          Loads an image file from the specified URL.
 void nodeActivated(NodeEvent e)
          Raised when a node becomes the active Item.
 void nodeClicked(NodeEvent e)
          Raised when the user clicks a node.
 void nodeCreated(NodeEvent e)
          Raised when the user draws a new node.
 void nodeCreating(NodeValidationEvent e)
          A validation event raised while the user is drawing a new node.
 void nodeDeactivated(NodeEvent e)
          Raised when a node is no longer the active Item.
 void nodeDeleted(NodeEvent e)
          Raised when a node is deleted, either programmatically or by the user.
 void nodeDeleting(NodeValidationEvent e)
          Raised when the user tries to delete a node, this event lets you cancel the operation.
 void nodeDeselected(NodeEvent e)
          Raised when a node is deselected, either programmatically or by the user.
 void nodeDoubleClicked(NodeEvent e)
          Raised when the user double-clicks a node.
 void nodeModified(NodeEvent e)
          Raised when the user moves or resizes a node.
 void nodeModifying(NodeValidationEvent e)
          A validation event raised while the user is moving or resizing a node.
 void nodeMouseEnter(NodeEvent e)
          Called when the mouse pointer enters a node.
 void nodeMouseLeave(NodeEvent e)
          Called when the mouse pointer leaves a node.
 void nodeSelected(NodeEvent e)
          Raised when a node is selected, either programmatically or by the user.
 void nodeSelecting(NodeValidationEvent e)
          Raised when the user tries to select a node, this event lets you cancel the operation.
 void nodeStartModifying(NodeValidationEvent e)
          A validation event raised when the user starts modifying a node.
 void nodeTextEdited(EditNodeTextEvent e)
          Raised when the user edits the text of a node.
 void nodeTextEditing(NodeValidationEvent e)
          A validation event that lets you approve or reject changes made to the text of a node.
 boolean pasteFromClipboard(float dx, float dy)
          Pastes diagram items from a local clipboard.
 boolean pasteFromClipboard(float dx, float dy, boolean unconnectedLinks)
          Pastes diagram items from a local clipboard.
 void repaint(RepaintEvent e)
          Raised when the diagram views should be repainted.
 void requestImage(java.lang.String imageUrl)
           
 java.lang.String saveToString(boolean compressed)
          Saves the diagram data into an XML string.
 void selectionMoved(java.util.EventObject e)
          Called when multiple selected items are moved.
 void selectionMoving(ValidationEvent e)
          Raised while the user is moving multiple selected items, this event lets you cancel the modification.
 void serializeTag(SerializeTagEvent e)
          Raised when the tag of a diagram item must be serialized into an XML document.
 void start()
          Called by the browser when displaying the page that contains the applet.
 void tableSectionCollapsed(RowEvent e)
          Called when a table section is collapsed
 void tableSectionExpanded(RowEvent e)
          Called when a table section is expanded
 void treeCollapsed(NodeEvent e)
          Raised when a user collapses a tree branch by clicking the [-] button of a expandable node.
 void treeExpanded(NodeEvent e)
          Raised when a user expands a tree branch by clicking the [+] button of a expandable node.
 void treeItemTextEdited(EditTreeItemTextEvent e)
           
 void validateAnchorPoint(LinkValidationEvent e)
          A validation event that lets you approve or reject connecting a link to an anchor point.
 void viewportChanged()
           
 void viewRemoved(ValidationEvent e)
          Raised when a DiagramView is detached from this diagram.
 
Methods inherited from class com.mindfusion.diagramming.AppletEx
appletLoadedCheck, runInAppletThread
 
Methods inherited from class javax.swing.JApplet
addImpl, createRootPane, getAccessibleContext, getContentPane, getGlassPane, getJMenuBar, getLayeredPane, getRootPane, isRootPaneCheckingEnabled, paramString, remove, setContentPane, setGlassPane, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, update
 
Methods inherited from class java.applet.Applet
destroy, getAppletContext, getAppletInfo, getAudioClip, getAudioClip, getCodeBase, getDocumentBase, getImage, getImage, getLocale, getParameter, getParameterInfo, isActive, newAudioClip, play, play, resize, resize, setStub, showStatus, stop
 
Methods inherited from class java.awt.Panel
addNotify
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getInsets, getLayout, getListeners, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paint, paintComponents, preferredSize, print, printComponents, processContainerEvent, processEvent, remove, removeAll, removeContainerListener, removeNotify, setComponentZOrder, setFocusCycleRoot, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusBackward, transferFocusDownCycle, validate, validateTree
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphics, getGraphicsConfiguration, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getToolkit, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, reshape, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setMinimumSize, setName, setPreferredSize, setSize, setSize, setVisible, show, show, size, toString, transferFocus, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

_behaviors

public java.lang.Object _behaviors

control

public java.lang.Object control

dispose

public java.lang.Object dispose

_events

public java.lang.Object _events

disabled

public boolean disabled

hasInitialized

public boolean hasInitialized

hasStarted

public boolean hasStarted
Constructor Detail

DiagramApplet

public DiagramApplet()
Initializes a new instance of the DiagramApplet class.

Method Detail

getDiagramView

public DiagramView getDiagramView()
Gets the DiagramView hosted inside this applet.

Returns:
A DiagramView instance.

getDiagram

public Diagram getDiagram()
Gets the Diagram whose content is displayed inside the DiagramView hosted inside this applet.

Returns:
A Diagram instance.

getScriptHelper

public ScriptHelper getScriptHelper()
Returns an object providing helper methods useful when accessing the JDiagram API from JavaScript.

Returns:
A ScriptHelper instance.

saveToString

public java.lang.String saveToString(boolean compressed)
Saves the diagram data into an XML string.

Parameters:
compressed - true to compress the string, otherwise false
Returns:
A string containing XML data representing the diagram.

loadFromString

public void loadFromString(java.lang.String data)
Loads the diagram from a string created by saveToString(boolean).

Parameters:
data - A string returned from previous invocation of saveToString(boolean).

copyToClipboard

public boolean copyToClipboard()
                        throws java.io.IOException
Copies the current selection of items to a local clipboard.

Returns:
true if items were successfully copied; otherwise, false.
Throws:
java.io.IOException

copyToClipboard

public boolean copyToClipboard(boolean groups)
                        throws java.io.IOException
Copies the current selection of items to a local clipboard.

Parameters:
groups - true to copy item groups; otherwise, false.
Returns:
true if items were successfully copied; otherwise, false.
Throws:
java.io.IOException

cutToClipboard

public boolean cutToClipboard()
                       throws java.io.IOException
Cuts the currently selected items to a local clipboard.

Returns:
true if items are successfully copied to clipboard; otherwise, false.
Throws:
java.io.IOException

cutToClipboard

public boolean cutToClipboard(boolean groups)
                       throws java.io.IOException
Cuts the currently selected items to a local clipboard.

Parameters:
groups - true to cut item groups; otherwise, false.
Returns:
true if items are successfully copied to clipboard; otherwise, false.
Throws:
java.io.IOException

pasteFromClipboard

public boolean pasteFromClipboard(float dx,
                                  float dy)
                           throws java.io.IOException
Pastes diagram items from a local clipboard.

Parameters:
dx - Horizontal offset of pasted items from their original positions.
dy - Vertical offset of pasted items from their original positions.
Throws:
java.io.IOException

pasteFromClipboard

public boolean pasteFromClipboard(float dx,
                                  float dy,
                                  boolean unconnectedLinks)
                           throws java.io.IOException
Pastes diagram items from a local clipboard.

Parameters:
dx - Horizontal offset of pasted items from their original positions.
dy - Vertical offset of pasted items from their original positions.
unconnectedLinks - true to allow pasting arrows whose origin or destination node has not been copied; otherwise, false. Default is false.
Throws:
java.io.IOException

loadImage

public java.awt.Image loadImage(java.lang.String url)
Loads an image file from the specified URL.

Parameters:
url - A String containing URL to the image file.
Returns:
An Image object.

requestImage

public void requestImage(java.lang.String imageUrl)

init

public void init()
Called by the browser after creating the applet instance.

Overrides:
init in class java.applet.Applet

start

public void start()
Called by the browser when displaying the page that contains the applet.

Overrides:
start in class java.applet.Applet

getHasStarted

public boolean getHasStarted()
Returns whether start() method has completed successfully.


createDiagramView

protected DiagramView createDiagramView()
Creates a new DiagramView object. Override this method to return a custom subclass of DiagramView if needed.

Returns:
A custom DiagramView instance.

cellClicked

public void cellClicked(CellEvent e)
Description copied from interface: DiagramListener
Called when a table cell is clicked.

Specified by:
cellClicked in interface DiagramListener
Parameters:
e - A CellEvent object providing information about the event.

nodeMouseEnter

public void nodeMouseEnter(NodeEvent e)
Description copied from interface: DiagramListener
Called when the mouse pointer enters a node. Use the setTrackPointedItem method to enable this event.

Specified by:
nodeMouseEnter in interface DiagramListener
Parameters:
e - A NodeEvent object providing information about the event.

nodeMouseLeave

public void nodeMouseLeave(NodeEvent e)
Description copied from interface: DiagramListener
Called when the mouse pointer leaves a node. Use the setTrackPointedItem method to enable this event.

Specified by:
nodeMouseLeave in interface DiagramListener
Parameters:
e - A NodeEvent object providing information about the event.

linkMouseEnter

public void linkMouseEnter(LinkEvent e)
Description copied from interface: DiagramListener
Called when the mouse pointer enters a link. Use the setTrackPointedItem method to enable this event.

Specified by:
linkMouseEnter in interface DiagramListener
Parameters:
e - A LinkEvent object providing information about the event.

linkMouseLeave

public void linkMouseLeave(LinkEvent e)
Description copied from interface: DiagramListener
Called when the mouse pointer leaves a link. Use the setTrackPointedItem method to enable this event.

Specified by:
linkMouseLeave in interface DiagramListener
Parameters:
e - A LinkEvent object providing information about the event.

repaint

public void repaint(RepaintEvent e)
Description copied from interface: DiagramListener
Raised when the diagram views should be repainted.

Specified by:
repaint in interface DiagramListener

viewportChanged

public void viewportChanged()
Specified by:
viewportChanged in interface DiagramListener

imageLoaded

public void imageLoaded(ImageLoadedEvent e)
Description copied from interface: DiagramListener
Called when image download initiated with Diagram.setImageUrl completes

Specified by:
imageLoaded in interface DiagramListener
Parameters:
e - An ImageLoadedEvent object that provides more information about the event.

deserializeTag

public void deserializeTag(SerializeTagEvent e)
Description copied from interface: DiagramListener
Raised when the tag of a diagram item must be deserialized from XML format.

Specified by:
deserializeTag in interface DiagramListener

serializeTag

public void serializeTag(SerializeTagEvent e)
Description copied from interface: DiagramListener
Raised when the tag of a diagram item must be serialized into an XML document.

Specified by:
serializeTag in interface DiagramListener

enterInplaceEditMode

public void enterInplaceEditMode(InPlaceEditEvent e)
Description copied from interface: DiagramListener
Called when entering inplace-edit mode.

Specified by:
enterInplaceEditMode in interface DiagramListener
Parameters:
e - An InPlaceEditEvent object providing information about the event.

leaveInplaceEditMode

public void leaveInplaceEditMode(InPlaceEditEvent e)
Description copied from interface: DiagramListener
Called when an inplace edit is accepted or rejected

Specified by:
leaveInplaceEditMode in interface DiagramListener
Parameters:
e - An InPlaceEditEvent object providing information about the event.

actionRecorded

public void actionRecorded(UndoEvent e)
Description copied from interface: DiagramListener
Raised when an action is recorded in the undo buffer.

Specified by:
actionRecorded in interface DiagramListener

actionRecording

public void actionRecording(UndoValidationEvent e)
Description copied from interface: DiagramListener
A validation event raised before an action is recorded in the undo buffer.

Specified by:
actionRecording in interface DiagramListener

actionRedone

public void actionRedone(UndoEvent e)
Description copied from interface: DiagramListener
Raised when an action is redone.

Specified by:
actionRedone in interface DiagramListener

actionUndone

public void actionUndone(UndoEvent e)
Description copied from interface: DiagramListener
Raised when an action is undone.

Specified by:
actionUndone in interface DiagramListener

cellDoubleClicked

public void cellDoubleClicked(CellEvent e)
Description copied from interface: DiagramListener
Raised when the user double-clicks a table's cell.

Specified by:
cellDoubleClicked in interface DiagramListener

cellTextEdited

public void cellTextEdited(EditCellTextEvent e)
Description copied from interface: DiagramListener
Raised when the user edits the text of a table's cell.

Specified by:
cellTextEdited in interface DiagramListener

cellTextEditing

public void cellTextEditing(CellValidationEvent e)
Description copied from interface: DiagramListener
A validation event that lets you prevent users from editing the text of a table's cell.

Specified by:
cellTextEditing in interface DiagramListener

clicked

public void clicked(DiagramEvent e)
Description copied from interface: DiagramListener
Raised when the user clicks the diagram at a point where no items are located.

Specified by:
clicked in interface DiagramListener

containerChildAdded

public void containerChildAdded(ContainerChildEvent e)
Description copied from interface: DiagramListener
Raised when a node is added to a ContainerNode, either programmatically or by the user.

Specified by:
containerChildAdded in interface DiagramListener

containerChildRemoved

public void containerChildRemoved(ContainerChildEvent e)
Description copied from interface: DiagramListener
Raised when a node is removed from a ContainerNode, either programmatically or by the user.

Specified by:
containerChildRemoved in interface DiagramListener

containerFolded

public void containerFolded(NodeEvent e)
Description copied from interface: DiagramListener
Raised when the user folds a container by clicking the arrow-up button in the container's caption area.

Specified by:
containerFolded in interface DiagramListener

containerUnfolded

public void containerUnfolded(NodeEvent e)
Description copied from interface: DiagramListener
Raised when the user unfolds a container by clicking the arrow-down button in the container's caption area.

Specified by:
containerUnfolded in interface DiagramListener

doubleClicked

public void doubleClicked(DiagramEvent e)
Description copied from interface: DiagramListener
Raised when the user double-clicks the diagram at a point where no items are located.

Specified by:
doubleClicked in interface DiagramListener

drawAnchorPoint

public void drawAnchorPoint(DrawAnchorPointEvent e)
Description copied from interface: DiagramListener
Raised when an anchor point must be custom drawn.

Specified by:
drawAnchorPoint in interface DiagramListener

drawBackground

public void drawBackground(DiagramEvent e)
Description copied from interface: DiagramListener
Raised to let you custom draw the diagram background.

Specified by:
drawBackground in interface DiagramListener

drawForeground

public void drawForeground(DiagramEvent e)
Description copied from interface: DiagramListener
Raised to let you custom draw the diagram foreground.

Specified by:
drawForeground in interface DiagramListener

drawCell

public void drawCell(DrawCellEvent e)
Description copied from interface: DiagramListener
Raised when a table's cell must be custom drawn.

Specified by:
drawCell in interface DiagramListener

drawLink

public void drawLink(DrawLinkEvent e)
Description copied from interface: DiagramListener
Raised when a diagram link must be custom drawn.

Specified by:
drawLink in interface DiagramListener

drawNode

public void drawNode(DrawNodeEvent e)
Description copied from interface: DiagramListener
Raised when a diagram node must be custom drawn.

Specified by:
drawNode in interface DiagramListener

expandButtonClicked

public void expandButtonClicked(NodeEvent e)
Description copied from interface: DiagramListener
Raised when the user clicks the [±] button of a expandable node.

Specified by:
expandButtonClicked in interface DiagramListener

groupDestroyed

public void groupDestroyed(GroupEvent e)
Description copied from interface: DiagramListener
Raised when a Group object is destroyed.

Specified by:
groupDestroyed in interface DiagramListener

initializeLink

public void initializeLink(LinkEvent e)
Description copied from interface: DiagramListener
Raised when the user starts drawing a new link, just after the DiagramLink instance is created.

Specified by:
initializeLink in interface DiagramListener

initializeNode

public void initializeNode(NodeEvent e)
Description copied from interface: DiagramListener
Raised when the user starts drawing a new node, just after the DiagramNode instance is created.

Specified by:
initializeNode in interface DiagramListener

itemAdded

public void itemAdded(ItemEvent e)
Description copied from interface: DiagramListener
Raised when an item is added to the diagram, either programmatically or interactively.

Specified by:
itemAdded in interface DiagramListener

itemRemoved

public void itemRemoved(ItemEvent e)
Description copied from interface: DiagramListener
Raised when an item is removed from the diagram, either programmatically or interactively.

Specified by:
itemRemoved in interface DiagramListener

linkActivated

public void linkActivated(LinkEvent e)
Description copied from interface: DiagramListener
Raised when a link becomes the activeItem.

Specified by:
linkActivated in interface DiagramListener

linkClicked

public void linkClicked(LinkEvent e)
Description copied from interface: DiagramListener
Raised when the user clicks a link.

Specified by:
linkClicked in interface DiagramListener

linkCreated

public void linkCreated(LinkEvent e)
Description copied from interface: DiagramListener
Raised when the user draws a new link.

Specified by:
linkCreated in interface DiagramListener

linkCreating

public void linkCreating(LinkValidationEvent e)
Description copied from interface: DiagramListener
A validation event raised while the user is drawing a new link.

Specified by:
linkCreating in interface DiagramListener

linkDeactivated

public void linkDeactivated(LinkEvent e)
Description copied from interface: DiagramListener
Raised when a link is no longer the active Item.

Specified by:
linkDeactivated in interface DiagramListener

linkDeleted

public void linkDeleted(LinkEvent e)
Description copied from interface: DiagramListener
Raised when a link is deleted, either programmatically or by the user.

Specified by:
linkDeleted in interface DiagramListener

linkDeleting

public void linkDeleting(LinkValidationEvent e)
Description copied from interface: DiagramListener
Raised when the user tries to delete a link, this event lets you cancel the operation.

Specified by:
linkDeleting in interface DiagramListener

linkDeselected

public void linkDeselected(LinkEvent e)
Description copied from interface: DiagramListener
Raised when a link is deselected, either programmatically or by the user.

Specified by:
linkDeselected in interface DiagramListener

linkDoubleClicked

public void linkDoubleClicked(LinkEvent e)
Description copied from interface: DiagramListener
Raised when the user double-clicks a link.

Specified by:
linkDoubleClicked in interface DiagramListener

linkModified

public void linkModified(LinkEvent e)
Description copied from interface: DiagramListener
Raised when the user moves any control point of a link.

Specified by:
linkModified in interface DiagramListener

linkModifying

public void linkModifying(LinkValidationEvent e)
Description copied from interface: DiagramListener
A validation event raised while the user is modifying a link.

Specified by:
linkModifying in interface DiagramListener

linkRouted

public void linkRouted(LinkEvent e)
Description copied from interface: DiagramListener
Raised when a link is routed by the auto-routing algorithm.

Specified by:
linkRouted in interface DiagramListener

linkSelected

public void linkSelected(LinkEvent e)
Description copied from interface: DiagramListener
Raised when a link is selected, either programmatically or by the user.

Specified by:
linkSelected in interface DiagramListener

linkSelecting

public void linkSelecting(LinkValidationEvent e)
Description copied from interface: DiagramListener
Raised when the user tries to select a link, this event lets you cancel the operation.

Specified by:
linkSelecting in interface DiagramListener

linkStartModifying

public void linkStartModifying(LinkValidationEvent e)
Description copied from interface: DiagramListener
A validation event raised when the user starts modifying a link.

Specified by:
linkStartModifying in interface DiagramListener

linkTextEdited

public void linkTextEdited(EditLinkTextEvent e)
Description copied from interface: DiagramListener
Raised when the user edits the text of a link.

Specified by:
linkTextEdited in interface DiagramListener

linkTextEditing

public void linkTextEditing(LinkValidationEvent e)
Description copied from interface: DiagramListener
A validation event that lets you approve or reject changes made to the text of a link.

Specified by:
linkTextEditing in interface DiagramListener

nodeActivated

public void nodeActivated(NodeEvent e)
Description copied from interface: DiagramListener
Raised when a node becomes the active Item.

Specified by:
nodeActivated in interface DiagramListener

nodeClicked

public void nodeClicked(NodeEvent e)
Description copied from interface: DiagramListener
Raised when the user clicks a node.

Specified by:
nodeClicked in interface DiagramListener

nodeCreated

public void nodeCreated(NodeEvent e)
Description copied from interface: DiagramListener
Raised when the user draws a new node.

Specified by:
nodeCreated in interface DiagramListener

nodeCreating

public void nodeCreating(NodeValidationEvent e)
Description copied from interface: DiagramListener
A validation event raised while the user is drawing a new node.

Specified by:
nodeCreating in interface DiagramListener

nodeDeactivated

public void nodeDeactivated(NodeEvent e)
Description copied from interface: DiagramListener
Raised when a node is no longer the active Item.

Specified by:
nodeDeactivated in interface DiagramListener

nodeDeleted

public void nodeDeleted(NodeEvent e)
Description copied from interface: DiagramListener
Raised when a node is deleted, either programmatically or by the user.

Specified by:
nodeDeleted in interface DiagramListener

nodeDeleting

public void nodeDeleting(NodeValidationEvent e)
Description copied from interface: DiagramListener
Raised when the user tries to delete a node, this event lets you cancel the operation.

Specified by:
nodeDeleting in interface DiagramListener

nodeDeselected

public void nodeDeselected(NodeEvent e)
Description copied from interface: DiagramListener
Raised when a node is deselected, either programmatically or by the user.

Specified by:
nodeDeselected in interface DiagramListener

nodeDoubleClicked

public void nodeDoubleClicked(NodeEvent e)
Description copied from interface: DiagramListener
Raised when the user double-clicks a node.

Specified by:
nodeDoubleClicked in interface DiagramListener

nodeModified

public void nodeModified(NodeEvent e)
Description copied from interface: DiagramListener
Raised when the user moves or resizes a node.

Specified by:
nodeModified in interface DiagramListener

nodeModifying

public void nodeModifying(NodeValidationEvent e)
Description copied from interface: DiagramListener
A validation event raised while the user is moving or resizing a node.

Specified by:
nodeModifying in interface DiagramListener

nodeSelected

public void nodeSelected(NodeEvent e)
Description copied from interface: DiagramListener
Raised when a node is selected, either programmatically or by the user.

Specified by:
nodeSelected in interface DiagramListener

nodeSelecting

public void nodeSelecting(NodeValidationEvent e)
Description copied from interface: DiagramListener
Raised when the user tries to select a node, this event lets you cancel the operation.

Specified by:
nodeSelecting in interface DiagramListener

nodeStartModifying

public void nodeStartModifying(NodeValidationEvent e)
Description copied from interface: DiagramListener
A validation event raised when the user starts modifying a node.

Specified by:
nodeStartModifying in interface DiagramListener

nodeTextEdited

public void nodeTextEdited(EditNodeTextEvent e)
Description copied from interface: DiagramListener
Raised when the user edits the text of a node.

Specified by:
nodeTextEdited in interface DiagramListener

nodeTextEditing

public void nodeTextEditing(NodeValidationEvent e)
Description copied from interface: DiagramListener
A validation event that lets you approve or reject changes made to the text of a node.

Specified by:
nodeTextEditing in interface DiagramListener

selectionMoved

public void selectionMoved(java.util.EventObject e)
Description copied from interface: DiagramListener
Called when multiple selected items are moved.

Specified by:
selectionMoved in interface DiagramListener
Parameters:
e - An EventObject providing information about the event.

selectionMoving

public void selectionMoving(ValidationEvent e)
Description copied from interface: DiagramListener
Raised while the user is moving multiple selected items, this event lets you cancel the modification.

Specified by:
selectionMoving in interface DiagramListener

tableSectionCollapsed

public void tableSectionCollapsed(RowEvent e)
Description copied from interface: DiagramListener
Called when a table section is collapsed

Specified by:
tableSectionCollapsed in interface DiagramListener
Parameters:
e - A RowEvent object providing information about the event.

tableSectionExpanded

public void tableSectionExpanded(RowEvent e)
Description copied from interface: DiagramListener
Called when a table section is expanded

Specified by:
tableSectionExpanded in interface DiagramListener
Parameters:
e - A RowEvent object providing information about the event.

treeCollapsed

public void treeCollapsed(NodeEvent e)
Description copied from interface: DiagramListener
Raised when a user collapses a tree branch by clicking the [-] button of a expandable node.

Specified by:
treeCollapsed in interface DiagramListener

treeExpanded

public void treeExpanded(NodeEvent e)
Description copied from interface: DiagramListener
Raised when a user expands a tree branch by clicking the [+] button of a expandable node.

Specified by:
treeExpanded in interface DiagramListener

validateAnchorPoint

public void validateAnchorPoint(LinkValidationEvent e)
Description copied from interface: DiagramListener
A validation event that lets you approve or reject connecting a link to an anchor point.

Specified by:
validateAnchorPoint in interface DiagramListener

viewRemoved

public void viewRemoved(ValidationEvent e)
Description copied from interface: DiagramListener
Raised when a DiagramView is detached from this diagram.

Specified by:
viewRemoved in interface DiagramListener

treeItemTextEdited

public void treeItemTextEdited(EditTreeItemTextEvent e)
Specified by:
treeItemTextEdited in interface DiagramListener