I have a custom class that extends JTree. It uses it's own custom editor and renderer. A node (DefaultMutableTreeNode) contains a JPanel. The JPanel contains a class (MyTextArea) that extends JTextArea. It's a multiline text area that wraps after 80 characters and starts with 3 lines visible. Problem: I can't get MyTextArea to add lines while the user is typing. If the amount of text being typed goes past three lines, MyTextArea won't resize to keep all the text visible. If you stop typing and close and open the node then MyTextArea is properly resized. I need this done on the fly. I've tried triggering repaints/revalidates of the JPanel, MyTextArea, the tree, and nothing seems to work. Does anyone have any ideas?
There's nothing more dangerous than a resourceful idiot. ---Dilbert