How to auto-resize JTextArea according to text content?

Suppose I have a JTextArea which is added into JPopupMenu.Now, I have a problem need to be done:auto-resize the JPopupMenu when entering new line text, text exceeding the column length.Thanks;)
[221 byte] By [Joe_Kinga] at [2007-11-26 21:23:52]
# 1
http://forum.java.sun.com/thread.jspa?forumID=57&threadID=627682regards,Stas
StanislavLa at 2007-7-10 3:03:36 > top of Java-index,Desktop,Core GUI APIs...