GNU bug report logs - #11041
23.4; Shifted keystrokes are not passed into OS X Input Manager correctly

Previous Next

Package: emacs;

Reported by: Yong-Gang Wang <wixette <at> gmail.com>

Date: Sun, 18 Mar 2012 19:40:02 UTC

Severity: normal

Tags: fixed

Found in version 23.4

Fixed in version 26.0

Done: Alan Third <alan <at> idiocy.org>

Bug is archived. No further changes may be made.

Full log


Message #8 received at 11041 <at> debbugs.gnu.org (full text, mbox):

From: Alan Third <alan <at> idiocy.org>
To: Yong-Gang Wang <wixette <at> gmail.com>
Cc: 11041 <at> debbugs.gnu.org
Subject: Re: bug#11041: 23.4;
 Shifted keystrokes are not passed into OS X Input Manager correctly
Date: Wed, 27 Dec 2017 00:11:13 +0000
Yong-Gang Wang <wixette <at> gmail.com> writes:

> Repro: On Mac OS X, turns a CJK input method on, e.g. Chinese Pinyin Input Method, then types shifted characters like ":", "?", "<" or ">" in GNU Emacs OS X 23.4.1.
> Expected results: Chinese fullwidth punctuations are input, like ":", "?", "《" or "》".
> Actual results: English halfwidth punctuations are input, ":", "?", "<" or ">".
>
> Debug and Code location:
>
> See src/nsterm.m line 4490-4492, the current logic is, when there are modifier keys, including SHIFT, being pressed down, the key code won't be sent to OS X Input Manager for composing the input method result. This logic is NOT true for shifted keystrokes. Actually, shifted keystrokes like ":", "?", "<" or ">" are still display characters and should be sent into the Input Manager
> for composing.
>
>       /* if it was a function key or had modifiers, pass it directly to emacs */
>       if (fnKeysym || (emacs_event->modifiers
>                        && [[theEvent charactersIgnoringModifiers] length] > 0))
>
> A workable fix:
>
>       /* if it was a function key or had modifiers(except for shift only modifier), pass it directly to emacs */
>       if (fnKeysym || (emacs_event->modifiers
>                        && emacs_event->modifiers != shift_modifier
>                        && [[theEvent charactersIgnoringModifiers] length] > 0))

Hi Sorry, it's taken so long for someone to get back to you.

It looks like this exact fix was already in Emacs when the bug was
raised, so I'm not sure what's going on.

Are you able to confirm whether this now works as expected?
-- 
Alan Third




This bug report was last modified 7 years and 180 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.