|
Karsten Hopp |
750d54 |
To: vim_dev@googlegroups.com
|
|
Karsten Hopp |
750d54 |
Subject: Patch 7.3.502
|
|
Karsten Hopp |
750d54 |
Fcc: outbox
|
|
Karsten Hopp |
750d54 |
From: Bram Moolenaar <Bram@moolenaar.net>
|
|
Karsten Hopp |
750d54 |
Mime-Version: 1.0
|
|
Karsten Hopp |
750d54 |
Content-Type: text/plain; charset=UTF-8
|
|
Karsten Hopp |
750d54 |
Content-Transfer-Encoding: 8bit
|
|
Karsten Hopp |
750d54 |
------------
|
|
Karsten Hopp |
750d54 |
|
|
Karsten Hopp |
750d54 |
Patch 7.3.502
|
|
Karsten Hopp |
750d54 |
Problem: Netbeans insert halfway a line actually appends to the line.
|
|
Karsten Hopp |
750d54 |
Solution: Insert halfway the line. (Brian Victor)
|
|
Karsten Hopp |
750d54 |
Files: src/netbeans.c
|
|
Karsten Hopp |
750d54 |
|
|
Karsten Hopp |
750d54 |
|
|
Karsten Hopp |
750d54 |
*** ../vim-7.3.501/src/netbeans.c 2012-01-10 22:31:26.000000000 +0100
|
|
Karsten Hopp |
750d54 |
--- src/netbeans.c 2012-04-20 19:44:31.000000000 +0200
|
|
Karsten Hopp |
750d54 |
***************
|
|
Karsten Hopp |
750d54 |
*** 1812,1825 ****
|
|
Karsten Hopp |
750d54 |
char_u *oldline = ml_get(lnum);
|
|
Karsten Hopp |
750d54 |
char_u *newline;
|
|
Karsten Hopp |
750d54 |
|
|
Karsten Hopp |
750d54 |
! /* Insert halfway a line. For simplicity we assume we
|
|
Karsten Hopp |
750d54 |
! * need to append to the line. */
|
|
Karsten Hopp |
750d54 |
newline = alloc_check(
|
|
Karsten Hopp |
750d54 |
(unsigned)(STRLEN(oldline) + len + 1));
|
|
Karsten Hopp |
750d54 |
if (newline != NULL)
|
|
Karsten Hopp |
750d54 |
{
|
|
Karsten Hopp |
750d54 |
! STRCPY(newline, oldline);
|
|
Karsten Hopp |
750d54 |
STRCAT(newline, args);
|
|
Karsten Hopp |
750d54 |
ml_replace(lnum, newline, FALSE);
|
|
Karsten Hopp |
750d54 |
}
|
|
Karsten Hopp |
750d54 |
}
|
|
Karsten Hopp |
750d54 |
--- 1812,1826 ----
|
|
Karsten Hopp |
750d54 |
char_u *oldline = ml_get(lnum);
|
|
Karsten Hopp |
750d54 |
char_u *newline;
|
|
Karsten Hopp |
750d54 |
|
|
Karsten Hopp |
750d54 |
! /* Insert halfway a line. */
|
|
Karsten Hopp |
750d54 |
newline = alloc_check(
|
|
Karsten Hopp |
750d54 |
(unsigned)(STRLEN(oldline) + len + 1));
|
|
Karsten Hopp |
750d54 |
if (newline != NULL)
|
|
Karsten Hopp |
750d54 |
{
|
|
Karsten Hopp |
750d54 |
! mch_memmove(newline, oldline, (size_t)pos->col);
|
|
Karsten Hopp |
750d54 |
! newline[pos->col] = NUL;
|
|
Karsten Hopp |
750d54 |
STRCAT(newline, args);
|
|
Karsten Hopp |
750d54 |
+ STRCAT(newline, oldline + pos->col);
|
|
Karsten Hopp |
750d54 |
ml_replace(lnum, newline, FALSE);
|
|
Karsten Hopp |
750d54 |
}
|
|
Karsten Hopp |
750d54 |
}
|
|
Karsten Hopp |
750d54 |
*** ../vim-7.3.501/src/version.c 2012-04-20 18:05:42.000000000 +0200
|
|
Karsten Hopp |
750d54 |
--- src/version.c 2012-04-20 19:46:48.000000000 +0200
|
|
Karsten Hopp |
750d54 |
***************
|
|
Karsten Hopp |
750d54 |
*** 716,717 ****
|
|
Karsten Hopp |
750d54 |
--- 716,719 ----
|
|
Karsten Hopp |
750d54 |
{ /* Add new patch number below this line */
|
|
Karsten Hopp |
750d54 |
+ /**/
|
|
Karsten Hopp |
750d54 |
+ 502,
|
|
Karsten Hopp |
750d54 |
/**/
|
|
Karsten Hopp |
750d54 |
|
|
Karsten Hopp |
750d54 |
--
|
|
Karsten Hopp |
750d54 |
Time flies like an arrow.
|
|
Karsten Hopp |
750d54 |
Fruit flies like a banana.
|
|
Karsten Hopp |
750d54 |
|
|
Karsten Hopp |
750d54 |
/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
|
|
Karsten Hopp |
750d54 |
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
|
|
Karsten Hopp |
750d54 |
\\\ an exciting new programming language -- http://www.Zimbu.org ///
|
|
Karsten Hopp |
750d54 |
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
|