diff --git a/src/plugins/fakevim/fakevimhandler.cpp b/src/plugins/fakevim/fakevimhandler.cpp index 0ed3706384bc17487916fdbc076aa38685029532..7e44f200638a78a83f44dd4e22e63c5fb6a11d70 100755 --- a/src/plugins/fakevim/fakevimhandler.cpp +++ b/src/plugins/fakevim/fakevimhandler.cpp @@ -2750,7 +2750,6 @@ void FakeVimHandler::Private::handleFfTt(int key) void FakeVimHandler::Private::moveToNextWord(bool simple) { - // FIXME: 'w' should stop on empty lines, too int repeat = count(); int n = lastPositionInDocument(); int lastClass = charClass(characterAtCursor(), simple); @@ -2763,6 +2762,10 @@ void FakeVimHandler::Private::moveToNextWord(bool simple) break; lastClass = thisClass; moveRight(); + if (m_tc.block().length() == 1) // empty line + --repeat; + if (repeat == 0) + break; if (m_tc.position() == n) break; }