|
Karsten Hopp |
ec88fe |
To: vim_dev@googlegroups.com
|
|
Karsten Hopp |
ec88fe |
Subject: Patch 7.4.067
|
|
Karsten Hopp |
ec88fe |
Fcc: outbox
|
|
Karsten Hopp |
ec88fe |
From: Bram Moolenaar <Bram@moolenaar.net>
|
|
Karsten Hopp |
ec88fe |
Mime-Version: 1.0
|
|
Karsten Hopp |
ec88fe |
Content-Type: text/plain; charset=UTF-8
|
|
Karsten Hopp |
ec88fe |
Content-Transfer-Encoding: 8bit
|
|
Karsten Hopp |
ec88fe |
------------
|
|
Karsten Hopp |
ec88fe |
|
|
Karsten Hopp |
ec88fe |
Patch 7.4.067
|
|
Karsten Hopp |
ec88fe |
Problem: After inserting comment leader, CTRL-\ CTRL-O does move the
|
|
Karsten Hopp |
ec88fe |
cursor. (Wiktor Ruben)
|
|
Karsten Hopp |
ec88fe |
Solution: Avoid moving the cursor. (Christian Brabandt)
|
|
Karsten Hopp |
ec88fe |
Files: src/edit.c
|
|
Karsten Hopp |
ec88fe |
|
|
Karsten Hopp |
ec88fe |
|
|
Karsten Hopp |
ec88fe |
*** ../vim-7.4.066/src/edit.c 2013-09-08 20:00:45.000000000 +0200
|
|
Karsten Hopp |
ec88fe |
--- src/edit.c 2013-11-04 03:57:43.000000000 +0100
|
|
Karsten Hopp |
ec88fe |
***************
|
|
Karsten Hopp |
ec88fe |
*** 199,205 ****
|
|
Karsten Hopp |
ec88fe |
static void spell_back_to_badword __ARGS((void));
|
|
Karsten Hopp |
ec88fe |
static int spell_bad_len = 0; /* length of located bad word */
|
|
Karsten Hopp |
ec88fe |
#endif
|
|
Karsten Hopp |
ec88fe |
! static void stop_insert __ARGS((pos_T *end_insert_pos, int esc));
|
|
Karsten Hopp |
ec88fe |
static int echeck_abbr __ARGS((int));
|
|
Karsten Hopp |
ec88fe |
static int replace_pop __ARGS((void));
|
|
Karsten Hopp |
ec88fe |
static void replace_join __ARGS((int off));
|
|
Karsten Hopp |
ec88fe |
--- 199,205 ----
|
|
Karsten Hopp |
ec88fe |
static void spell_back_to_badword __ARGS((void));
|
|
Karsten Hopp |
ec88fe |
static int spell_bad_len = 0; /* length of located bad word */
|
|
Karsten Hopp |
ec88fe |
#endif
|
|
Karsten Hopp |
ec88fe |
! static void stop_insert __ARGS((pos_T *end_insert_pos, int esc, int nomove));
|
|
Karsten Hopp |
ec88fe |
static int echeck_abbr __ARGS((int));
|
|
Karsten Hopp |
ec88fe |
static int replace_pop __ARGS((void));
|
|
Karsten Hopp |
ec88fe |
static void replace_join __ARGS((int off));
|
|
Karsten Hopp |
ec88fe |
***************
|
|
Karsten Hopp |
ec88fe |
*** 6698,6704 ****
|
|
Karsten Hopp |
ec88fe |
if (!arrow_used) /* something has been inserted */
|
|
Karsten Hopp |
ec88fe |
{
|
|
Karsten Hopp |
ec88fe |
AppendToRedobuff(ESC_STR);
|
|
Karsten Hopp |
ec88fe |
! stop_insert(end_insert_pos, FALSE);
|
|
Karsten Hopp |
ec88fe |
arrow_used = TRUE; /* this means we stopped the current insert */
|
|
Karsten Hopp |
ec88fe |
}
|
|
Karsten Hopp |
ec88fe |
#ifdef FEAT_SPELL
|
|
Karsten Hopp |
ec88fe |
--- 6698,6704 ----
|
|
Karsten Hopp |
ec88fe |
if (!arrow_used) /* something has been inserted */
|
|
Karsten Hopp |
ec88fe |
{
|
|
Karsten Hopp |
ec88fe |
AppendToRedobuff(ESC_STR);
|
|
Karsten Hopp |
ec88fe |
! stop_insert(end_insert_pos, FALSE, FALSE);
|
|
Karsten Hopp |
ec88fe |
arrow_used = TRUE; /* this means we stopped the current insert */
|
|
Karsten Hopp |
ec88fe |
}
|
|
Karsten Hopp |
ec88fe |
#ifdef FEAT_SPELL
|
|
Karsten Hopp |
ec88fe |
***************
|
|
Karsten Hopp |
ec88fe |
*** 6787,6795 ****
|
|
Karsten Hopp |
ec88fe |
* to another window/buffer.
|
|
Karsten Hopp |
ec88fe |
*/
|
|
Karsten Hopp |
ec88fe |
static void
|
|
Karsten Hopp |
ec88fe |
! stop_insert(end_insert_pos, esc)
|
|
Karsten Hopp |
ec88fe |
pos_T *end_insert_pos;
|
|
Karsten Hopp |
ec88fe |
int esc; /* called by ins_esc() */
|
|
Karsten Hopp |
ec88fe |
{
|
|
Karsten Hopp |
ec88fe |
int cc;
|
|
Karsten Hopp |
ec88fe |
char_u *ptr;
|
|
Karsten Hopp |
ec88fe |
--- 6787,6796 ----
|
|
Karsten Hopp |
ec88fe |
* to another window/buffer.
|
|
Karsten Hopp |
ec88fe |
*/
|
|
Karsten Hopp |
ec88fe |
static void
|
|
Karsten Hopp |
ec88fe |
! stop_insert(end_insert_pos, esc, nomove)
|
|
Karsten Hopp |
ec88fe |
pos_T *end_insert_pos;
|
|
Karsten Hopp |
ec88fe |
int esc; /* called by ins_esc() */
|
|
Karsten Hopp |
ec88fe |
+ int nomove; /* <c-\><c-o>, don't move cursor */
|
|
Karsten Hopp |
ec88fe |
{
|
|
Karsten Hopp |
ec88fe |
int cc;
|
|
Karsten Hopp |
ec88fe |
char_u *ptr;
|
|
Karsten Hopp |
ec88fe |
***************
|
|
Karsten Hopp |
ec88fe |
*** 6860,6866 ****
|
|
Karsten Hopp |
ec88fe |
* Do this when ESC was used or moving the cursor up/down.
|
|
Karsten Hopp |
ec88fe |
* Check for the old position still being valid, just in case the text
|
|
Karsten Hopp |
ec88fe |
* got changed unexpectedly. */
|
|
Karsten Hopp |
ec88fe |
! if (did_ai && (esc || (vim_strchr(p_cpo, CPO_INDENT) == NULL
|
|
Karsten Hopp |
ec88fe |
&& curwin->w_cursor.lnum != end_insert_pos->lnum))
|
|
Karsten Hopp |
ec88fe |
&& end_insert_pos->lnum <= curbuf->b_ml.ml_line_count)
|
|
Karsten Hopp |
ec88fe |
{
|
|
Karsten Hopp |
ec88fe |
--- 6861,6867 ----
|
|
Karsten Hopp |
ec88fe |
* Do this when ESC was used or moving the cursor up/down.
|
|
Karsten Hopp |
ec88fe |
* Check for the old position still being valid, just in case the text
|
|
Karsten Hopp |
ec88fe |
* got changed unexpectedly. */
|
|
Karsten Hopp |
ec88fe |
! if (!nomove && did_ai && (esc || (vim_strchr(p_cpo, CPO_INDENT) == NULL
|
|
Karsten Hopp |
ec88fe |
&& curwin->w_cursor.lnum != end_insert_pos->lnum))
|
|
Karsten Hopp |
ec88fe |
&& end_insert_pos->lnum <= curbuf->b_ml.ml_line_count)
|
|
Karsten Hopp |
ec88fe |
{
|
|
Karsten Hopp |
ec88fe |
***************
|
|
Karsten Hopp |
ec88fe |
*** 8377,8383 ****
|
|
Karsten Hopp |
ec88fe |
disabled_redraw = TRUE;
|
|
Karsten Hopp |
ec88fe |
return FALSE; /* repeat the insert */
|
|
Karsten Hopp |
ec88fe |
}
|
|
Karsten Hopp |
ec88fe |
! stop_insert(&curwin->w_cursor, TRUE);
|
|
Karsten Hopp |
ec88fe |
undisplay_dollar();
|
|
Karsten Hopp |
ec88fe |
}
|
|
Karsten Hopp |
ec88fe |
|
|
Karsten Hopp |
ec88fe |
--- 8378,8384 ----
|
|
Karsten Hopp |
ec88fe |
disabled_redraw = TRUE;
|
|
Karsten Hopp |
ec88fe |
return FALSE; /* repeat the insert */
|
|
Karsten Hopp |
ec88fe |
}
|
|
Karsten Hopp |
ec88fe |
! stop_insert(&curwin->w_cursor, TRUE, nomove);
|
|
Karsten Hopp |
ec88fe |
undisplay_dollar();
|
|
Karsten Hopp |
ec88fe |
}
|
|
Karsten Hopp |
ec88fe |
|
|
Karsten Hopp |
ec88fe |
*** ../vim-7.4.066/src/version.c 2013-11-04 02:53:46.000000000 +0100
|
|
Karsten Hopp |
ec88fe |
--- src/version.c 2013-11-04 03:57:29.000000000 +0100
|
|
Karsten Hopp |
ec88fe |
***************
|
|
Karsten Hopp |
ec88fe |
*** 740,741 ****
|
|
Karsten Hopp |
ec88fe |
--- 740,743 ----
|
|
Karsten Hopp |
ec88fe |
{ /* Add new patch number below this line */
|
|
Karsten Hopp |
ec88fe |
+ /**/
|
|
Karsten Hopp |
ec88fe |
+ 67,
|
|
Karsten Hopp |
ec88fe |
/**/
|
|
Karsten Hopp |
ec88fe |
|
|
Karsten Hopp |
ec88fe |
--
|
|
Karsten Hopp |
ec88fe |
Beer & pretzels can't be served at the same time in any bar or restaurant.
|
|
Karsten Hopp |
ec88fe |
[real standing law in North Dakota, United States of America]
|
|
Karsten Hopp |
ec88fe |
|
|
Karsten Hopp |
ec88fe |
/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
|
|
Karsten Hopp |
ec88fe |
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
|
|
Karsten Hopp |
ec88fe |
\\\ an exciting new programming language -- http://www.Zimbu.org ///
|
|
Karsten Hopp |
ec88fe |
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
|