Tree whose each node contains both a checkbox and an editable textfield. How?

L

Little

Hi!

I need any help/advice/reference/anything about how to implement a
tree (using JTree) whose each node, except maybe its first layer,
contain both a checkbox and an editable text field.

Thanks!
 
J

John B. Matthews

Little said:
I need any help/advice/reference/anything about how to implement a
tree (using JTree) whose each node, except maybe its first layer,
contain both a checkbox and an editable text field.


I like org.netbeans.swing.outline.Outline. Because it's a JTable, simepl
extensions of TableCellRenderer and the RenderDataProvider interface
make it easy to customize the appearance of rows in the tree.

<http://blogs.sun.com/geertjan/entry/swing_outline_component>
<http://bits.netbeans.org/dev/javadoc/org-netbeans-swing-outline/org/netb
eans/swing/outline/Outline.html>
 
L

Little

I like org.netbeans.swing.outline.Outline. Because it's a JTable, simepl
extensions of TableCellRenderer and the RenderDataProvider interface
make it easy to customize the appearance of rows in the tree.

<http://blogs.sun.com/geertjan/entry/swing_outline_component>
<http://bits.netbeans.org/dev/javadoc/org-netbeans-swing-outline/org/netb
eans/swing/outline/Outline.html>

Hi!

Thanks for replying so quickly.
Is there a solution that doesn't involve third party jars, but only
"plain" java swing?
I guess that if someone would want to use my jar they would have to
get netbeans jars as well, right?

Thanks!
 
J

John B. Matthews

[Please do not include signature lines.]
Thanks for replying so quickly. Is there a solution that doesn't
involve third party jars, but only "plain" java swing? I guess that
if someone would want to use my jar they would have to get netbeans
jars as well, right?

No. As the article mentions, platform8/org-netbeans-swing-outline.jar,
included with NetBeans, may be used independently. License terms may be
found here:

<http://netbeans.org/about/legal/index.html>

I like the design of Outline, but numerous examples combining JTable
and JTree may be found via your preferred search engine; here's a
popular study in three parts:

<http://java.sun.com/products/jfc/tsc/articles/treetable1/>

[Please do not include signature lines.]
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,901
Latest member
Noble71S45

Latest Threads

Top