99b86a7
To: vim-dev@vim.org
99b86a7
Subject: Patch 7.1.190
99b86a7
Fcc: outbox
99b86a7
From: Bram Moolenaar <Bram@moolenaar.net>
99b86a7
Mime-Version: 1.0
99b86a7
Content-Type: text/plain; charset=ISO-8859-1
99b86a7
Content-Transfer-Encoding: 8bit
99b86a7
------------
99b86a7
99b86a7
Patch 7.1.190
99b86a7
Problem:    Cursor after end-of-line: "iA sentence.<Esc>)"
99b86a7
Solution:   Move cursor back and make motion inclusive.
99b86a7
Files:	    src/normal.c
99b86a7
99b86a7
99b86a7
*** ../vim-7.1.189/src/normal.c	Wed Jan  2 16:25:20 2008
99b86a7
--- src/normal.c	Wed Jan  2 22:04:38 2008
99b86a7
***************
99b86a7
*** 6564,6569 ****
99b86a7
--- 6564,6575 ----
99b86a7
  	clearopbeep(cap->oap);
99b86a7
      else
99b86a7
      {
99b86a7
+ 	/* Don't leave the cursor on the NUL past a line */
99b86a7
+ 	if (curwin->w_cursor.col > 0 && gchar_cursor() == NUL)
99b86a7
+ 	{
99b86a7
+ 	    --curwin->w_cursor.col;
99b86a7
+ 	    cap->oap->inclusive = TRUE;
99b86a7
+ 	}
99b86a7
  #ifdef FEAT_VIRTUALEDIT
99b86a7
  	curwin->w_cursor.coladd = 0;
99b86a7
  #endif
99b86a7
*** ../vim-7.1.189/src/version.c	Thu Jan  3 12:42:39 2008
99b86a7
--- src/version.c	Thu Jan  3 13:19:03 2008
99b86a7
***************
99b86a7
*** 668,669 ****
99b86a7
--- 668,671 ----
99b86a7
  {   /* Add new patch number below this line */
99b86a7
+ /**/
99b86a7
+     190,
99b86a7
  /**/
99b86a7
99b86a7
-- 
99b86a7
    [clop clop]
99b86a7
GUARD #1:  Halt!  Who goes there?
99b86a7
ARTHUR:    It is I, Arthur, son of Uther Pendragon, from the castle of
99b86a7
           Camelot.  King of the Britons, defeator of the Saxons, sovereign of
99b86a7
           all England!
99b86a7
GUARD #1:  Pull the other one!
99b86a7
                                  The Quest for the Holy Grail (Monty Python)
99b86a7
99b86a7
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
99b86a7
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
99b86a7
\\\        download, build and distribute -- http://www.A-A-P.org        ///
99b86a7
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///