diff --git a/src/utils/vvim.cpp b/src/utils/vvim.cpp index 2ce6ac74..4c73fbca 100644 --- a/src/utils/vvim.cpp +++ b/src/utils/vvim.cpp @@ -569,7 +569,11 @@ bool VVim::handleKeyPressEvent(int key, int modifiers, int *p_autoIndentPos) if (m_registerPending) { // Ctrl and Shift may be sent out first. - if (key == Qt::Key_Control || key == Qt::Key_Shift || key == Qt::Key_Meta) { + if (key == Qt::Key_Control + || key == Qt::Key_Shift + || key == Qt::Key_Meta + // For mapping Caps as Ctrl in KDE. + || key == Qt::Key_CapsLock) { goto accept; } diff --git a/src/vmdeditoperations.cpp b/src/vmdeditoperations.cpp index 1e427d56..22ffe56a 100644 --- a/src/vmdeditoperations.cpp +++ b/src/vmdeditoperations.cpp @@ -483,7 +483,9 @@ exit: && key != Qt::Key_Tab && key != Qt::Key_Backtab && key != Qt::Key_Shift - && key != Qt::Key_Control) { + && key != Qt::Key_Control + // For mapping Caps as Ctrl in KDE. + && key != Qt::Key_CapsLock) { m_autoIndentPos = -1; }