Hi,

I wrote some test code to see if I can display chinese character in a simple MFC dialog program.

I'm currently running in NT4.0 English version, VC++6.0. I've downloaded the "Ming" font from the HKC website. I've already installed the Visual unicode static and DLL library.

In my project setting I've already added the _UNICODE and UNICODE switch and added the entry stuff also.

I've use the Visual wizard to generate a simple dialog program. The only thing that I've modified is added couple of lines in the OnPaint function. Still it is not display the chinese character.

Hopefully, you can pinpoint the mistakes I've made. What else is missing that I need to do.

thx,
Jeff


CFont font;
VERIFY(font.CreateFont(
12, // nHeight
0, // nWidth
0, // nEscapement
0, // nOrientation
FW_NORMAL, // nWeight
FALSE, // bItalic
FALSE, // bUnderline
0, // cStrikeOut
CHINESEBIG5_CHARSET, // nCharSet
OUT_DEFAULT_PRECIS, // nOutPrecision
CLIP_DEFAULT_PRECIS, // nClipPrecision
DEFAULT_QUALITY, // nQuality
DEFAULT_PITCH, // | FF_SWISS, // nPitchAndFamily
//_T(""))); // lpszFacename
_T("Ming"))); // lpszFacename

SetFont(&font);
CPaintDC dc(this); // device context for painting
TCHAR ss[] = {0x4000, 0x5000, 0x40, 0x0000};

dc.TextOut(10, 10,ss, 2);

SetWindowText(ss);