Skip to Main Content

Embedded Technologies

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Text alignment in a TextArea()

843849Nov 25 2005 — edited Nov 28 2005
Hi all,

I'm using a TextArea object to list some strings. In fact, what I need is something like a JTable, but we don't have it in AWT/CDC-PP, so the solution I found is to create a string and append it to the TextArea().

So, my problem is that the text aligment is strange. I don't know why. Below and example:

Imagine two strings:

"XXXXXXXXXXXXXXXXXXXXXX 999.99 999.99"
"YYYYYYYYYYYYYYYYYYYYYY 999.99 999.99"

When I test it with System.out.println the strings are aligned. But in my TextArea() it looks like this:

"XXXXXXXXXXXXXXXXXXXXXX 999.99 999.99"
"YYYYYYYYYYYYYYYYYYYYYY 999.99 999.99"

Why it happens ? And how can I solve it ?

Thanks !
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 26 2005
Added on Nov 25 2005
10 comments
374 views