ee42d7c
To: vim_dev@googlegroups.com
ee42d7c
Subject: Patch 7.3.137
ee42d7c
Fcc: outbox
ee42d7c
From: Bram Moolenaar <Bram@moolenaar.net>
ee42d7c
Mime-Version: 1.0
ee42d7c
Content-Type: text/plain; charset=UTF-8
ee42d7c
Content-Transfer-Encoding: 8bit
ee42d7c
------------
ee42d7c
ee42d7c
Patch 7.3.137 (after 7.3.091)
ee42d7c
Problem:    When 'lazyredraw' is set the screen may not be updated. (Ivan
ee42d7c
	    Krasilnikov)
ee42d7c
Solution:   Call update_screen() before waiting for input.
ee42d7c
Files:	    src/misc1.c, src/getchar.c
ee42d7c
ee42d7c
ee42d7c
*** ../vim-7.3.136/src/misc1.c	2011-01-22 00:11:42.000000000 +0100
ee42d7c
--- src/misc1.c	2011-03-03 14:02:02.000000000 +0100
ee42d7c
***************
ee42d7c
*** 3115,3121 ****
ee42d7c
--- 3115,3129 ----
ee42d7c
  	    continue;
ee42d7c
  
ee42d7c
  	if (n == KEYLEN_REMOVED)  /* key code removed */
ee42d7c
+ 	{
ee42d7c
+ 	    if (must_redraw)
ee42d7c
+ 	    {
ee42d7c
+ 		/* Redrawing was postponed, do it now. */
ee42d7c
+ 		update_screen(0);
ee42d7c
+ 		setcursor(); /* put cursor back where it belongs */
ee42d7c
+ 	    }
ee42d7c
  	    continue;
ee42d7c
+ 	}
ee42d7c
  	if (n > 0)		/* found a termcode: adjust length */
ee42d7c
  	    len = n;
ee42d7c
  	if (len == 0)		/* nothing typed yet */
ee42d7c
*** ../vim-7.3.136/src/getchar.c	2010-12-30 12:30:26.000000000 +0100
ee42d7c
--- src/getchar.c	2011-03-03 14:01:26.000000000 +0100
ee42d7c
***************
ee42d7c
*** 2710,2717 ****
ee42d7c
  		 * are still available.  But when those available characters
ee42d7c
  		 * are part of a mapping, and we are going to do a blocking
ee42d7c
  		 * wait here.  Need to update the screen to display the
ee42d7c
! 		 * changed text so far. */
ee42d7c
! 		if ((State & INSERT) && advance && must_redraw != 0)
ee42d7c
  		{
ee42d7c
  		    update_screen(0);
ee42d7c
  		    setcursor(); /* put cursor back where it belongs */
ee42d7c
--- 2710,2719 ----
ee42d7c
  		 * are still available.  But when those available characters
ee42d7c
  		 * are part of a mapping, and we are going to do a blocking
ee42d7c
  		 * wait here.  Need to update the screen to display the
ee42d7c
! 		 * changed text so far. Also for when 'lazyredraw' is set and
ee42d7c
! 		 * redrawing was postponed because there was something in the
ee42d7c
! 		 * input buffer (e.g., termresponse). */
ee42d7c
! 		if (((State & INSERT) || p_lz) && advance && must_redraw != 0)
ee42d7c
  		{
ee42d7c
  		    update_screen(0);
ee42d7c
  		    setcursor(); /* put cursor back where it belongs */
ee42d7c
*** ../vim-7.3.136/src/version.c	2011-03-03 15:01:25.000000000 +0100
ee42d7c
--- src/version.c	2011-03-03 15:02:45.000000000 +0100
ee42d7c
***************
ee42d7c
*** 716,717 ****
ee42d7c
--- 716,719 ----
ee42d7c
  {   /* Add new patch number below this line */
ee42d7c
+ /**/
ee42d7c
+     137,
ee42d7c
  /**/
ee42d7c
ee42d7c
-- 
ee42d7c
ARTHUR:        What?
ee42d7c
BLACK KNIGHT:  None shall pass.
ee42d7c
ARTHUR:        I have no quarrel with you, good Sir knight, but I must cross
ee42d7c
               this bridge.
ee42d7c
BLACK KNIGHT:  Then you shall die.
ee42d7c
                                  The Quest for the Holy Grail (Monty Python)
ee42d7c
ee42d7c
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
ee42d7c
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
ee42d7c
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
ee42d7c
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///