public
Created

  • Download Gist
gistfile1
1 2 3 4 5 6 7 8 9 10 11 12 13 14
diff -r 8b86b69546a9 src/ops.c
--- a/src/ops.c Wed Feb 20 21:26:00 2013 +0100
+++ b/src/ops.c Thu Feb 28 14:41:31 2013 +0900
@@ -2194,7 +2194,9 @@
{
/* This is slow, but it handles replacing a single-byte
* with a multi-byte and the other way around. */
- oap->end.col += (*mb_char2len)(c) - (*mb_char2len)(n);
+
+ if (curwin->w_cursor.lnum == oap->end.lnum)
+ oap->end.col += (*mb_char2len)(c) - (*mb_char2len)(n);
n = State;
State = REPLACE;
ins_char(c);

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.