Skip to main content

Displaying table data inside a JTable(Use JXLayer??).

No replies
navinkjha
Offline
Joined: 2004-12-28

I need to display read-only data expanding multiple rows and columns in a JTable. I decided to do it using popup layer, something like this:

table.setRowHeight(row, 50);
SwingUtilities.getRootPane(table).getLayeredPane().add(layerContainingTable, JLayeredPane.POPUP_LAYER);

The problem is when the main JTable scrolls the the popup layer remains stationary. I could listen to scroll events and move the popup layer accordingly. I was wondering if there is a better way to do this whole thing.

-Navin

Message was edited by: navinkjha