Hi,
Just to be clear. I am including some snippets here.
This is my part of my font.properties file.
# @(#)font.properties.zh 1.7 98/01/26
#
# AWT Font default Properties for Chinese Windows
#
dialog.0=\u5b8b\u4f53,GB2312_CHARSET
dialog.1=\u9ed1\u4f53,GB2312_CHARSET
dialog.2=WingDings,SYMBOL_CHARSET,NEED_CONVERTED
dialog.3=Symbol,SYMBOL_CHARSET,NEED_CONVERTED
dialoginput.0=\u5b8b\u4f53,GB2312_CHARSET
dialoginput.1=\u9ed1\u4f53,GB2312_CHARSET
dialoginput.2=WingDings,SYMBOL_CHARSET,NEED_CONVERTED
dialoginput.3=Symbol,SYMBOL_CHARSET,NEED_CONVERTED
serif.0=\u5b8b\u4f53,GB2312_CHARSET
serif.1=\u9ed1\u4f53,GB2312_CHARSET
serif.2=WingDings,SYMBOL_CHARSET,NEED_CONVERTED
serif.3=Symbol,SYMBOL_CHARSET,NEED_CONVERTED
sansserif.0=\u5b8b\u4f53,GB2312_CHARSET
sansserif.1=\u9ed1\u4f53,GB2312_CHARSET
sansserif.2=WingDings,SYMBOL_CHARSET,NEED_CONVERTED
sansserif.3=Symbol,SYMBOL_CHARSET,NEED_CONVERTED
monospaced.0=\u5b8b\u4f53,GB2312_CHARSET
monospaced.1=\u9ed1\u4f53,GB2312_CHARSET
monospaced.2=WingDings,SYMBOL_CHARSET,NEED_CONVERTED
monospaced.3=Symbol,SYMBOL_CHARSET,NEED_CONVERTED
====================================================
I create a dialog font by using
public static final Font DIALOG_BUTTON_FONT = Font.getFont("dialog");
which should search the font.properties to find the first font available. All of those
fonts listed above are installed on my system in winnt/fonts directory.
When I try to display the words (in unicode) \u8fdb\u5165 as a label of a button, I
call
btnLogin.setFont(DIALOG_BUTTON_FONT);
btnLogin.setLabel("\u8fdb\u5165");
And, all I see in the appletviewer is "??" displayed on the button.
What am I missing?
Thanks
Patrick
-----Original Message-----
From: Derek Ngok [mailto:[EMAIL PROTECTED]
Sent: November 17, 2003 7:41 PM
To: jdjlist
Subject: [jdjlist] RE: I18n with JDK 1.1.8 within an applet
Are you sure that IE is using the JRE as the default VM? I suggest you to run the
applet in appletviewer first and make sure your settings are correct.
Derek
> -----Original Message-----
> From: Patrick Li [mailto:[EMAIL PROTECTED]
> Sent: Monday, November 17, 2003 1:36 PM
> To: jdjlist
> Subject: [jdjlist] I18n with JDK 1.1.8 within an applet
>
>
> Hi,
>
> I am trying to create a complex applet that supports Chinese
> characters.
> They are used to display messages thru Graphics.drawString() and in
> various AWT components (not swing). This is what I have done so far:
>
> - I have Added Chinese font support to IE
> - Renamed font.properties.zh to font.properties in JRE's install area
> - Used virtual font names with the java program to set font for all
> components.
> - translated properties file with Chinese characters and used
> native2ascii to convert them into unicode
>
> However, when I run the program in IE. I see squares instead
> of Chinese
> character.
>
> Could anyone tell me what else I need to do?
>
> Thanks
>
> Patrick
>
> ---
> You are currently subscribed to jdjlist as: [EMAIL PROTECTED]
> To unsubscribe send a blank email to
> [EMAIL PROTECTED]
> http://www.sys-con.com/fusetalk
> To unsubscribe from all mailing lists, click:
> http://sys-con.com/globaldelete.cfm?email=leave-jdjlist-22083X
@mailbox.sys-con.com
---
You are currently subscribed to jdjlist as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]
http://www.sys-con.com/fusetalk
To unsubscribe from all mailing lists, click:
http://sys-con.com/[EMAIL PROTECTED]
---
You are currently subscribed to jdjlist as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]
http://www.sys-con.com/fusetalk
To unsubscribe from all mailing lists, click:
http://sys-con.com/[EMAIL PROTECTED]