commit dfc3db773ac79e33b828b2d2b4a008c8a37cd4e9
Author: Daniel Ramoeller <[email protected]>
Date: Fri Mar 17 21:45:36 2023 +0100
Fixup 89394bcd: handle cursor keys from keypad
Due to a macOS peculiarity, it is necessary to handle KeypadModifier.
We do it unconditionnally, although only macOS seems to be affected.
"Note: On macOS, [...] The KeypadModifier value will also be set when
an arrow key is pressed as the arrow keys are considered part of the
keypad." (https://doc.qt.io/qt-6/qt.html#KeyboardModifier-enum)
Related to bug #12572.
---
src/frontends/qt/GuiCommandEdit.cpp | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/src/frontends/qt/GuiCommandEdit.cpp
b/src/frontends/qt/GuiCommandEdit.cpp
index 89883da..a3bf14c 100644
--- a/src/frontends/qt/GuiCommandEdit.cpp
+++ b/src/frontends/qt/GuiCommandEdit.cpp
@@ -29,7 +29,7 @@ GuiCommandEdit::GuiCommandEdit(QWidget * parent)
void GuiCommandEdit::keyPressEvent(QKeyEvent * e)
{
- if (e->modifiers() == Qt::NoModifier) {
+ if (e->modifiers() == Qt::NoModifier || e->modifiers() ==
Qt::KeypadModifier) {
switch (e->key()) {
case Qt::Key_Escape:
// emit signal
--
lyx-cvs mailing list
[email protected]
http://lists.lyx.org/mailman/listinfo/lyx-cvs