Subject: Re: bug#74590: 31.0.50 [scratch/igc branch]; key input sometimes skip fcitx input method preedit box

From: Eli Zaretskii <[email-masked]>
Date: Mon, 02 Dec 2024 18:51:26 +0200

> Cc: Gerd Möllmann <[email-masked]>,
>  Helmut Eller <[email-masked]>, [email-masked]
> Date: Mon, 02 Dec 2024 16:26:50 +0000
> From:  Pip Cet via "Bug reports for GNU Emacs,
>  the Swiss army knife of text editors" <[email-masked]>
> 
> "Yikai Zhao" <[email-masked]> writes:
> 
> > I have reproduced the issue with your patch, here's the relevant log:
> 
> Thank you! So it seems we call XFilterEvent correctly but it incorrectly
> indicates that the keypress (event 2) should be handled by Emacs rather
> than the input method. That's rather puzzling, particularly since
> subsequent calls to XFilterEvent return 1, indicating that the key
> release is handled by the input method.
> 
> I'm pretty much stumped at this point. It might be a timing difference
> between the MPS and non-MPS builds, but I think it's more likely to be
> a bug in our MPS code.
> 
> > Please let me know if there's any other info I can provide.
> 
> Well, you already tried setting x-gtk-use-native-input to t :-)
> 
> One thing you could try is to run a full x11trace of the Emacs session
> and see whether anything unusual is in there. But that's not guaranteed
> to yield any results.

Maybe Po Lu (CC'ed) could have some additional ideas or comments.