Change the color of one or more nodes in Jtree dynamically
问题 I have created Jtree with Root node and 4Subnodes. My problem is like this: I need to change the foreground and background color of a particular node dynamically. How can i do it? Help me with some piece of code. Thank you all in advance... 回答1: How can i do it? I'm sure that JTree tutorial contains valuable info about DefaultTreeCellRenderer, Help me with some piece of code. tons of examples here or here or here 回答2: One easy way I found was to include HTML markup in the node text. The