Jean-Marc Lienher wrote on 2002-11-10 18:32 UTC:
> The Xterm patch should look like this :
> --------------------------------------------------------------
> ret = Xutf8LookupString(ic, event, buf, 20, &keysym, &status);
> 
> if (ret == 0 && keysym & 0xFF000000 == 0x01000000) {
>       ret = unicode_to_utf8(keysym - 0x01000000, buf);
> }
> ---------------------------------------------------------------

The *entire* keysym -> Unicode/UTF-8 converstion should of course be
done *inside* a single function such as Xutf8LookupString or
X{mb,wc}LookupString, independent of whether the keysym is >= 0x01000000
or not. Under no circumstances must you factor out one tiny part of this
conversion process into an application. If I understood correctly what
you suggest, then your patch should definitely be rejected. This does
not smell like decent software engineering.

X.Org is still distributing an outdated X{mb,wc}LookupString function
that does not handle keysym >= 0x01000000, but that implementation also
has quite a number of bugs in its keysym->Unicode table and therefore
should not be used at all.

Markus

-- 
Markus G. Kuhn, Computer Laboratory, University of Cambridge, UK
Email: mkuhn at acm.org,  WWW: <http://www.cl.cam.ac.uk/~mgk25/>

_______________________________________________
I18n mailing list
[EMAIL PROTECTED]
http://XFree86.Org/mailman/listinfo/i18n

Reply via email to