ca.utoronto.cs.prefuseextensions.demo
Class StarburstDemo

java.lang.Object
  extended by java.awt.Component
      extended by java.awt.Container
          extended by javax.swing.JComponent
              extended by prefuse.Display
                  extended by ca.utoronto.cs.prefuseextensions.demo.StarburstDemo
All Implemented Interfaces:
java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable

public class StarburstDemo
extends prefuse.Display

Demonstration of a radial space-filling tree viewer. Generalized fisheye filter applied, revealing only nodes of depth 1 from focus (root), selected nodes (gold), and search results (orange). Select nodes with a single click. Select multiple with ctrl-click. Deselect with ctrl-click on a selected node. Recenter graph by double clicking any node; new spanning tree is calculated and the graph will be shown centered at that node. There are some strange rendering effects, but these are documented Java2D bugs with Arc2D rendering (see notes in Sector2D class).

Version:
1.1
Author:
Christopher Collins through modification of original code by jeffrey heer
See Also:
Serialized Form

Nested Class Summary
static class StarburstDemo.NodeColorAction
          Set node fill colors
static class StarburstDemo.TextColorAction
          Set node text colors
static class StarburstDemo.TreeRootAction
          Switch the root of the tree by requesting a new spanning tree at the desired root and hiding all nodes above
 
Nested classes/interfaces inherited from class prefuse.Display
prefuse.Display.InputEventCapturer
 
Nested classes/interfaces inherited from class javax.swing.JComponent
javax.swing.JComponent.AccessibleJComponent
 
Nested classes/interfaces inherited from class java.awt.Component
java.awt.Component.BaselineResizeBehavior
 
Field Summary
static java.lang.String DATA_FILE
           
 
Fields inherited from class javax.swing.JComponent
TOOL_TIP_TEXT_KEY, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
 
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
StarburstDemo(prefuse.data.Graph g, java.lang.String label)
           
 
Method Summary
static javax.swing.JPanel demo()
           
static javax.swing.JPanel demo(prefuse.data.Graph g, java.lang.String label)
           
static javax.swing.JPanel demo(java.lang.String datafile, java.lang.String label)
           
static void main(java.lang.String[] argv)
           
 void setAutoResize(boolean autoResize)
           
 void setFilterLevel(int level)
           
 
Methods inherited from class prefuse.Display
addControlListener, addItemBoundsListener, addPaintListener, animatePan, animatePanAbs, animatePanAndZoomTo, animatePanAndZoomToAbs, animatePanTo, animatePanToAbs, animateZoom, animateZoomAbs, clearDamage, createToolTip, damageReport, damageReport, editText, editText, editText, findItem, getAbsoluteCoordinate, getCustomToolTip, getDisplayX, getDisplayY, getFrameRate, getInverseTransform, getItemBounds, getItemBounds, getItemSorter, getOffscreenBuffer, getPredicate, getScale, getTextEditor, getTransform, getVisibleItemCount, getVisualization, invalidate, isDamageRedraw, isHighQuality, isTranformInProgress, paintComponent, paintDisplay, pan, panAbs, panTo, panToAbs, removeControlListener, removeItemBoundsListener, removePaintListener, renderImmediate, repaintImmediate, reset, rotate, rotateAbs, saveImage, setBackgroundImage, setBackgroundImage, setBounds, setCustomToolTip, setDamageRedraw, setFont, setHighQuality, setItemSorter, setPredicate, setPredicate, setSize, setSize, setTextEditor, setTransform, setVisualization, stopEditing, update, zoom, zoomAbs
 
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, getAccessibleContext, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getUIClassID, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintImmediately, paintImmediately, print, printAll, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, updateUI
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, contains, createImage, createImage, createVolatileImage, createVolatileImage, dispatchEvent, enable, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, show, show, size, toString, transferFocus, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

DATA_FILE

public static final java.lang.String DATA_FILE
See Also:
Constant Field Values
Constructor Detail

StarburstDemo

public StarburstDemo(prefuse.data.Graph g,
                     java.lang.String label)
Method Detail

setAutoResize

public void setAutoResize(boolean autoResize)

setFilterLevel

public void setFilterLevel(int level)

main

public static void main(java.lang.String[] argv)

demo

public static javax.swing.JPanel demo()

demo

public static javax.swing.JPanel demo(java.lang.String datafile,
                                      java.lang.String label)

demo

public static javax.swing.JPanel demo(prefuse.data.Graph g,
                                      java.lang.String label)