Hello,

Although I have an XLC_LOCALE for Big5HKSCS that works for me at the
moment, it requires users to have a single font that includes both
standard Big5 and HKSCS extension characters.  I have been lucky to
have such a "unified" font; however I don't think it would be useful
for other people since generally HKSCS fonts are distributed 
separately from standard Big5 fonts.

I'm now working on an XLC_LOCALE that lets X use standard Big5 fonts
for "standard" characters (0xA1xx-0xF9xx), and extended fonts for
other characters.  However I don't know how to get X to distinguish
between these two character ranges.

I have attached what I have done so far; however I don't have access
to X at the moment so I can't test it.  Have a look and try it and
see if it works. :)

-- 
  Roger So                                            telnet://e-fever.org
  spacehunt at e-fever dot org                          SysOp, e-Fever BBS
  GnuPG  1024D/98FAA0AD  F2C3 4136 8FB1 7502 0C0C 01B1 0E59 37AC 98FA A0AD
-- 
| This message was re-posted from [email protected]
| and converted from big5 to gb2312 by an automatic gateway.
# 
#  (c) 1996, X11R6 L10N for Taiwan and Big5 Encoding Project
# 
#  modified for X11R6.3 by Hung-Chi Chu <[EMAIL PROTECTED]> 1998/01/10
# 
#       XLC_FONTSET category
#
# $XFree86: xc/nls/XLC_LOCALE/zh_TW.Big5,v 1.1.2.2 1999/07/30 13:19:19 hohndel 
Exp $
# 
# Modified for HKSCS by Roger So <[EMAIL PROTECTED]>
#
#

XLC_FONTSET
# fs0 class (7 bit ASCII)
fs0     {
        charset {
                name    ISO8859-1:GL
        }
        font    {
                primary         ISO8859-1:GL
                vertical_rotate all
        }
}
# fs1 class (standard Big5)
fs1     {
        charset {
                name    BIG5-0:GLGR
        }
        font    {
                primary BIG5-0:GLGR
        }
}
# fs2 class (HKSCS extensions)
fs2     {
        charset {
                name    BIG5HKSCS-0:GLGR
        }
        font    {
                primary BIG5HKSCS-0:GLGR
        }
}
END XLC_FONTSET

#===========================================================
# 
#       XLC_XLOCALE category
# 
XLC_XLOCALE

encoding_name           zh_HK.Big5HKSCS
mb_cur_max              2
state_depend_encoding   False

wc_encoding_mask        \x00008000
wc_shift_bits           8

use_stdc_env            True
force_convert_to_mb     True

cs0     {
        side            GL:Default
        length          1
        wc_encoding     \x00000000
        ct_encoding     ISO8859-1:GL
}

# standard Big5, 0xA1-0xF9
cs1     {
        side            none
        length          2
        byte1           \xa1,\xf9
        byte2           \x40,\x7e;\xa1,\xfe

        wc_encoding     \x00008000
        ct_encoding     
BIG5-0:GLGR:\x1b\x25\x2f\x32\x80\x89\x42\x49\x47\x35\x2d\x30\x02

        mb_conversion   [\xa140,\xf9fe]->\x2140
        ct_conversion   [\x2140,\x79fe]->\xa140
}

# HKSCS extensions, 0x81-0xA0 + 0xFA-0xFE
cs2     {
        side            none
        length          2
        byte1           \x81,\xa0;\xfa,\xfe
        byte2           \x40,\x7e;\xa1,\xfe

        wc_encoding     \x00008000
        ct_encoding     
BIG5HKSCS-0:GLGR:\x1b\x25\x2f\x32\x80\x8c\x42\x49\x47\x35\x48\x4b\x53\x43\x53\x2d\x30\x02

        mb_conversion   [\x8140,\xfefe]->\x0140
        ct_conversion   [\x0140,\x7efe]->\x8140
}
END XLC_XLOCALE
-- 
| This message was re-posted from [email protected]
| and converted from big5 to gb2312 by an automatic gateway.

Reply via email to