I would like to have a JTree which also displays some extra information right adjusted, just like there was an extra column, see picture below. Any hints for accomplishing something like this or similar are welcome!
+6
A:
There are some articles at Sun about producing TreeTables in Java.
I remember developing a TreeTable using the sample code as a great starting point, but these articles are 10 years old now so you may want to approach with a little caution.
If you'd like something newer there is the NetBeans Outline Component.
Dave Webb
2010-01-14 13:59:22
Thank you, didn't know about that. I'll have a look...
Ed Taylor
2010-01-14 14:00:43
They definitely are pretty old by now. I started implementing such a thing a while ago, though development was done by another one later and I don't know in what shape the codebase is. If you're interested, you can download JAMES II at http://wwwmosi.informatik.uni-rostock.de/mosi/plonesoftwarecenter.2006-03-21.4262636143/pscproject.2006-03-21.6122697558/releases and take a look at the package `james.gui.utils.treetable`. The license should permit re-use outside that project.
Joey
2010-01-14 14:07:01
I think I'll be able to put something together using this information, thanks.
Ed Taylor
2010-01-14 14:11:01
+1 for the NetBeans Outline. It is very simple to use. See this explanation: http://stackoverflow.com/questions/1436281/help-making-a-jtree-with-a-jcheckbox/1436480#1436480
akf
2010-01-14 14:16:45
+2
A:
You can achieve this kind of thing by using and configuring the JTreeTable from SwingX project.
romaintaz
2010-01-14 14:11:55
It's name is j_X_treetable and it comes without sorting: http://forums.java.net/jive/thread.jspa?messageID=484525 and without filtering: http://forums.java.net/jive/message.jspa?messageID=234613
bobndrew
2010-10-15 15:00:16