The Java Tutorials' Weblog
JTable: Freezing a column while scrolling the others
Have you ever needed to create a table that is too wide for the view so it requires a horitzonal scrollbar? OK, that's pretty routine. But have you then wanted one (or more) of the columns to remain fixed when you scroll the other columns?Over on the javatutorials portal Collin Fagan has posted an example that shows how to do just that. Check out Row Labels/Frozen Columns. (You'll have to scroll down through several posts to see it.)
Thanks Collin!
-- Sharon Zakhour
Posted at 02:51PM May 13, 2008 by The Java Tutorial Team | Comments[2]
Tuesday May 13, 2008
It would be nice to have frozen columns as part of the official JTable api.
This is a nice hack, but still a hack
Posted by Thierry Janaudy on May 17, 2008 at 05:21 AM PDT #
Well, I'm not saying that it's easy, but thanks to the fact that the JDK is now open (http://community.java.net/openjdk/), it's possible for anyone to contribute to the JDK. One would need to join the community, in this case the Swing project, and
participate.
Sharon
Posted by Sharon Zakhour on May 20, 2008 at 08:09 AM PDT #