Mercurial > vim
comparison src/move.c @ 30219:bc8ad1c28b51
patch 9.0.0445: when opening/closing window text moves up/down
Commit: https://github.com/vim/vim/commit/29ab524358ba429bcf6811710afc97a978641f0b
Author: Luuk van Baal <luukvbaal@gmail.com>
Date: Sun Sep 11 16:59:53 2022 +0100
patch 9.0.0445: when opening/closing window text moves up/down
Problem: When opening/closing window text moves up/down.
Solution: Add the 'splitscroll' option. When off text will keep its
position as much as possible.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sun, 11 Sep 2022 18:00:03 +0200 |
parents | ed6f3d2593df |
children | 0d084880276a |
comparison
equal
deleted
inserted
replaced
30218:759e9dfee593 | 30219:bc8ad1c28b51 |
---|---|
979 long siso = get_sidescrolloff_value(); | 979 long siso = get_sidescrolloff_value(); |
980 | 980 |
981 /* | 981 /* |
982 * First make sure that w_topline is valid (after moving the cursor). | 982 * First make sure that w_topline is valid (after moving the cursor). |
983 */ | 983 */ |
984 update_topline(); | 984 if (p_spsc) |
985 update_topline(); | |
985 | 986 |
986 /* | 987 /* |
987 * Next make sure that w_cline_row is valid. | 988 * Next make sure that w_cline_row is valid. |
988 */ | 989 */ |
989 if (!(curwin->w_valid & VALID_CROW)) | 990 if (!(curwin->w_valid & VALID_CROW)) |