From cbd4480f97a913e0e356ec02f652b693b0195767 Mon Sep 17 00:00:00 2001 From: luukvbaal <31730729+luukvbaal@users.noreply.github.com> Date: Sun, 19 Feb 2023 01:33:02 +0100 Subject: vim-patch:9.0.1324: "gj" and "gk" do not move correctly over a closed fold (#22320) Problem: "gj" and "gk" do not move correctly over a closed fold. Solution: Use the same code as used for "j"/"k" to go to the next/previous line. (Luuk van Baal, closes vim/vim#12007) https://github.com/vim/vim/commit/441a7a94482f704b66253b8d08130f27b6b13736 --- src/nvim/testdir/test_fold.vim | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/nvim/testdir') diff --git a/src/nvim/testdir/test_fold.vim b/src/nvim/testdir/test_fold.vim index 9014948fb4..2f5c93ca2d 100644 --- a/src/nvim/testdir/test_fold.vim +++ b/src/nvim/testdir/test_fold.vim @@ -1548,4 +1548,11 @@ func Test_expand_fold_at_bottom_of_buffer() bwipe! endfunc +func Test_fold_screenrow_motion() + call setline(1, repeat(['aaaa'], 5)) + 1,4fold + norm Ggkzo + call assert_equal(1, line('.')) +endfunc + " vim: shiftwidth=2 sts=2 expandtab -- cgit