diff --git a/Changes b/Changes index a8ea341..3d25898 100644 --- a/Changes +++ b/Changes @@ -13,6 +13,8 @@ Release ... the end of the new text. * Visual 'U' followed by 'u' lead to garbage on the screen when multibyte characters were present on the changed line. +* The position of '$' when changing text was fixed for cases where the first + changed character had multiple columns but the last one had not. * The handling of multicolumn characters was fixed for terminals without the IM (insert mode) capability. It is unlikely that such terminals actually exist, but vi will use the corresponding code for open mode if a termcap diff --git a/ex_vops.c b/ex_vops.c index 4a6816a..4d28fac 100644 --- a/ex_vops.c +++ b/ex_vops.c @@ -73,7 +73,7 @@ #ifndef lint #ifdef DOSCCS -static char sccsid[] = "@(#)ex_vops.c 1.25 (gritter) 1/11/05"; +static char sccsid[] = "@(#)ex_vops.c 1.26 (gritter) 1/13/05"; #endif #endif @@ -671,9 +671,10 @@ smallchange: if (state == HARDOPEN) bleep(i, cp); else { - int c, n; + int c, d, n; vcursbef(wcursor); - nextc(c, cursor, n); + d = skipleft(linebuf, wcursor); + nextc(c, &wcursor[d], n); if (colsc(c) > 1) putchar(' '); putchar('$');