JIDE 3.5.15

com.jidesoft.gantt
Class GanttChartPane<T,S extends GanttEntry<T>>

java.lang.Object
  extended by java.awt.Component
      extended by java.awt.Container
          extended by javax.swing.JComponent
              extended by javax.swing.JPanel
                  extended by com.jidesoft.swing.JideSplitPane
                      extended by com.jidesoft.gantt.GanttChartPane<T,S>
Type Parameters:
T - The type of the bases unit of the scale, for example Date or Integer.
S - The type of the GanttEntries in the model.
All Implemented Interfaces:
ComponentListener, ContainerListener, ImageObserver, MenuContainer, Serializable, EventListener, Accessible
Direct Known Subclasses:
DateGanttChartPane

public class GanttChartPane<T,S extends GanttEntry<T>>
extends JideSplitPane

GanttChartPane is a pane that contains both TreeTable and GanttChart.

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class com.jidesoft.swing.JideSplitPane
JideSplitPane.AccessibleJideSplitPane
 
Nested classes/interfaces inherited from class javax.swing.JPanel
JPanel.AccessibleJPanel
 
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
 
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
 
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
 
Field Summary
 
Fields inherited from class com.jidesoft.swing.JideSplitPane
_windowDeactivatedListener, CONTINUOUS_LAYOUT_PROPERTY, DIVIDER_SIZE_PROPERTY, GRIPPER_PROPERTY, HORIZONTAL_SPLIT, NON_CONTINUOUS_DIVIDER, ONE_TOUCH_EXPANDABLE_PROPERTY, ORIENTATION_PROPERTY, PROPERTY_DIVIDER_LOCATION, PROPERTY_HEAVYWEIGHT_COMPONENT_ENABLED, PROPORTIONAL_LAYOUT_PROPERTY, PROPORTIONS_PROPERTY, VERTICAL_SPLIT
 
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
GanttChartPane(GanttModel<T,S> ganttModel)
           
 
Method Summary
protected  GanttChart<T,S> createGanttChart(GanttModel<T,S> ganttModel)
          By default, returns a GanttChart with a DefaultPeriodConverter.
protected  JScrollPane createScrollPane(Component component)
          Creates the scroll pane for the TreeTable and the GanttChart.
protected  JComponent createTableHeaderComponent()
          To customize the panel above the table header, override this method and add your custom component with the BorderLayout.CENTER constraint for the best result.
protected  TreeTable createTreeTable(TableModel model, JComponent tableHeaderComponent)
          By default, returns a TreeTable with setFillsViewPortHeight set to true and installs the table header component with the actual table header in the enclosing scroll pane instance column header view.
protected  Component customizeScrollPane(JScrollPane scrollPane)
          Allows sub classes to customize or wrap the scroll pane of the TreeTable and GanttChart.
 GanttChart<T,S> getGanttChart()
           
 GanttModel<T,S> getGanttModel()
           
 TreeTable getTreeTable()
           
protected  void initComponent()
           
 void setGanttModel(GanttModel<T,S> ganttModel)
           
 void setRowHeight(int height)
           
 
Methods inherited from class com.jidesoft.swing.JideSplitPane
addExtraDividers, addPane, addProportion, componentAdded, componentHidden, componentMoved, componentRemoved, componentResized, componentShown, createSplitPaneDivider, doLayout, dragDividerTo, finishDraggingTo, getAccessibleContext, getDividerAt, getDividerLocation, getDividerLocations, getDividerSize, getDividerStepSize, getLeftOneTouchButtonImageIcon, getNextDividerLocation, getOrientation, getPaneAt, getPaneCount, getPreviousDividerLocation, getProportions, getRightOneTouchButtonImageIcon, indexOf, indexOfDivider, indexOfPane, insertPane, insertPane, isContinuousLayout, isDragResizable, isHeavyweightComponentEnabled, isInitiallyEven, isOneTouchExpandable, isProportionalLayout, isShowGripper, isValidateRoot, removeExtraDividers, removePane, removePane, removeProportion, resetToPreferredSizes, setContinuousLayout, setDividerLocation, setDividerLocation, setDividerLocations, setDividerSize, setDividerStepSize, setDividersVisible, setDragResizable, setHeavyweightComponentEnabled, setInitiallyEven, setLeftOneTouchButtonImageIcon, setOneTouchExpandable, setOrientation, setPaneAt, setPaneAt, setProportionalLayout, setProportions, setRightOneTouchButtonImageIcon, setShowGripper, setVisible, startDragging, updateUI
 
Methods inherited from class javax.swing.JPanel
getUI, getUIClassID, paramString, setUI
 
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, 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, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, unregisterKeyboardAction, update
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, 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, 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, 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, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, 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, toString, transferFocus, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

GanttChartPane

public GanttChartPane(GanttModel<T,S> ganttModel)
Method Detail

getGanttModel

public GanttModel<T,S> getGanttModel()

setGanttModel

public void setGanttModel(GanttModel<T,S> ganttModel)

setRowHeight

public void setRowHeight(int height)

getGanttChart

public GanttChart<T,S> getGanttChart()

getTreeTable

public TreeTable getTreeTable()

initComponent

protected void initComponent()

createScrollPane

protected JScrollPane createScrollPane(Component component)
Creates the scroll pane for the TreeTable and the GanttChart.

Parameters:
component - the component
Returns:
the scroll pane.

customizeScrollPane

protected Component customizeScrollPane(JScrollPane scrollPane)
Allows sub classes to customize or wrap the scroll pane of the TreeTable and GanttChart. For example to wrap them in a JXLayer with MouseScrollableUI.

By default, the scroll pane is just returned for the TreeTable. For the GanttChart, we will set a CornerScroller to the lower right corner of the scroll pane.

Parameters:
scrollPane - the scroll pane for the table and the chart.
Returns:
The (wrapper) scroll pane.

createTableHeaderComponent

protected JComponent createTableHeaderComponent()
To customize the panel above the table header, override this method and add your custom component with the BorderLayout.CENTER constraint for the best result.

Returns:
By default returns a JPanel with a south line border and a BorderLayout.

createTreeTable

protected TreeTable createTreeTable(TableModel model,
                                    JComponent tableHeaderComponent)
By default, returns a TreeTable with setFillsViewPortHeight set to true and installs the table header component with the actual table header in the enclosing scroll pane instance column header view.

If the table model is not wrapped in a SortableTreeTableModel, sorting is disabled.

Parameters:
model - The ITreeTableModel of the GanttModel (which should also implement TableModel) or null if the GanttModel is null.
tableHeaderComponent - A JComponent which should be placed above the table header in case the gantt chart has multiple scale tiers.
Returns:
Returns the TreeTable for GanttChartPane

createGanttChart

protected GanttChart<T,S> createGanttChart(GanttModel<T,S> ganttModel)
By default, returns a GanttChart with a DefaultPeriodConverter.

Parameters:
ganttModel - The GanttModel (can be null);
Returns:
Returns the GanttChart for the the GanttChartPane.

JIDE 3.5.15