diff options
author | Jan Edmund Lazo <jan.lazo@mail.utoronto.ca> | 2019-10-17 04:24:23 -0400 |
---|---|---|
committer | Justin M. Keyes <justinkz@gmail.com> | 2019-10-17 01:24:23 -0700 |
commit | 0785f8e8b11b2fa290cfbc0604d570f49b954ba6 (patch) | |
tree | ec9cd655c7a85a533d03240965df22c16f6dce23 /src/nvim/testdir | |
parent | 94bda2fec8d03cdbea442d70c41186f0aa039786 (diff) | |
download | rneovim-0785f8e8b11b2fa290cfbc0604d570f49b954ba6.tar.gz rneovim-0785f8e8b11b2fa290cfbc0604d570f49b954ba6.tar.bz2 rneovim-0785f8e8b11b2fa290cfbc0604d570f49b954ba6.zip |
vim-patch:8.1.2140: "gk" and "gj" do not work correctly in number column #11208
Problem: "gk" and "gj" do not work correctly in number column.
Solution: Allow for a negative "curswant". (Zach Wegner, closes vim/vim#4969)
https://github.com/vim/vim/commit/ceba3dd5187788e09f65bd41b07b40f6f9aab953
Diffstat (limited to 'src/nvim/testdir')
-rw-r--r-- | src/nvim/testdir/test_normal.vim | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/src/nvim/testdir/test_normal.vim b/src/nvim/testdir/test_normal.vim index b967f84626..aeae6423d0 100644 --- a/src/nvim/testdir/test_normal.vim +++ b/src/nvim/testdir/test_normal.vim @@ -2813,4 +2813,29 @@ func Test_normal_gk() call assert_equal(95, virtcol('.')) bw! bw! + + " needs 80 column new window + new + vert 80new + set number + set numberwidth=10 + set cpoptions+=n + put =[repeat('0',90), repeat('1',90)] + norm! 075l + call assert_equal(76, col('.')) + norm! gk + call assert_equal(1, col('.')) + norm! gk + call assert_equal(76, col('.')) + norm! gk + call assert_equal(1, col('.')) + norm! gj + call assert_equal(76, col('.')) + norm! gj + call assert_equal(1, col('.')) + norm! gj + call assert_equal(76, col('.')) + bw! + bw! + set cpoptions& number& numberwidth& endfunc |