Re: New line in a JTextArea (student learning here)
- From: Farcus Pottysqirt <where_is_my_car@xxxxxxxxxx>
- Date: Mon, 29 Jan 2007 00:12:45 GMT
Sandy wrote:
Just don't forget the "\n" *newline character* at the end of every line or else you'll end up with JTA-diahrea. I made this mistake myself once and had a devil of a time trying to figure it out.
On Jan 28, 2:55 pm, Knute Johnson <nos...@xxxxxxxxxxxxxxxxxxxxxxx> wrote:
Sandy wrote:
How does one append to a JTextArea in such a way to tell it that you
want this on a new line?
Thanks.JTextArea ta = new JTextArea();
ta.append("I want a new line at the end\n");
--
Knute Johnson
email s/nospam/knute/
Thanks. Makes perfect sense, just like a console app with C or C++. (Don't know why I didn't think of that! DOH!)
Hey.... does it work different on Windows than on Unix? Is the new-line character represented differently on a different platform?
.
- Follow-Ups:
- Re: New line in a JTextArea (student learning here)
- From: Andrew Thompson
- Re: New line in a JTextArea (student learning here)
- References:
- New line in a JTextArea (student learning here)
- From: Sandy
- Re: New line in a JTextArea (student learning here)
- From: Knute Johnson
- Re: New line in a JTextArea (student learning here)
- From: Sandy
- New line in a JTextArea (student learning here)
- Prev by Date: Re: Arraylist
- Next by Date: Re: Arraylist
- Previous by thread: Re: New line in a JTextArea (student learning here)
- Next by thread: Re: New line in a JTextArea (student learning here)
- Index(es):