JTable row resizing using ..JxLayer
Posted by Pavan Kumar on September 16, 2010
A common usecase for a JTable is to manually resize rows . One solution googled was Make JTable Resizable
It works fine with a couple of drawbacks..
- If the CellEditor gets activated on mouseMove(as in my application) the mouse events will be consumed by the editor component , and the table mouseListeners(for Dragging) will Not be notfied.
- Working around the problem of rowSelection,when resizing ..needed the underlying table to be modified.
This seemed a perfect usecase for JxLayer
- Get all MouseEvents from any component parented by the underlying Table.
- Lock the UI on MouseMove & prevent the RowSelection in the table from changing(on mousePressed).