Re: 如何找出一個漢字所對應的字體
On Tue, Apr 09, 2002 at 03:16:24AM -0700, Chen sheng wrote:
> 比如說, 我用的字體是hanzigb16fs, 它的全名為:
> -isas-fangsong
> ti-medium-r-normal--16-160-72-72-c-160-gb2312.1980-0
> 我想找出"陳"字在hanzigb16fs中所對應的位置.
>
> 我用xfd查看hanzigb16fs字體,
> xfd -fn hanzigb16fs
> 發現"陳"字在hanzigb16fs中對應的一個16位字符: 0x3342.
> 請問有沒有一個現成的函數實現它, 即
> function("陳") 返回 0x3342
>
沒有,對字體的函數應該直接交給xlib 的wc或者mb處理。他們會
根據xlocale 找出相應的字符。這是正統的i18n在X上的使用。
man XmbDrawString ....
你要是非自己處理,X的國標字型使用iso-2022-cn排列。對應
euc 碼,需要每一個byte 作 &0x80.
--
hashao| 千古江山,英雄無覓,孫仲謀處。舞榭歌台,風流總被,雨打風吹去。
hashao| 斜陽草樹,尋常巷陌,人道寄奴曾住。想當年、金戈鐵馬,氣吞萬裡如虎。
--
To UNSUBSCRIBE, email to debian-chinese-gb-request@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
--
| This message was re-posted from debian-chinese-gb@lists.debian.org
| and converted from gb2312 to big5 by an automatic gateway.
--
To UNSUBSCRIBE, email to debian-chinese-big5-request@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Reply to: