5d8ab8d
To: vim-dev@vim.org
5d8ab8d
Subject: Patch 7.2.255
5d8ab8d
Fcc: outbox
5d8ab8d
From: Bram Moolenaar <Bram@moolenaar.net>
5d8ab8d
Mime-Version: 1.0
5d8ab8d
Content-Type: text/plain; charset=UTF-8
5d8ab8d
Content-Transfer-Encoding: 8bit
5d8ab8d
------------
5d8ab8d
5d8ab8d
Patch 7.2.255 (after 7.2.242)
5d8ab8d
Problem:    Setting 'rightleft', 'linebreak' and 'wrap' may cause cursor to be
5d8ab8d
	    in wrong place.
5d8ab8d
Solution:   Recompute the cursor column for these options.
5d8ab8d
Files:	    src/option.c
5d8ab8d
5d8ab8d
5d8ab8d
*** ../vim-7.2.254/src/option.c	2009-07-29 15:41:32.000000000 +0200
5d8ab8d
--- src/option.c	2009-09-11 13:59:55.000000000 +0200
5d8ab8d
***************
5d8ab8d
*** 7430,7435 ****
5d8ab8d
--- 7430,7437 ----
5d8ab8d
      {
5d8ab8d
  	if (curwin->w_p_wrap)
5d8ab8d
  	    curwin->w_leftcol = 0;
5d8ab8d
+ 	if (curwin->w_curswant != MAXCOL)
5d8ab8d
+ 	    curwin->w_set_curswant = TRUE;
5d8ab8d
      }
5d8ab8d
  
5d8ab8d
  #ifdef FEAT_WINDOWS
5d8ab8d
***************
5d8ab8d
*** 7664,7669 ****
5d8ab8d
--- 7666,7687 ----
5d8ab8d
      }
5d8ab8d
  #endif
5d8ab8d
  
5d8ab8d
+ #ifdef FEAT_LINEBREAK
5d8ab8d
+     if ((int *)varp == &curwin->w_p_lbr)
5d8ab8d
+     {
5d8ab8d
+ 	if (curwin->w_curswant != MAXCOL)
5d8ab8d
+ 	    curwin->w_set_curswant = TRUE;
5d8ab8d
+     }
5d8ab8d
+ #endif
5d8ab8d
+ 
5d8ab8d
+ #ifdef FEAT_RIGHTLEFT
5d8ab8d
+     if ((int *)varp == &curwin->w_p_rl)
5d8ab8d
+     {
5d8ab8d
+ 	if (curwin->w_curswant != MAXCOL)
5d8ab8d
+ 	    curwin->w_set_curswant = TRUE;
5d8ab8d
+     }
5d8ab8d
+ #endif
5d8ab8d
+ 
5d8ab8d
      /*
5d8ab8d
       * End of handling side effects for bool options.
5d8ab8d
       */
5d8ab8d
*** ../vim-7.2.254/src/version.c	2009-09-11 15:04:13.000000000 +0200
5d8ab8d
--- src/version.c	2009-09-11 15:19:40.000000000 +0200
5d8ab8d
***************
5d8ab8d
*** 678,679 ****
5d8ab8d
--- 678,681 ----
5d8ab8d
  {   /* Add new patch number below this line */
5d8ab8d
+ /**/
5d8ab8d
+     255,
5d8ab8d
  /**/
5d8ab8d
5d8ab8d
-- 
5d8ab8d
A computer without Windows is like a fish without a bicycle.
5d8ab8d
5d8ab8d
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
5d8ab8d
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
5d8ab8d
\\\        download, build and distribute -- http://www.A-A-P.org        ///
5d8ab8d
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///