From 01fc62b78eb844d400803f0a489d5b326714708b Mon Sep 17 00:00:00 2001 From: Jean-Marc Lasgouttes Date: Tue, 5 Jan 2016 11:12:00 +0100 Subject: [PATCH] When moving cursor, always reset anchor This applies to BufferView::moveToPosition, which is used for bookmarks and initial cursor position (on loading). Fixes bug #9912. --- src/BufferView.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/BufferView.cpp b/src/BufferView.cpp index 15dcb92682..7332ec5921 100644 --- a/src/BufferView.cpp +++ b/src/BufferView.cpp @@ -809,6 +809,8 @@ bool BufferView::moveToPosition(pit_type bottom_pit, pos_type bottom_pos, setCursor(dit); // set the current font. d->cursor_.setCurrentFont(); + // Do not forget to reset the anchor (see #9912) + d->cursor_.resetAnchor(); // To center the screen on this new position we need the // paragraph position which is computed at draw() time. // So we need a redraw!