|
|
@@ -3346,13 +3346,21 @@ handle_target:
|
|
|
second = tmp;
|
|
|
}
|
|
|
|
|
|
- --second;
|
|
|
+ if (!(checkMode(VimMode::Normal) && p_moveMode == QTextCursor::KeepAnchor)) {
|
|
|
+ --second;
|
|
|
+ }
|
|
|
|
|
|
int target = first;
|
|
|
if (first == pairPosition) {
|
|
|
target = second;
|
|
|
}
|
|
|
|
|
|
+ if (anchor > target
|
|
|
+ && !p_cursor.atEnd()
|
|
|
+ && !useLeftSideOfCursor(p_cursor)) {
|
|
|
+ ++anchor;
|
|
|
+ }
|
|
|
+
|
|
|
p_cursor.setPosition(anchor);
|
|
|
p_cursor.setPosition(target, p_moveMode);
|
|
|
|