From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#10299: Emacs doesn't handle Unicode characters in keyboard layout on MS Windows Date: Fri, 16 Dec 2011 13:22:01 +0200 Message-ID: <83r504223q.fsf@gnu.org> References: <8739clgapc.fsf@gnu.org> <83zket20xw.fsf@gnu.org> <83vcph0w9t.fsf@gnu.org> Reply-To: Eli Zaretskii NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: QUOTED-PRINTABLE X-Trace: dough.gmane.org 1324034565 29322 80.91.229.12 (16 Dec 2011 11:22:45 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 16 Dec 2011 11:22:45 +0000 (UTC) Cc: 10299@debbugs.gnu.org To: Joakim =?UTF-8?Q?H=C3=A5rsman?= Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Dec 16 12:22:40 2011 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1RbVs8-00006s-FD for geb-bug-gnu-emacs@m.gmane.org; Fri, 16 Dec 2011 12:22:40 +0100 Original-Received: from localhost ([::1]:60106 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RbVs7-0001LI-Qf for geb-bug-gnu-emacs@m.gmane.org; Fri, 16 Dec 2011 06:22:39 -0500 Original-Received: from eggs.gnu.org ([140.186.70.92]:47940) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RbVs4-0001KF-MZ for bug-gnu-emacs@gnu.org; Fri, 16 Dec 2011 06:22:37 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RbVrv-0006Ji-Pm for bug-gnu-emacs@gnu.org; Fri, 16 Dec 2011 06:22:36 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:39714) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RbVrv-0006Je-OL for bug-gnu-emacs@gnu.org; Fri, 16 Dec 2011 06:22:27 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1RbVtS-0005Hy-DS for bug-gnu-emacs@gnu.org; Fri, 16 Dec 2011 06:24:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 16 Dec 2011 11:24:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 10299 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 10299-submit@debbugs.gnu.org id=B10299.132403462120294 (code B ref 10299); Fri, 16 Dec 2011 11:24:02 +0000 Original-Received: (at 10299) by debbugs.gnu.org; 16 Dec 2011 11:23:41 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1RbVt7-0005HE-0R for submit@debbugs.gnu.org; Fri, 16 Dec 2011 06:23:41 -0500 Original-Received: from mtaout22.012.net.il ([80.179.55.172]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1RbVt4-0005Gz-7e for 10299@debbugs.gnu.org; Fri, 16 Dec 2011 06:23:39 -0500 Original-Received: from conversion-daemon.a-mtaout22.012.net.il by a-mtaout22.012.net.il (HyperSendmail v2007.08) id <0LWA00K00NAZYB00@a-mtaout22.012.net.il> for 10299@debbugs.gnu.org; Fri, 16 Dec 2011 13:22:00 +0200 (IST) Original-Received: from HOME-C4E4A596F7 ([77.127.39.203]) by a-mtaout22.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0LWA00IESNKLWJI0@a-mtaout22.012.net.il>; Fri, 16 Dec 2011 13:22:00 +0200 (IST) In-reply-to: X-012-Sender: halo1@inter.net.il X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Fri, 16 Dec 2011 06:24:02 -0500 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:55009 Archived-At: > Date: Fri, 16 Dec 2011 12:01:02 +0100 > From: Joakim H=E5rsman > Cc: jasonr@gnu.org, 10299@debbugs.gnu.org, handa@m17n.org >=20 > So I'll try to change to using RegisterClassW which should fix this > issue but might break other stuff since more messages will deliver > Unicode text then. I think using RegisterClassW is the right way. But please pay attention to this part of w32term.c:w32_read_socket: if (msg.msg.message =3D=3D WM_UNICHAR) { inev.code =3D msg.msg.wParam; } else if (msg.msg.wParam < 256) { ... } else { /* Windows shouldn't generate WM_CHAR events above = 0xFF in non-Unicode message handlers. */ DebPrint (("Non-byte WM_CHAR: %d\n", msg.msg.wParam= )); inev.kind =3D NO_EVENT; break; } inev.kind =3D inev.code < 128 ? ASCII_KEYSTROKE_EVENT : MULTIBYTE_CHAR_KEYSTROKE_= EVENT; If Windows continues sending WM_CHAR to Emacs even if you call RegisterClassW, you will probably need to modify the "else" clause to use the characters with codepoints beyond 256, instead of throwing them away.