This is what has worked for me when I couldn't get the columns in a
JTable to resize.  I don't know if it is the correct way but it works
and I have not seen any bad side effects.
 
After setting your data in the model use the method sizeColumnsToFit on
your JTable passing in a -1.  This will cause the columns to fill the
width of the table instead of leaving blank space to the right of the
columns.
JTable.sizeColumnsToFit(-1);

Hope this helps.


_______________________________________________
Advanced-swing mailing list
[EMAIL PROTECTED]
http://eos.dk/mailman/listinfo/advanced-swing

Reply via email to