vimode: fixed the cursor position in some cases of the "c" command in normal mode.

Review Request #114872 - Created Jan. 5, 2014 and submitted

Information
Miquel Sabaté Solà
kate
master
Reviewers
kate
Consider the following text: "something". Before this patch, if you hit 'ci"' with the cursor in the first double quote character, the text is transformed into: "". This is correct, but in this specific case, the cursor is then left before the first double quote character instead of between the two double quote characters. With this patch, after transforming the text, the cursor is left inside the two double quote characters. This same issue appeared with other characters like ', <, >, etc. This is the same behavior as in vim.
I've added a few QCOMPARE's in the NormalModeMotionsTest() function. I've also tested this patch manually.
Simon St James
Miquel Sabaté Solà
Commit Hook
Commit Hook
This review has been submitted with commit 4439214a19842b0335f0ef524e17dce608227b7e by Miquel Sabaté to branch frameworks.
Miquel Sabaté Solà
Review request changed

Status: Closed (submitted)

Loading...