Non-ASCII chars in applets?

hi,

Spent 4 hours to find a way to use non-ASCII chars in applets (buttons, textareas), but didn't make it.

Simply saying

TextFieldObj.setText("\uxxxx");

//or any equivalent obj. Ex. of \uxxxx: \u015F

doesn't work. I even went into Graphics.paint() example, but it too can paint only ASCII chars.

My hunch is that it is smt. about Character.Subset but i still can't figure out how to do it.

Please SOS,

Reshat.

[476 byte] By [safir] at [2007-9-26 2:58:55]
# 1

Hi,

I just managed to get Buttons to show Greek characters, so it appears that static buttons are fine.

However, i still face the same problem for TextField's:

TextFields work fine for IE, but in NN they sometimes convert into ASCII and sometimes give ? The same in HotJava.

So there are 2 questions in my head:

1. why can't NN use the fonts used by IE to display Non-ASCII chars?

2. What is the safest font to use for Non-ASCII chars, to cover the widest possible audience.

P.S. Java solves most cross-platform-browser problems, but the font issue still seems to be dependent on a user and his/her browser. It appears Java is not font-independent in non-ASCII context. If so, it would be nice to develop a plug-in to make sure that if the user doesn't have the font, then a Java-standardized Unicode-based font is used. Otherwise, non-ASCII world is still w/o a real Java.)

Thank you for your feedback,

Reshat.

safir at 2007-6-29 10:54:24 > top of Java-index,Desktop,I18N...
# 2

Hi Reshat,

>>So there are 2 questions in my head:

>>1. why can't NN use the fonts used by IE to display Non-ASCII chars?

>>2. What is the safest font to use for Non-ASCII chars, to cover the widest possible audience.

I can't answer 1. The differences I have to deal with running my programs under NN versus IE give me headaches.

For 2, I've had best luck with the "Arial Unicode MS" (Microsoft) font but even that is missing a lot of glyphs.

Regards,

Joe

joefk at 2007-6-29 10:54:24 > top of Java-index,Desktop,I18N...