315abbb
To: vim_dev@googlegroups.com
315abbb
Subject: Patch 7.4.173
315abbb
Fcc: outbox
315abbb
From: Bram Moolenaar <Bram@moolenaar.net>
315abbb
Mime-Version: 1.0
315abbb
Content-Type: text/plain; charset=UTF-8
315abbb
Content-Transfer-Encoding: 8bit
315abbb
------------
315abbb
315abbb
Patch 7.4.173
315abbb
Problem:    When using scrollbind the cursor can end up below the last line.
315abbb
	    (mvxxc)
315abbb
Solution:   Reset w_botfill when scrolling up. (Christian Brabandt)
315abbb
Files:	    src/move.c
315abbb
315abbb
315abbb
*** ../vim-7.4.172/src/move.c	2012-11-28 18:15:42.000000000 +0100
315abbb
--- src/move.c	2014-02-11 15:39:24.758138292 +0100
315abbb
***************
315abbb
*** 2101,2106 ****
315abbb
--- 2101,2107 ----
315abbb
      int		used;
315abbb
      lineoff_T	loff;
315abbb
      lineoff_T	boff;
315abbb
+     linenr_T	old_topline = curwin->w_topline;
315abbb
  
315abbb
      loff.lnum = boff.lnum = curwin->w_cursor.lnum;
315abbb
  #ifdef FEAT_FOLDING
315abbb
***************
315abbb
*** 2156,2161 ****
315abbb
--- 2157,2164 ----
315abbb
  	curwin->w_topline = topline;
315abbb
  #ifdef FEAT_DIFF
315abbb
      curwin->w_topfill = topfill;
315abbb
+     if (old_topline > curwin->w_topline + curwin->w_height)
315abbb
+ 	curwin->w_botfill = FALSE;
315abbb
      check_topfill(curwin, FALSE);
315abbb
  #endif
315abbb
      curwin->w_valid &= ~(VALID_WROW|VALID_CROW|VALID_BOTLINE|VALID_BOTLINE_AP);
315abbb
*** ../vim-7.4.172/src/version.c	2014-02-11 15:23:27.942123631 +0100
315abbb
--- src/version.c	2014-02-11 15:38:34.562137523 +0100
315abbb
***************
315abbb
*** 740,741 ****
315abbb
--- 740,743 ----
315abbb
  {   /* Add new patch number below this line */
315abbb
+ /**/
315abbb
+     173,
315abbb
  /**/
315abbb
315abbb
-- 
315abbb
   GALAHAD hurries to the door and pushes through it.  As he leaves the room
315abbb
   we CUT TO the reverse to show that he is now in a room full of bathing
315abbb
   and romping GIRLIES, all innocent, wide-eyed and beautiful.  They smile
315abbb
   enchantingly at him as he tries to keep walking without being diverted by
315abbb
   the lovely sights assaulting his eyeballs.
315abbb
                 "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD
315abbb
315abbb
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
315abbb
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
315abbb
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
315abbb
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///