[Advanced-java] Horizontally Scroll in JTable (Wrapped by JScrollPane)

John Zukowski jaz at zukowski.net
Tue Apr 1 19:47:27 2003


---------------------- multipart/alternative attachment


setAutoResizeMode with setting of  AUTO_RESIZE_OFF



At 02:39 PM 4/1/2003 -0500, Alvin Wang wrote:

>Hi! I am writing a JTable with a lot of columns. Java will try to shrink the
>columns to display all of them. So some data will be displayed as "-12...".
>The user has to widen the column manually to see the data. It is not
>convenient. My JTable is wrapped by a JScrollPane, so I wanto let JTable
>just use whatever width it needs for each column to display the data, and
>the user can scroll horizontally. Can any gurus tell me how to do it? I
>think the main problem is how to disallow JTable from shrinking.

---------------------- multipart/alternative attachment
An HTML attachment was scrubbed...
URL: /lists/advanced-java/attachments/20030401/9a8f6048/attachment.htm

---------------------- multipart/alternative attachment--