Skip to main content

How to autofit the row height

1 reply [Last post]
henry_nxd
Offline
Joined: 2012-07-20

I have a jTable and need to autofit the row height of each row to text

Thank's

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
kleopatra
Offline
Joined: 2003-06-11

Have a look at TableUtilities: there's a bunch of methods to adjust table row heights to the pref height of the rendering component. To use, trigger ´the appropriate method in a TableModelListener, wrapped into an invokeLater to be sure its done after table's internal update

Cheers
Jeanette