Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/external/bsd/nvi/dist/common As described in comments, we tr...



details:   https://anonhg.NetBSD.org/src/rev/12f038c4da50
branches:  trunk
changeset: 365099:12f038c4da50
user:      rin <rin%NetBSD.org@localhost>
date:      Wed Aug 01 02:48:47 2018 +0000

description:
As described in comments, we treat non-spacing chars as single-width ones.

diffstat:

 external/bsd/nvi/dist/common/conv.h |  4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diffs (17 lines):

diff -r de6149d10393 -r 12f038c4da50 external/bsd/nvi/dist/common/conv.h
--- a/external/bsd/nvi/dist/common/conv.h       Wed Aug 01 00:07:27 2018 +0000
+++ b/external/bsd/nvi/dist/common/conv.h       Wed Aug 01 02:48:47 2018 +0000
@@ -1,11 +1,11 @@
-/*     $NetBSD: conv.h,v 1.3 2018/06/03 08:08:36 rin Exp $     */
+/*     $NetBSD: conv.h,v 1.4 2018/08/01 02:48:47 rin Exp $     */
 
 /*
  * We ensure that every wide char occupies at least one display width.
  * See vs_line.c for more details.
  */
 #define WIDE_COL(sp, ch)                                               \
-       (CHAR_WIDTH(sp, ch) >= 0 ? CHAR_WIDTH(sp, ch) : 1)
+       (CHAR_WIDTH(sp, ch) > 0 ? CHAR_WIDTH(sp, ch) : 1)
 
 #define KEY_COL(sp, ch)                                                        \
        (INTISWIDE(ch) ? (size_t)WIDE_COL(sp, ch) : KEY_LEN(sp, ch))



Home | Main Index | Thread Index | Old Index