Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

edu.stanford.genetics.treeview.karyoview
Class KaryoPanel  view KaryoPanel download KaryoPanel.java

java.lang.Object
  extended byjava.awt.Component
      extended byjava.awt.Container
          extended byjavax.swing.JComponent
              extended byjavax.swing.JPanel
                  extended byedu.stanford.genetics.treeview.DragGridPanel
                      extended byedu.stanford.genetics.treeview.karyoview.KaryoPanel
All Implemented Interfaces:
javax.accessibility.Accessible, java.awt.event.ComponentListener, java.awt.event.ContainerListener, java.util.EventListener, java.awt.event.FocusListener, java.awt.image.ImageObserver, edu.stanford.genetics.treeview.MainPanel, java.awt.MenuContainer, java.awt.event.MouseListener, java.awt.event.MouseMotionListener, java.io.Serializable

public class KaryoPanel
extends edu.stanford.genetics.treeview.DragGridPanel
implements edu.stanford.genetics.treeview.MainPanel

This class encapsulates a dendrogram view, which is the classic Eisen treeview. It uses a drag grid panel to lay out a bunch of linked visualizations of the data, a la Eisen. In addition to laying out components, it also manages the GlobalZoomMap. This is necessary since both the GTRView (gene tree) and GlobalView need to know where to lay out genes using the same map. The zoom map is managed by the ViewFrame- it represents the selected genes, and potentially forms a link between different views, only one of which is the DendroView.

Version:
$Revision: 1.19 $ $Date: 2003/09/23 17:43:47 $

Nested Class Summary
(package private)  class KaryoPanel.CoordinatesTask
           
(package private)  class KaryoPanel.TimerListener
           
 
Nested classes inherited from class javax.swing.JPanel
javax.swing.JPanel.AccessibleJPanel
 
Nested classes inherited from class javax.swing.JComponent
javax.swing.JComponent.AccessibleJComponent
 
Nested classes inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
 
Nested classes inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy
 
Field Summary
private  edu.stanford.genetics.treeview.ConfigNode configNode
           
(package private)  javax.swing.ProgressMonitor coordinatesMonitor
           
(package private)  CoordinatesSettingsPanel coordinatesPanel
           
(package private)  KaryoPanel.CoordinatesTask coordinatesTask
           
(package private)  javax.swing.Timer coordinatesTimer
           
private  Genome genome
           
private  KaryoDrawer karyoDrawer
           
private  KaryoView karyoView
           
private  boolean loaded
           
private  KaryoViewParameterPanel parameterPanel
           
private  Genome startingGenome
          store original coordinates here...
private  edu.stanford.genetics.treeview.MessagePanel statusPanel
           
private  edu.stanford.genetics.treeview.ViewFrame viewFrame
           
private  boolean windowActive
           
 
Fields inherited from class edu.stanford.genetics.treeview.DragGridPanel
 
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
 
Fields inherited from class java.awt.Container
 
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
KaryoPanel(edu.stanford.genetics.treeview.DataModel tvmodel, edu.stanford.genetics.treeview.CdtSelection cdtSelection, edu.stanford.genetics.treeview.ViewFrame vFrame, edu.stanford.genetics.treeview.ConfigNode configNode)
          Constructor for the DendroView object
 
Method Summary
 void addComponent(java.awt.Component component, java.awt.Rectangle rectangle)
          Adds a component to the DendroView
 void addView(edu.stanford.genetics.treeview.ModelView modelView, java.awt.Rectangle rectangle)
          Adds a ModelView to the KaryoPanel
 void bindConfig(edu.stanford.genetics.treeview.ConfigNode configNode)
          Setter for configNode
 edu.stanford.genetics.treeview.ConfigNode getConfigNode()
          Getter for configNode
private  edu.stanford.genetics.treeview.ConfigNode getFirst(java.lang.String name)
          always returns an instance of the node, even if it has to create it.
 Genome getGenome()
          Getter for genome
 void getGenome(edu.stanford.genetics.treeview.DataModel newModel)
           
 void getGenome(edu.stanford.genetics.treeview.FileSet fileSet)
           
 KaryoDrawer getKaryoDrawer()
          Getter for karyoDrawer
 KaryoView getKaryoView()
          Getter for karyoView
 void populateAnalysisMenu(java.awt.Menu menu)
          Add items which do some kind of analysis
 void populateExportMenu(java.awt.Menu menu)
          Add items which allow for export, if any.
 void populateSettingsMenu(java.awt.Menu menu)
          Add items related to settings
 void scrollToIndex(int i)
          ensure a particular index is visible.
 void setGenome(Genome genome)
          Setter for genome
 void setKaryoDrawer(KaryoDrawer karyoDrawer)
          Setter for karyoDrawer
 void setKaryoView(KaryoView karyoView)
          Setter for karyoView
private  void setupViews()
          This method should be called only during initial setup of the modelview It sets up the views, which are reinitialized if the model changes.
private  void setWindowActive(boolean flag)
          Sets the windowActive attribute of the DendroView object
 void showAveragingPopup()
           
 void showCoordinatesPopup()
           
 void showDisplayPopup()
           
 void syncConfig()
          This makes the persistent storage resemble the compnents, if it doesn't already.
 void useOriginal()
           
 boolean windowActive()
          Determines if window is currently active
 
Methods inherited from class edu.stanford.genetics.treeview.DragGridPanel
addComponent, componentAdded, componentHidden, componentMoved, componentRemoved, componentResized, componentShown, doLayout, focusGained, focusLost, getBorderHeight, getBorderWidth, getFocusHeight, getFocusWidth, getHeights, getMinimumHeight, getMinimumWidth, getPreferredSize, getWidths, isAdjustable, mouseClicked, mouseDragged, mouseEntered, mouseExited, mouseMoved, mousePressed, mouseReleased, paintComponent, removeComponent, setAdjustable, setBorderHeight, setBorderWidth, setFocusHeight, setFocusWidth, setHeights, setMinimumHeight, setMinimumWidth, setWidths, toString
 
Methods inherited from class javax.swing.JPanel
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI
 
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addPropertyChangeListener, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBorder, getBounds, getClientProperty, getComponentGraphics, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getGraphics, getHeight, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isPreferredSizeSet, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFont, setForeground, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalKeys, setFocusTraversalPolicy, setLayout, 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, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, 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, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, transferFocus, transferFocusBackward, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

coordinatesMonitor

javax.swing.ProgressMonitor coordinatesMonitor

coordinatesTimer

javax.swing.Timer coordinatesTimer

coordinatesTask

KaryoPanel.CoordinatesTask coordinatesTask

coordinatesPanel

CoordinatesSettingsPanel coordinatesPanel

configNode

private edu.stanford.genetics.treeview.ConfigNode configNode

viewFrame

private edu.stanford.genetics.treeview.ViewFrame viewFrame

loaded

private boolean loaded

windowActive

private boolean windowActive

startingGenome

private Genome startingGenome
store original coordinates here...


genome

private Genome genome

karyoDrawer

private KaryoDrawer karyoDrawer

karyoView

private KaryoView karyoView

parameterPanel

private KaryoViewParameterPanel parameterPanel

statusPanel

private edu.stanford.genetics.treeview.MessagePanel statusPanel
Constructor Detail

KaryoPanel

public KaryoPanel(edu.stanford.genetics.treeview.DataModel tvmodel,
                  edu.stanford.genetics.treeview.CdtSelection cdtSelection,
                  edu.stanford.genetics.treeview.ViewFrame vFrame,
                  edu.stanford.genetics.treeview.ConfigNode configNode)
Constructor for the DendroView object

Method Detail

getGenome

public void getGenome(edu.stanford.genetics.treeview.FileSet fileSet)
               throws edu.stanford.genetics.treeview.LoadException

getGenome

public void getGenome(edu.stanford.genetics.treeview.DataModel newModel)

useOriginal

public void useOriginal()

setWindowActive

private void setWindowActive(boolean flag)
Sets the windowActive attribute of the DendroView object


setupViews

private void setupViews()
This method should be called only during initial setup of the modelview It sets up the views, which are reinitialized if the model changes.


addComponent

public void addComponent(java.awt.Component component,
                         java.awt.Rectangle rectangle)
Adds a component to the DendroView


addView

public void addView(edu.stanford.genetics.treeview.ModelView modelView,
                    java.awt.Rectangle rectangle)
Adds a ModelView to the KaryoPanel


windowActive

public boolean windowActive()
Determines if window is currently active


syncConfig

public void syncConfig()
This makes the persistent storage resemble the compnents, if it doesn't already.

Specified by:
syncConfig in interface edu.stanford.genetics.treeview.MainPanel

showDisplayPopup

public void showDisplayPopup()

showCoordinatesPopup

public void showCoordinatesPopup()

showAveragingPopup

public void showAveragingPopup()

populateSettingsMenu

public void populateSettingsMenu(java.awt.Menu menu)
Add items related to settings

Specified by:
populateSettingsMenu in interface edu.stanford.genetics.treeview.MainPanel

populateAnalysisMenu

public void populateAnalysisMenu(java.awt.Menu menu)
Add items which do some kind of analysis

Specified by:
populateAnalysisMenu in interface edu.stanford.genetics.treeview.MainPanel

populateExportMenu

public void populateExportMenu(java.awt.Menu menu)
Add items which allow for export, if any.

Specified by:
populateExportMenu in interface edu.stanford.genetics.treeview.MainPanel

scrollToIndex

public void scrollToIndex(int i)
ensure a particular index is visible. Used by Find.

Specified by:
scrollToIndex in interface edu.stanford.genetics.treeview.MainPanel

bindConfig

public void bindConfig(edu.stanford.genetics.treeview.ConfigNode configNode)
Setter for configNode


getConfigNode

public edu.stanford.genetics.treeview.ConfigNode getConfigNode()
Getter for configNode

Specified by:
getConfigNode in interface edu.stanford.genetics.treeview.MainPanel

setGenome

public void setGenome(Genome genome)
Setter for genome


getGenome

public Genome getGenome()
Getter for genome


setKaryoDrawer

public void setKaryoDrawer(KaryoDrawer karyoDrawer)
Setter for karyoDrawer


getKaryoDrawer

public KaryoDrawer getKaryoDrawer()
Getter for karyoDrawer


setKaryoView

public void setKaryoView(KaryoView karyoView)
Setter for karyoView


getKaryoView

public KaryoView getKaryoView()
Getter for karyoView


getFirst

private edu.stanford.genetics.treeview.ConfigNode getFirst(java.lang.String name)
always returns an instance of the node, even if it has to create it.