emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: kbd vs read-key-sequence


From: Eli Zaretskii
Subject: Re: kbd vs read-key-sequence
Date: Mon, 02 Apr 2007 14:58:40 +0300

> From: Kenichi Handa <address@hidden>
> CC: address@hidden, address@hidden, address@hidden, address@hidden
> Date: Mon, 02 Apr 2007 11:27:41 +0900
> 
> Windows code is already using MultiByteToWideChar() which
> seems to convert codepage codes to Unicode character, right?

Not to Unicode, to UTF-16.

> Then, can't we use it to get a Unicode character code from
> keyevent(s) and do something like this?
> 
>         MultiByteToWideChar (codepage, 0, inbuf, inlen, outbuf, outlen)
>       lisp_char = call2 (intern ("decode-char"), intern ("ucs"),
>                           make_number (outbuf[0]));

I don't think this is the right way of getting Unicode codepoints for
keyboard input on Windows; see

     http://msdn2.microsoft.com/en-us/library/ms646267.aspx

(under "Nonsystem Character Messages"), and

     http://msdn2.microsoft.com/en-us/library/ms633586.aspx

for the gory details.

But surely, such a drastic change in the w32 keyboard input processing
is not something to consider before the release!  Especially when the
problems we are trying to fix are so minor, almost invisible.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]