Kai Ma <justksqsf@gmail.com> writes: > Hi all, > > Attached is a one-liner patch to the âghost keyâ problem on NS. (The name is > made up by me.) I didnât have luck finding a bug report (but it did happen to > many to-be-liberated Mac users [1-3]), so I decided to directly send it here. > > On certain occasions (*), the key event buffer is not cleared to be > empty even if the events have been processed. This results in a nasty > problem: when you press a key, say âyâ, a key that is pressed earlier > will be prepended to the current key. Thereâs no way to reset the > event buffer. > > This problem is highly unpredictable, making it very hard to reproduce. A > probably quicker way: hack Emacsâ C codebase with corfu-auto and citre-mode. > > (*) The root cause is still not clear to me. Itâs observed that > sometimes, the [interpretKeyEvents] call seems not to return. (Blocked > inside Cocoa?) And the supposedly matched âremoveâ is never > called. Now ânsEvArrayâ is left with an earlier keyDown event, and > since ânsEvArrayâ is static, you have the problem as described > above. I guess it may be some Cocoa internal changes that caused this. > > This patch is just a workaround, but it improves the current user experience > a bit. I am sorry, but this patch breaks compose processing. So we're certainly not installing anything like this in Emacs 29. I will try to figure out a way to reproduce the bug and why it actually happens.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4