JIDE 3.5.15

com.jidesoft.plaf.basic
Class BasicGroupTableHeaderUIDelegate

java.lang.Object
  extended by com.jidesoft.plaf.TableHeaderUIDelegate
      extended by com.jidesoft.plaf.basic.BasicCellStyleTableHeaderUIDelegate
          extended by com.jidesoft.plaf.basic.BasicSortableTableHeaderUIDelegate
              extended by com.jidesoft.plaf.basic.BasicEditableTableHeaderUIDelegate
                  extended by com.jidesoft.plaf.basic.BasicAutoFilterTableHeaderUIDelegate
                      extended by com.jidesoft.plaf.basic.BasicGroupTableHeaderUIDelegate
All Implemented Interfaces:
SortListener, GroupTableHeaderUIDelegate, MouseListener, MouseMotionListener, PropertyChangeListener, EventListener, TableColumnModelListener, TableModelListener

public class BasicGroupTableHeaderUIDelegate
extends BasicAutoFilterTableHeaderUIDelegate
implements GroupTableHeaderUIDelegate

The UIDelegate class for GroupTableHeader in all L&F's.

Since:
3.1.0

Nested Class Summary
 
Nested classes/interfaces inherited from class com.jidesoft.plaf.basic.BasicAutoFilterTableHeaderUIDelegate
BasicAutoFilterTableHeaderUIDelegate.DropDownSwingWorker
 
Field Summary
 
Fields inherited from class com.jidesoft.plaf.basic.BasicAutoFilterTableHeaderUIDelegate
HIDE_POPUP_KEY
 
Fields inherited from class com.jidesoft.plaf.basic.BasicCellStyleTableHeaderUIDelegate
_header, _mouseXOffset, _rendererPane
 
Constructor Summary
BasicGroupTableHeaderUIDelegate(JTableHeader header, CellRendererPane rendererPane)
           
 
Method Summary
protected  Point calculatePopupLocation()
          calculate the popup location.
 void columnAdded(TableColumnModelEvent e)
           
 void columnMarginChanged(ChangeEvent e)
           
 void columnRemoved(TableColumnModelEvent e)
           
protected  void drawConnectionLine(Graphics g, Rectangle rect)
          Draw the connect line for the parent column
 int getActualHeaderHeight()
          Gets the height of the real header.
 int getActualModelPreferredWidth(int modelColumnIndex)
          Gets the column's preferred width.
 int getGroupColumnPreferredHeight(int groupColumnIndex)
          Gets the group column's preferred height.
 Dimension getPreferredSize(JComponent c)
          Gets the preferred size of the header.
 void mouseMoved(MouseEvent e)
           
protected  boolean mouseOverFilterButton(Point p)
          Check if the mouse point is over the filter button.
 void paint(Graphics g, JComponent c)
          Paint method to paint the entire header.
protected  void paintGroupAreaBackground(Graphics g)
          Paints the group area background.
protected  void paintGroupCell(Graphics g, Rectangle cellRect, int groupColumnIndex, Object value, boolean isSelected, boolean hasFocus)
          Paints the group column cell.
protected  void paintGroupCell(Graphics g, Rectangle cellRect, int groupColumnIndex, Object value, boolean isSelected, boolean hasFocus, boolean paintCellDecorators)
          Paints the group column cell.
 void tableChanged(TableModelEvent e)
           
 
Methods inherited from class com.jidesoft.plaf.basic.BasicAutoFilterTableHeaderUIDelegate
applyFilter, applyFilter, applyFilters, applyFilters, convertElementToString, convertElementToString, convertElementToString, createCheckBoxListChooserPanel, createCustomFilterEditor, createCustomFilterEditorDialog, createListChooserPanel, createPopupPanel, createPopupWindow, customizeList, getCurrentFilters, getFilterCellDecoratorProperties, getHeaderRenderer, getPossibleValues, hasFocus, hidePopup, isPopupVisible, mouseClicked, mouseDragged, mouseExited, paintCell, showCustomFilterEditor
 
Methods inherited from class com.jidesoft.plaf.basic.BasicEditableTableHeaderUIDelegate
mouseReleased
 
Methods inherited from class com.jidesoft.plaf.basic.BasicSortableTableHeaderUIDelegate
mouseEntered, mousePressed, propertyChange, sortChanged, sortChanging, uninstallAllListeners
 
Methods inherited from class com.jidesoft.plaf.basic.BasicCellStyleTableHeaderUIDelegate
columnMoved, columnSelectionChanged, createMarginBorder, customizePaint, customizeRendererComponent, dragColumn, getBorderInsets, getHeaderPreferredHeight, getPreferredHeight, getPreferredWidth, getResizingColumn, hasStyledLabelColumn, invalidateCache, isMouseOverPaintArea, releaseRendererComponent, resizeColumn, startResizingColumn, viewIndexForColumn
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BasicGroupTableHeaderUIDelegate

public BasicGroupTableHeaderUIDelegate(JTableHeader header,
                                       CellRendererPane rendererPane)
Method Detail

paintGroupAreaBackground

protected void paintGroupAreaBackground(Graphics g)
Paints the group area background.

Parameters:
g - the Graphics instance
Since:
3.3.0

paint

public void paint(Graphics g,
                  JComponent c)
Description copied from class: BasicSortableTableHeaderUIDelegate
Paint method to paint the entire header.

Overrides:
paint in class BasicAutoFilterTableHeaderUIDelegate
Parameters:
g - the Graphics instance
c - the component to be painted

paintGroupCell

protected void paintGroupCell(Graphics g,
                              Rectangle cellRect,
                              int groupColumnIndex,
                              Object value,
                              boolean isSelected,
                              boolean hasFocus)
Paints the group column cell.

Parameters:
g - the Graphics instance
cellRect - the cell rectangle to paint the cell
groupColumnIndex - the group column index
value - the value to paint
isSelected - the flag indicating if the cell is selected
hasFocus - the flag indicating if the cell has focus

paintGroupCell

protected void paintGroupCell(Graphics g,
                              Rectangle cellRect,
                              int groupColumnIndex,
                              Object value,
                              boolean isSelected,
                              boolean hasFocus,
                              boolean paintCellDecorators)
Paints the group column cell.

Parameters:
g - the Graphics instance
cellRect - the cell rectangle to paint the cell
groupColumnIndex - the group column index
value - the value to paint
isSelected - the flag indicating if the cell is selected
hasFocus - the flag indicating if the cell has focus
paintCellDecorators - if the cell decorators should be used as well

drawConnectionLine

protected void drawConnectionLine(Graphics g,
                                  Rectangle rect)
Draw the connect line for the parent column

Parameters:
g - the Graphics instance
rect - the rectangle of the parent column

getActualHeaderHeight

public int getActualHeaderHeight()
Gets the height of the real header.

Returns:
the height.
Since:
3.2.3

getPreferredSize

public Dimension getPreferredSize(JComponent c)
Description copied from class: BasicCellStyleTableHeaderUIDelegate
Gets the preferred size of the header.

Overrides:
getPreferredSize in class BasicCellStyleTableHeaderUIDelegate
Parameters:
c - the component
Returns:
the preferred size of the header.

getGroupColumnPreferredHeight

public int getGroupColumnPreferredHeight(int groupColumnIndex)
Description copied from interface: GroupTableHeaderUIDelegate
Gets the group column's preferred height.

Specified by:
getGroupColumnPreferredHeight in interface GroupTableHeaderUIDelegate
Parameters:
groupColumnIndex - the group column index
Returns:
the preferred height for the row.

getActualModelPreferredWidth

public int getActualModelPreferredWidth(int modelColumnIndex)
Description copied from interface: GroupTableHeaderUIDelegate
Gets the column's preferred width.

Specified by:
getActualModelPreferredWidth in interface GroupTableHeaderUIDelegate
Parameters:
modelColumnIndex - the column index in the actual model of DefaultGroupTableModel
Returns:
the preferred width of the column.

tableChanged

public void tableChanged(TableModelEvent e)
Specified by:
tableChanged in interface TableModelListener
Overrides:
tableChanged in class BasicCellStyleTableHeaderUIDelegate

columnAdded

public void columnAdded(TableColumnModelEvent e)
Specified by:
columnAdded in interface TableColumnModelListener
Overrides:
columnAdded in class BasicCellStyleTableHeaderUIDelegate

columnRemoved

public void columnRemoved(TableColumnModelEvent e)
Specified by:
columnRemoved in interface TableColumnModelListener
Overrides:
columnRemoved in class BasicCellStyleTableHeaderUIDelegate

columnMarginChanged

public void columnMarginChanged(ChangeEvent e)
Specified by:
columnMarginChanged in interface TableColumnModelListener
Overrides:
columnMarginChanged in class BasicCellStyleTableHeaderUIDelegate

mouseMoved

public void mouseMoved(MouseEvent e)
Specified by:
mouseMoved in interface MouseMotionListener
Overrides:
mouseMoved in class BasicAutoFilterTableHeaderUIDelegate

mouseOverFilterButton

protected boolean mouseOverFilterButton(Point p)
Description copied from class: BasicAutoFilterTableHeaderUIDelegate
Check if the mouse point is over the filter button.

Overrides:
mouseOverFilterButton in class BasicAutoFilterTableHeaderUIDelegate
Parameters:
p - the mouse point
Returns:
true if the mouse point is over the filter button. Otherwise false.

calculatePopupLocation

protected Point calculatePopupLocation()
Description copied from class: BasicAutoFilterTableHeaderUIDelegate
calculate the popup location.

Overrides:
calculatePopupLocation in class BasicAutoFilterTableHeaderUIDelegate
Returns:
the location of popup.

JIDE 3.5.15