rdonuk
rdonuk

Reputation: 3956

JTextField couldn't hold enter chars

I am copying a JTextArea's content to a JTextField and then getting the same text from JTextField and setting to JTextArea. But at last case; all text is coming in same line. Enters are missing. How can I protect the content?

Upvotes: 1

Views: 87

Answers (1)

Alex Goja
Alex Goja

Reputation: 548

yourJTextArea.setLineWrap(true) I think it's what you are looking for if I understood your question correctly.

Upvotes: 1

Related Questions