Peter Kümmel wrote:
Yes, I also don't like the hardcoding. The problem is that if we start
to drop events we have to differentiate between good and bad events, and
it is hard to find a solution for all cases. So it would be better not
to drop any key. But what is the alternative? A XSync call could block
the main thread, but suppresses it the auto generated key events? Does
it not eat user generated events?

At the time that this filtering code is called, you already know what key bindings the LyX user is using. So, you could replace the hard-coded Qt::Key_PageDown, etc with
        lyx::PageDownKeyEvent()
where this function encapsulates the different cua.bind, emacs.bind, etc syntax.

Regards,
Angus

Reply via email to