|
Karsten Hopp |
ceaab2 |
To: vim_dev@googlegroups.com
|
|
Karsten Hopp |
ceaab2 |
Subject: Patch 7.3.853
|
|
Karsten Hopp |
ceaab2 |
Fcc: outbox
|
|
Karsten Hopp |
ceaab2 |
From: Bram Moolenaar <Bram@moolenaar.net>
|
|
Karsten Hopp |
ceaab2 |
Mime-Version: 1.0
|
|
Karsten Hopp |
ceaab2 |
Content-Type: text/plain; charset=UTF-8
|
|
Karsten Hopp |
ceaab2 |
Content-Transfer-Encoding: 8bit
|
|
Karsten Hopp |
ceaab2 |
------------
|
|
Karsten Hopp |
ceaab2 |
|
|
Karsten Hopp |
ceaab2 |
Patch 7.3.853
|
|
Karsten Hopp |
ceaab2 |
Problem: Using "ra" in multiple lines on multi-byte characters leaves a few
|
|
Karsten Hopp |
ceaab2 |
characters not replaced.
|
|
Karsten Hopp |
ceaab2 |
Solution: Adjust the end column only in the last line. (Yasuhiro Matsumoto)
|
|
Karsten Hopp |
ceaab2 |
Files: src/testdir/test69.in, src/testdir/test69.ok, src/ops.c
|
|
Karsten Hopp |
ceaab2 |
|
|
Karsten Hopp |
ceaab2 |
|
|
Karsten Hopp |
ceaab2 |
*** ../vim-7.3.852/src/testdir/test69.in 2013-01-17 17:01:57.000000000 +0100
|
|
Karsten Hopp |
ceaab2 |
--- src/testdir/test69.in 2013-03-07 18:30:50.000000000 +0100
|
|
Karsten Hopp |
ceaab2 |
***************
|
|
Karsten Hopp |
ceaab2 |
*** 1,5 ****
|
|
Karsten Hopp |
ceaab2 |
--- 1,6 ----
|
|
Karsten Hopp |
ceaab2 |
Test for multi-byte text formatting.
|
|
Karsten Hopp |
ceaab2 |
Also test, that 'mps' with multibyte chars works.
|
|
Karsten Hopp |
ceaab2 |
+ And test "ra" on multi-byte characters.
|
|
Karsten Hopp |
ceaab2 |
|
|
Karsten Hopp |
ceaab2 |
STARTTEST
|
|
Karsten Hopp |
ceaab2 |
:so mbyte.vim
|
|
Karsten Hopp |
ceaab2 |
***************
|
|
Karsten Hopp |
ceaab2 |
*** 144,149 ****
|
|
Karsten Hopp |
ceaab2 |
--- 145,159 ----
|
|
Karsten Hopp |
ceaab2 |
‘ two three ’ four
|
|
Karsten Hopp |
ceaab2 |
}
|
|
Karsten Hopp |
ceaab2 |
STARTTEST
|
|
Karsten Hopp |
ceaab2 |
+ /^ra test
|
|
Karsten Hopp |
ceaab2 |
+ jVjra
|
|
Karsten Hopp |
ceaab2 |
+ ENDTEST
|
|
Karsten Hopp |
ceaab2 |
+
|
|
Karsten Hopp |
ceaab2 |
+ ra test
|
|
Karsten Hopp |
ceaab2 |
+ abba
|
|
Karsten Hopp |
ceaab2 |
+ aab
|
|
Karsten Hopp |
ceaab2 |
+
|
|
Karsten Hopp |
ceaab2 |
+ STARTTEST
|
|
Karsten Hopp |
ceaab2 |
:g/^STARTTEST/.,/^ENDTEST/d
|
|
Karsten Hopp |
ceaab2 |
:1;/^Results/,$wq! test.out
|
|
Karsten Hopp |
ceaab2 |
ENDTEST
|
|
Karsten Hopp |
ceaab2 |
*** ../vim-7.3.852/src/testdir/test69.ok 2013-01-17 17:01:57.000000000 +0100
|
|
Karsten Hopp |
ceaab2 |
--- src/testdir/test69.ok 2013-03-07 18:31:32.000000000 +0100
|
|
Karsten Hopp |
ceaab2 |
***************
|
|
Karsten Hopp |
ceaab2 |
*** 144,146 ****
|
|
Karsten Hopp |
ceaab2 |
--- 144,151 ----
|
|
Karsten Hopp |
ceaab2 |
{
|
|
Karsten Hopp |
ceaab2 |
four
|
|
Karsten Hopp |
ceaab2 |
}
|
|
Karsten Hopp |
ceaab2 |
+
|
|
Karsten Hopp |
ceaab2 |
+ ra test
|
|
Karsten Hopp |
ceaab2 |
+ aaaa
|
|
Karsten Hopp |
ceaab2 |
+ aaa
|
|
Karsten Hopp |
ceaab2 |
+
|
|
Karsten Hopp |
ceaab2 |
*** ../vim-7.3.852/src/ops.c 2013-03-07 18:02:27.000000000 +0100
|
|
Karsten Hopp |
ceaab2 |
--- src/ops.c 2013-03-07 18:35:01.000000000 +0100
|
|
Karsten Hopp |
ceaab2 |
***************
|
|
Karsten Hopp |
ceaab2 |
*** 2194,2200 ****
|
|
Karsten Hopp |
ceaab2 |
{
|
|
Karsten Hopp |
ceaab2 |
/* This is slow, but it handles replacing a single-byte
|
|
Karsten Hopp |
ceaab2 |
* with a multi-byte and the other way around. */
|
|
Karsten Hopp |
ceaab2 |
! oap->end.col += (*mb_char2len)(c) - (*mb_char2len)(n);
|
|
Karsten Hopp |
ceaab2 |
n = State;
|
|
Karsten Hopp |
ceaab2 |
State = REPLACE;
|
|
Karsten Hopp |
ceaab2 |
ins_char(c);
|
|
Karsten Hopp |
ceaab2 |
--- 2194,2201 ----
|
|
Karsten Hopp |
ceaab2 |
{
|
|
Karsten Hopp |
ceaab2 |
/* This is slow, but it handles replacing a single-byte
|
|
Karsten Hopp |
ceaab2 |
* with a multi-byte and the other way around. */
|
|
Karsten Hopp |
ceaab2 |
! if (curwin->w_cursor.lnum == oap->end.lnum)
|
|
Karsten Hopp |
ceaab2 |
! oap->end.col += (*mb_char2len)(c) - (*mb_char2len)(n);
|
|
Karsten Hopp |
ceaab2 |
n = State;
|
|
Karsten Hopp |
ceaab2 |
State = REPLACE;
|
|
Karsten Hopp |
ceaab2 |
ins_char(c);
|
|
Karsten Hopp |
ceaab2 |
*** ../vim-7.3.852/src/version.c 2013-03-07 18:02:27.000000000 +0100
|
|
Karsten Hopp |
ceaab2 |
--- src/version.c 2013-03-07 18:36:46.000000000 +0100
|
|
Karsten Hopp |
ceaab2 |
***************
|
|
Karsten Hopp |
ceaab2 |
*** 730,731 ****
|
|
Karsten Hopp |
ceaab2 |
--- 730,733 ----
|
|
Karsten Hopp |
ceaab2 |
{ /* Add new patch number below this line */
|
|
Karsten Hopp |
ceaab2 |
+ /**/
|
|
Karsten Hopp |
ceaab2 |
+ 853,
|
|
Karsten Hopp |
ceaab2 |
/**/
|
|
Karsten Hopp |
ceaab2 |
|
|
Karsten Hopp |
ceaab2 |
--
|
|
Karsten Hopp |
ceaab2 |
What a wonderfully exciting cough! Do you mind if I join you?
|
|
Karsten Hopp |
ceaab2 |
-- Douglas Adams, "The Hitchhiker's Guide to the Galaxy"
|
|
Karsten Hopp |
ceaab2 |
|
|
Karsten Hopp |
ceaab2 |
/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
|
|
Karsten Hopp |
ceaab2 |
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
|
|
Karsten Hopp |
ceaab2 |
\\\ an exciting new programming language -- http://www.Zimbu.org ///
|
|
Karsten Hopp |
ceaab2 |
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
|