Search in sources :

Example 1 with DateCellEditor

use of dr.app.gui.table.DateCellEditor in project beast-mcmc by beast-dev.

the class TaxonSetPanel method initTableColumn.

protected void initTableColumn() {
    tableColumnModel = taxonSetsTable.getColumnModel();
    TableColumn tableColumn = tableColumnModel.getColumn(0);
    tableColumn.setCellRenderer(new TableRenderer(SwingConstants.LEFT, new Insets(0, 4, 0, 4)));
    tableColumn.setMinWidth(20);
    tableColumn = tableColumnModel.getColumn(1);
    tableColumn.setPreferredWidth(20);
    tableColumn = tableColumnModel.getColumn(2);
    tableColumn.setPreferredWidth(20);
    tableColumn = tableColumnModel.getColumn(3);
    comboBoxRenderer.putClientProperty("JComboBox.isTableCellEditor", Boolean.TRUE);
    tableColumn.setCellRenderer(comboBoxRenderer);
    tableColumn.setPreferredWidth(30);
    tableColumn = tableColumnModel.getColumn(4);
    tableColumn.setCellEditor(new DateCellEditor(true));
    tableColumn.setPreferredWidth(30);
}
Also used : TableRenderer(jam.table.TableRenderer) DateCellEditor(dr.app.gui.table.DateCellEditor) TableColumn(javax.swing.table.TableColumn)

Aggregations

DateCellEditor (dr.app.gui.table.DateCellEditor)1 TableRenderer (jam.table.TableRenderer)1 TableColumn (javax.swing.table.TableColumn)1