Vim `gk` at the head of line goes 2 line up

Steps to reproduce

  1. Open a file with wrapped long paragraph. Make sure vim is open and it is in view mode.
  2. gg: curosr at first line
  3. gj x 2: cursor to third line
  4. gk: cursor to the first line rather than second

Expected result

In vim view mode, pressing gk leads to 1 viewing line up.

Actual result

Pressing gk leads to 2 viewing line up if cursor is at the head of one line.


windows 10
obsidian 1.5.3
No third party vim plugin

Additional information

gj works fine. gk works also if cursor at the middle of a line.

1 Like

Addition gif:

  1. Does it happen in the sandbox vault?
  2. Does it happen in source mode?
  3. Does it happen here ?

I can repro, thanks!

  1. yes.
  2. yes.
  3. don’t understand how to test in this website. It looks like an only-read webpage
  1. Here

  1. Yes


Search/open an issue here and explain how to reproduce the issue in their sandbox

Hi, I came across this thread but couldn’t find a corresponding issue that had been opened for it so I went ahead and opened one here here
Weirdly I couldn’t recreate it in their sandbox but I described the issue and linked back to this discussion.

Now I can’t reproduce the issue in code mirror’s sandbox. It seems that they have fixed the issue. But in latest obsidian 1.5.11,the bug still exist.

Same here, very annoying

Same here, the bug still persists in obsidian 1.5.12-1. I’ve tested the Code mirror sandbox and I can confirm that it’s fixed.