org.argouml.ui
Class MultiEditorPane

java.lang.Object
  |
  +--java.awt.Component
        |
        +--java.awt.Container
              |
              +--javax.swing.JComponent
                    |
                    +--javax.swing.JPanel
                          |
                          +--org.argouml.ui.MultiEditorPane
All Implemented Interfaces:
javax.accessibility.Accessible, javax.swing.event.ChangeListener, java.util.EventListener, java.awt.image.ImageObserver, java.awt.MenuContainer, java.awt.event.MouseListener, QuadrantPanel, java.io.Serializable

public class MultiEditorPane
extends javax.swing.JPanel
implements javax.swing.event.ChangeListener, java.awt.event.MouseListener, QuadrantPanel

The upper right pane in the Argo/UML user interface. It has several tabs with different kinds of "major" editors that allow the user to edit whatever is selected in the NavigatorPane.

See Also:
Serialized Form

Inner classes inherited from class javax.swing.JPanel
javax.swing.JPanel.AccessibleJPanel
 
Inner classes inherited from class javax.swing.JComponent
javax.swing.JComponent.AccessibleJComponent
 
Inner classes inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
 
Inner classes inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent
 
Field Summary
protected  org.tigris.gef.base.Editor _ed
           
protected  java.awt.Component _lastTab
           
protected  java.util.Vector _tabPanels
           
protected  javax.swing.JTabbedPane _tabs
           
protected  java.lang.Object _target
           
protected static org.apache.log4j.Category cat
           
 
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.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
 
Fields inherited from interface org.argouml.application.api.QuadrantPanel
Q_BOTTOM, Q_BOTTOM_LEFT, Q_BOTTOM_RIGHT, Q_LEFT, Q_RIGHT, Q_TOP, Q_TOP_LEFT, Q_TOP_RIGHT
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
MultiEditorPane()
           
 
Method Summary
 void addNavigationListener(NavigationListener navListener)
           
 java.util.List findPresentationsFor(java.lang.Object o, java.util.Vector diagrams)
          Returns a list with all figs for some object o on the given diagrams.
 int getIndexOfNamedTab(java.lang.String tabName)
           
 java.awt.Dimension getMinimumSize()
           
 java.awt.Dimension getPreferredSize()
           
 int getQuadrant()
           
 java.lang.Object getTarget()
           
 void mouseClicked(java.awt.event.MouseEvent me)
           
 void mouseEntered(java.awt.event.MouseEvent me)
           
 void mouseExited(java.awt.event.MouseEvent me)
           
 void mousePressed(java.awt.event.MouseEvent me)
           
 void mouseReleased(java.awt.event.MouseEvent me)
           
 void myDoubleClick(int tab)
          called when the user clicks twice on a tab.
 void mySingleClick(int tab)
          called when the user clicks once on a tab.
 void removeNavigationListener(NavigationListener navListener)
           
 void removePresentationFor(java.lang.Object obj, java.util.Vector diagrams)
          Removes all figs from all diagrams for some object obj.
 void select(java.lang.Object o)
           
 void selectNextTab()
           
 void selectTabNamed(java.lang.String tabName)
           
 void setTarget(java.lang.Object target)
          Sets the target of the multieditorpane.
 void stateChanged(javax.swing.event.ChangeEvent e)
          called when the user selects a tab, by clicking or otherwise.
 
Methods inherited from class javax.swing.JPanel
getAccessibleContext, getUIClassID, paramString, updateUI
 
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAutoscrolls, getBorder, getBounds, getClientProperty, getComponentGraphics, getConditionForKeyStroke, getDebugGraphicsOptions, getGraphics, getHeight, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getNextFocusableComponent, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getVerifyInputWhenFocusTarget, getVisibleRect, getWidth, getX, getY, grabFocus, hasFocus, hide, isDoubleBuffered, isFocusCycleRoot, isFocusTraversable, isLightweightComponent, isManagingFocus, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isPreferredSizeSet, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processFocusEvent, processKeyBinding, processKeyEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setDebugGraphicsOptions, setDoubleBuffered, setEnabled, setFont, setForeground, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getLayout, insets, invalidate, isAncestorOf, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setLayout, validate, validateTree
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, getBackground, getBounds, getColorModel, getComponentOrientation, getCursor, getDropTarget, getFont, getFontMetrics, getForeground, getGraphicsConfiguration, getInputContext, getInputMethodRequests, getLocale, getLocation, getLocationOnScreen, getName, getParent, getPeer, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, imageUpdate, inside, isDisplayable, isEnabled, isLightweight, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

cat

protected static org.apache.log4j.Category cat

_target

protected java.lang.Object _target

_tabs

protected javax.swing.JTabbedPane _tabs

_ed

protected org.tigris.gef.base.Editor _ed

_tabPanels

protected java.util.Vector _tabPanels

_lastTab

protected java.awt.Component _lastTab
Constructor Detail

MultiEditorPane

public MultiEditorPane()
Method Detail

getPreferredSize

public java.awt.Dimension getPreferredSize()
Overrides:
getPreferredSize in class javax.swing.JComponent

getMinimumSize

public java.awt.Dimension getMinimumSize()
Overrides:
getMinimumSize in class javax.swing.JComponent

setTarget

public void setTarget(java.lang.Object target)
Sets the target of the multieditorpane. The multieditorpane can have several tabs. If a tab is an instance of tabmodeltarget (that is a tab that displays model elements) that tab should display the target if the target is an ArgoDiagram.
Parameters:
target -  

getTarget

public java.lang.Object getTarget()

getIndexOfNamedTab

public int getIndexOfNamedTab(java.lang.String tabName)

selectTabNamed

public void selectTabNamed(java.lang.String tabName)

selectNextTab

public void selectNextTab()

select

public void select(java.lang.Object o)

stateChanged

public void stateChanged(javax.swing.event.ChangeEvent e)
called when the user selects a tab, by clicking or otherwise.
Specified by:
stateChanged in interface javax.swing.event.ChangeListener

mousePressed

public void mousePressed(java.awt.event.MouseEvent me)
Specified by:
mousePressed in interface java.awt.event.MouseListener

mouseReleased

public void mouseReleased(java.awt.event.MouseEvent me)
Specified by:
mouseReleased in interface java.awt.event.MouseListener

mouseEntered

public void mouseEntered(java.awt.event.MouseEvent me)
Specified by:
mouseEntered in interface java.awt.event.MouseListener

mouseExited

public void mouseExited(java.awt.event.MouseEvent me)
Specified by:
mouseExited in interface java.awt.event.MouseListener

mouseClicked

public void mouseClicked(java.awt.event.MouseEvent me)
Specified by:
mouseClicked in interface java.awt.event.MouseListener

mySingleClick

public void mySingleClick(int tab)
called when the user clicks once on a tab.

myDoubleClick

public void myDoubleClick(int tab)
called when the user clicks twice on a tab.

addNavigationListener

public void addNavigationListener(NavigationListener navListener)

removeNavigationListener

public void removeNavigationListener(NavigationListener navListener)

getQuadrant

public int getQuadrant()
Specified by:
getQuadrant in interface QuadrantPanel

removePresentationFor

public void removePresentationFor(java.lang.Object obj,
                                  java.util.Vector diagrams)
Removes all figs from all diagrams for some object obj. Does not remove the owner of the objects (does not do a call to dispose).
Parameters:
obj -  

findPresentationsFor

public java.util.List findPresentationsFor(java.lang.Object o,
                                           java.util.Vector diagrams)
Returns a list with all figs for some object o on the given diagrams.
Parameters:
o -  
diagrams -  
Returns:
List


ArgoUML (c) 1996-2002
ArgoUML Project Home
ArgoUML Cookbook