From f59785670a2ff12cec33894add6dc1590c7b77b1 Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Mon, 28 Sep 2026 15:28:36 -0300 Subject: Replacing a selection with the register keeps its direction R always left the head on the pasted text's last char. helix maps the replaced range through the change, so a backward selection comes back backward, its head on the first char: helix-golf's reverse_golf_example (xbR) is where it showed. SPC R shares the path. Co-Authored-By: Claude Opus 5.5 --- test/hxcases/cases.jsonl | 2 ++ test/hxcases/goldens.jsonl | 2 ++ 2 files changed, 4 insertions(+) (limited to 'test') diff --git a/test/hxcases/cases.jsonl b/test/hxcases/cases.jsonl index d7f76912..6e1b8188 100644 --- a/test/hxcases/cases.jsonl +++ b/test/hxcases/cases.jsonl @@ -287,6 +287,8 @@ {"name": "r-cancel-esc", "pane": "file", "text": "abc\n", "keys": "rl"} {"name": "R-inline", "pane": "file", "text": "alpha beta\n", "keys": "wyggR"} {"name": "R-linewise", "pane": "file", "text": "one\ntwo\n", "keys": "xyjR"} +{"name": "R-backward", "pane": "file", "text": "alpha beta\n", "keys": "wyebR"} +{"name": "R-backward-linewise", "pane": "file", "text": "one\ntwo three\n", "keys": "xyjxbR"} {"name": "tilde-sel-keeps", "pane": "file", "text": "abc\n", "keys": "vll~"} {"name": "tilde-bare", "pane": "file", "text": "aBc\n", "keys": "~"} {"name": "backtick-lower", "pane": "file", "text": "ABC\n", "keys": "vll`"} diff --git a/test/hxcases/goldens.jsonl b/test/hxcases/goldens.jsonl index cab7393b..8ac110e6 100644 --- a/test/hxcases/goldens.jsonl +++ b/test/hxcases/goldens.jsonl @@ -287,6 +287,8 @@ {"name":"r-cancel-esc","text":"abc\n","mode":"normal","cursor":{"row":0,"col":1},"anchor":{"row":0,"col":1}} {"name":"R-inline","text":"alpha lpha beta\n","mode":"normal","cursor":{"row":0,"col":5},"anchor":{"row":0,"col":0}} {"name":"R-linewise","text":"one\ntwoone\n","mode":"normal","cursor":{"row":1,"col":6},"anchor":{"row":1,"col":3}} +{"name":"R-backward","text":"alpha alpha \n","mode":"normal","cursor":{"row":0,"col":6},"anchor":{"row":0,"col":11}} +{"name":"R-backward-linewise","text":"one\ntwo one\n\n","mode":"normal","cursor":{"row":1,"col":4},"anchor":{"row":1,"col":7}} {"name":"tilde-sel-keeps","text":"ABC\n","mode":"normal","cursor":{"row":0,"col":2},"anchor":{"row":0,"col":0}} {"name":"tilde-bare","text":"ABc\n","mode":"normal","cursor":{"row":0,"col":0},"anchor":{"row":0,"col":0}} {"name":"backtick-lower","text":"abc\n","mode":"normal","cursor":{"row":0,"col":2},"anchor":{"row":0,"col":0}} -- cgit v1.3