From 4e383dd1100ee35e08cafcbebdcefdae330b3323 Mon Sep 17 00:00:00 2001 From: "Yevhen Babiichuk (DustDFG)" Date: Wed, 17 Jan 2024 10:04:18 +0200 Subject: [PATCH] Do correct cursor right with storing visual X in `CursorRight` action (#3103) Signed-off-by: Yevhen Babiichuk (DustDFG) --- internal/action/actions.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/action/actions.go b/internal/action/actions.go index d45f5b2f..be197d74 100644 --- a/internal/action/actions.go +++ b/internal/action/actions.go @@ -211,7 +211,7 @@ func (h *BufPane) CursorLeft() bool { func (h *BufPane) CursorRight() bool { if h.Cursor.HasSelection() { h.Cursor.Deselect(false) - h.Cursor.Loc = h.Cursor.Loc.Move(1, h.Buf) + h.Cursor.Right() } else { tabstospaces := h.Buf.Settings["tabstospaces"].(bool) tabmovement := h.Buf.Settings["tabmovement"].(bool)