com.imagero.gui.flowin
Class JGuiTabbedPane

java.lang.Object
  extended byjava.awt.Component
      extended byjava.awt.Container
          extended byjavax.swing.JComponent
              extended bycom.imagero.gui.flowin.JGuiTabbedPane
All Implemented Interfaces:
java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable

public class JGuiTabbedPane
extends javax.swing.JComponent

JGuiTabbedPane is a TabbedPane implementation. Features: tabs are real JToggleButtons sort and filter tabs change tab placement with drag and drop vertical buttons for left and right tabs placement auto mnemonics full keyboard navigation: ALT + RIGHT - select right tab ALT + LEFT - select left tab CTRL + ALT + LEFT - navigate previous tab CTRL + ALT + RIGHT - navigate next tab if autoMnemonics is true then ALT + selects appropriate tab otherwise it selects next tab which starts with char CTRL + ALT + F - define filter string CTRL + ALT + S - define sort string

See Also:
Serialized Form

Nested Class Summary
 class JGuiTabbedPane.TabPanelContainer
           
 
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
static java.lang.String AUTO_MNEMONIC
           
static java.lang.String TAB_PLACEMENT
           
 
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 java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
JGuiTabbedPane()
           
JGuiTabbedPane(int tabPlacement)
           
 
Method Summary
protected  TabContainer.Tab addAction(javax.swing.AbstractAction action)
           
protected  void addImpl(java.awt.Component comp, java.lang.Object constraints, int index)
          Adds the specified component to this container at the specified index.
 void addTab(java.awt.Component c)
           
 void addTab(javax.swing.Icon icon, java.awt.Component c)
           
 void addTab(java.lang.String name, java.awt.Component c)
           
 void addTab(java.lang.String name, javax.swing.Icon icon, java.awt.Component c)
           
protected  void assignMnemonic(TabContainer.Tab tab)
           
protected  void assignMnemonics()
           
 void back()
           
protected  BasicTitleBar createTitleBar()
           
 void forward()
           
protected  InputPopup getFilterPopup()
           
 java.lang.String getFilterString()
           
protected  javax.swing.ActionMap getParentActionMap0()
           
protected  javax.swing.ActionMap getParentActionMap1()
           
protected  javax.swing.InputMap getParentInputMap0()
           
protected  javax.swing.InputMap getParentInputMap1()
           
protected  InputPopup getSortPopup()
           
 java.lang.String getSortString()
           
 TabContainer getTabPanel()
           
 int getTabPlacement()
           
 JGuiTabbedPane.TabPanelContainer getTabsContainer()
           
 BasicTitleBar getTitleBar()
           
 JGuiTabbedPaneUI getUI()
           
 java.lang.String getUIClassID()
          Returns the UIDefaults key used to look up the name of the swing.plaf.ComponentUI class that defines the look and feel for this component.
 boolean isAutoMnemonic()
           
 void paint(java.awt.Graphics g)
          Invoked by Swing to draw components.
 void selectNextTab()
           
protected  void selectNextTab(java.lang.String s)
          select next Tab which caption starts with supplied String
 void selectPreviousTab()
           
 void setAutoMnemonic(boolean autoMnemonic)
           
 void setFilterString(java.lang.String filterString)
           
 void setFilterString(java.lang.String filterString, boolean ignoreCase)
           
 void setSortString(java.lang.String s)
           
 void setTabPlacement(int tabPlacement)
           
 void setUI(JGuiTabbedPaneUI ui)
           
 void showFilterPopup()
           
 void showSortPopup()
           
 void updateUI()
          Resets the UI property to a value from the current look and feel.
 
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getAccessibleContext, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBorder, getBounds, getClientProperty, getComponentGraphics, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getGraphics, getHeight, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getPreferredSize, getPropertyChangeListeners, getPropertyChangeListeners, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isPreferredSizeSet, isRequestFocusEnabled, isValidateRoot, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, paramString, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFont, setForeground, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicySet, list, list, paintComponents, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setFocusCycleRoot, setFocusTraversalKeys, setFocusTraversalPolicy, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
 
Methods inherited from class java.awt.Component
add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enableEvents, enableInputMethods, 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, getSize, getToolkit, getTreeLock, hasFocus, imageUpdate, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFontSet, isForegroundSet, isLightweight, isShowing, isValid, isVisible, list, list, list, paintAll, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, repaint, repaint, repaint, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, toString, transferFocus, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

AUTO_MNEMONIC

public static final java.lang.String AUTO_MNEMONIC
See Also:
Constant Field Values

TAB_PLACEMENT

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

JGuiTabbedPane

public JGuiTabbedPane()

JGuiTabbedPane

public JGuiTabbedPane(int tabPlacement)
Method Detail

addAction

protected TabContainer.Tab addAction(javax.swing.AbstractAction action)

addImpl

protected void addImpl(java.awt.Component comp,
                       java.lang.Object constraints,
                       int index)
Description copied from class: java.awt.Container
Adds the specified component to this container at the specified index. This method also notifies the layout manager to add the component to this container's layout using the specified constraints object via the addLayoutComponent method. The constraints are defined by the particular layout manager being used. For example, the BorderLayout class defines five constraints: BorderLayout.NORTH, BorderLayout.SOUTH, BorderLayout.EAST, BorderLayout.WEST, and BorderLayout.CENTER.

Note that if the component already exists in this container or a child of this container, it is removed from that container before being added to this container.

This is the method to override if a program needs to track every add request to a container as all other add methods defer to this one. An overriding method should usually include a call to the superclass's version of the method:

super.addImpl(comp, constraints, index)

Parameters:
comp - the component to be added
constraints - an object expressing layout constraints for this component
index - the position in the container's list at which to insert the component, where -1 means append to the end
See Also:
Container.add(Component), Container.add(Component, int), Container.add(Component, java.lang.Object), LayoutManager, LayoutManager2

addTab

public void addTab(java.awt.Component c)

addTab

public void addTab(javax.swing.Icon icon,
                   java.awt.Component c)

addTab

public void addTab(java.lang.String name,
                   java.awt.Component c)

addTab

public void addTab(java.lang.String name,
                   javax.swing.Icon icon,
                   java.awt.Component c)

assignMnemonic

protected void assignMnemonic(TabContainer.Tab tab)

assignMnemonics

protected void assignMnemonics()

back

public void back()

createTitleBar

protected BasicTitleBar createTitleBar()

forward

public void forward()

getFilterPopup

protected InputPopup getFilterPopup()

getFilterString

public java.lang.String getFilterString()

getParentActionMap0

protected javax.swing.ActionMap getParentActionMap0()

getParentActionMap1

protected javax.swing.ActionMap getParentActionMap1()

getParentInputMap0

protected javax.swing.InputMap getParentInputMap0()

getParentInputMap1

protected javax.swing.InputMap getParentInputMap1()

getSortPopup

protected InputPopup getSortPopup()

getSortString

public java.lang.String getSortString()

getTabPanel

public TabContainer getTabPanel()

getTabPlacement

public int getTabPlacement()

getTabsContainer

public JGuiTabbedPane.TabPanelContainer getTabsContainer()

getTitleBar

public BasicTitleBar getTitleBar()

getUI

public JGuiTabbedPaneUI getUI()

getUIClassID

public java.lang.String getUIClassID()
Description copied from class: javax.swing.JComponent
Returns the UIDefaults key used to look up the name of the swing.plaf.ComponentUI class that defines the look and feel for this component. Most applications will never need to call this method. Subclasses of JComponent that support pluggable look and feel should override this method to return a UIDefaults key that maps to the ComponentUI subclass that defines their look and feel.

Returns:
the UIDefaults key for a ComponentUI subclass
See Also:
UIDefaults.getUI(javax.swing.JComponent)

isAutoMnemonic

public boolean isAutoMnemonic()

paint

public void paint(java.awt.Graphics g)
Description copied from class: javax.swing.JComponent
Invoked by Swing to draw components. Applications should not invoke paint directly, but should instead use the repaint method to schedule the component for redrawing.

This method actually delegates the work of painting to three protected methods: paintComponent, paintBorder, and paintChildren. They're called in the order listed to ensure that children appear on top of component itself. Generally speaking, the component and its children should not paint in the insets area allocated to the border. Subclasses can just override this method, as always. A subclass that just wants to specialize the UI (look and feel) delegate's paint method should just override paintComponent.

Parameters:
g - the Graphics context in which to paint
See Also:
JComponent.paintComponent(java.awt.Graphics), JComponent.paintBorder(java.awt.Graphics), JComponent.paintChildren(java.awt.Graphics), JComponent.getComponentGraphics(java.awt.Graphics), JComponent.repaint(long, int, int, int, int)

selectNextTab

public void selectNextTab()

selectNextTab

protected void selectNextTab(java.lang.String s)
select next Tab which caption starts with supplied String


selectPreviousTab

public void selectPreviousTab()

setAutoMnemonic

public void setAutoMnemonic(boolean autoMnemonic)

setFilterString

public void setFilterString(java.lang.String filterString)

setFilterString

public void setFilterString(java.lang.String filterString,
                            boolean ignoreCase)

setSortString

public void setSortString(java.lang.String s)

setTabPlacement

public void setTabPlacement(int tabPlacement)

setUI

public void setUI(JGuiTabbedPaneUI ui)

showFilterPopup

public void showFilterPopup()

showSortPopup

public void showSortPopup()

updateUI

public void updateUI()
Description copied from class: javax.swing.JComponent
Resets the UI property to a value from the current look and feel. JComponent subclasses must override this method like this:
   public void updateUI() {
      setUI((SliderUI)UIManager.getUI(this);
   }
  

See Also:
JComponent.setUI(javax.swing.plaf.ComponentUI), UIManager.getLookAndFeel(), UIManager.getUI(javax.swing.JComponent)