forked from qt-creator/qt-creator
FakeVim: Escape '>' character in mappings
On some keyboards, '>' character can be produced using Shift key. But recorded macro shouldn't contain '<S->>', which cannot be properly parsed, instead it will be '<S-<GT>>' (as '<LT>' for '<'). Change-Id: Iac3759029b6ff8c9e690c4728e35048c0b6046f9 Reviewed-by: hjk <hjk121@nokiamail.com>
This commit is contained in:
@@ -725,6 +725,7 @@ static const QMap<QString, int> &vimKeyNames()
|
||||
k.insert(_("RIGHT"), Key_Right);
|
||||
|
||||
k.insert(_("LT"), Key_Less);
|
||||
k.insert(_("GT"), Key_Greater);
|
||||
|
||||
k.insert(_("F1"), Key_F1);
|
||||
k.insert(_("F2"), Key_F2);
|
||||
@@ -1007,6 +1008,8 @@ public:
|
||||
if (!namedKey) {
|
||||
if (m_xkey == '<')
|
||||
key = _("<LT>");
|
||||
else if (m_xkey == '>')
|
||||
key = _("<GT>");
|
||||
else
|
||||
key = QChar(m_xkey);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user