Example usage for javax.swing.table JTableHeader JTableHeader

List of usage examples for javax.swing.table JTableHeader JTableHeader

Introduction

In this page you can find the example usage for javax.swing.table JTableHeader JTableHeader.

Prototype

public JTableHeader() 

Source Link

Document

Constructs a JTableHeader with a default TableColumnModel.

Usage

From source file:com.emental.mindraider.ui.outline.OutlineSorterJPanel.java

protected JTableHeader createDefaultTableHeader() {
    return new JTableHeader() {
        public String getToolTipText(MouseEvent e) {
            java.awt.Point p = e.getPoint();
            int index = columnModel.getColumnIndexAtX(p.x);
            int realIndex = columnModel.getColumn(index).getModelIndex();
            return columnNames[realIndex];
        }//from  ww w  .jav a 2s . c o m

        private static final long serialVersionUID = -3219707005673982727L;
    };
}

From source file:org.openconcerto.task.TodoListPanel.java

public JComponentTableCellRenderer(Icon icon) {
    super();/*from  www.j a  v  a  2 s .c om*/
    this.icon = icon;
    this.renderer = new JTableHeader().getDefaultRenderer();
}