Variable Row Height Table
PurposeThis extension enhances the ULCTable functionality by providing a method to set the row height of each table row individually on ULCVariableRowHeightTable.
How to useInstantiate a ULCVariableRowHeightTable and set the row height on the desired rows. All row heights that are not set explicitly will have the row height value that is queried through public int getRowHeight().
ULCVariableRowHeightTable table = new ULCVariableRowHeightTable(); table.setModel(myTableModel); table.setRowHeight(0, 20); table.setRowHeight(3, 40); table.setRowHeight(7, 60);
How it is implementedThe ULCVariableRowHeightTable class provides an API for setting the row of an individual row height and delegates this call to JTable.setRowHeight(int row, int rowHeight) which has been added to the JTable API in JDK 1.3.