nanogui: Thread: how to display chracter of diff sizes


[<<] [<] Page 1 of 1 [>] [>>]
Subject: how to display chracter of diff sizes
From: ####@####.####
Date: 4 Jan 2008 09:18:53 -0000
Message-Id: <17237128.1066661199438253356.JavaMail.coremail@bj163app11.163.com>

Hi,all!
I want to display chinese in my app.I use win32 api with only HAVE_GB2312_SUPPORT setted.I add a function to display chinese using MwExtTextOut with flags MWTF_DBCS_EUCCN passed and it worked!I think it was using gb2312.c generated from hzk12!
But now I want to display chinese character of 24 or any other size and ascii chars of different sizes!How can I do that?Which fontprocs->DrawText do the font drawing work?Anyone knows that?
by the way, can anyone explain the meanings of the args in MwExtTextOut? 
Thanks a lot!
 
--

Best regards! 
   Aflar Van    



网 易 有 道 词 典 -- 全 球 最 强 大 的 免 费 英 汉 互 译 词 典 ( 只 有 2 兆 )
Subject: how to display chracter of diff sizes
From: ####@####.####
Date: 4 Jan 2008 12:56:37 -0000
Message-Id: <33403281.1190571199451368125.JavaMail.coremail@bj163app36.163.com>

Hi,all!
I want to display chinese in my app.I use win32 api with only HAVE_GB2312_SUPPORT setted.I add a function to display chinese using MwExtTextOut with flags MWTF_DBCS_EUCCN passed and it worked!I think it was using gb2312.c generated from hzk12!
But now I want to display chinese character of 24 or any other size and ascii chars of different sizes!How can I do that?Which fontprocs->DrawText do the font drawing work?Anyone knows that?
by the way, can anyone explain the meanings of the args in MwExtTextOut? 
Thanks a lot!
 
--

Best regards! 
   Aflar Van    
Subject: Re: [nanogui] how to display chracter of diff sizes
From: "Greg Haerr" ####@####.####
Date: 7 Jan 2008 00:15:33 -0000
Message-Id: <023501c850c2$5a54e610$6501a8c0@winXP>

> I want to display chinese in my app.I use win32 api with only 
> HAVE_GB2312_SUPPORT setted.I add a function to display chinese using 
> MwExtTextOut with flags MWTF_DBCS_EUCCN passed and it worked!I think it 
> was using gb2312.c generated from hzk12!

This works because microwindows converts GrText or
MwExtTextOut data from the passed MWTF_xxx input format
to the output format required by the current font.  This
conversion is done by engine/devfont.c::GdConvertEncoding().



> But now I want to display chinese character of 24 or any other size and 
> ascii chars of different sizes!How can I do that?Which fontprocs->DrawText 
> do the font drawing work?Anyone knows that?

You will have to load your own .ttf or .pcf font using
GrCreateFont or CreateFont/CreateFontIndirect, and
then MwExtTextOut to output the desired characters.

> by the way, can anyone explain the meanings of the args in MwExtTextOut?

They are the same as the standard win32 ExtTextOut, except the
last parameter, flags, is used to specify the input character
encoding, using one of the MWTF_xxx (like MWTF_DBCS_EUCCN)
character encodings.

Regards,

Greg

[<<] [<] Page 1 of 1 [>] [>>]


Powered by ezmlm-browse 0.20.