]> git.wh0rd.org Git - nano.git/commitdiff
in print_opt_full(), use strlenpt() instead of strlen(), so that tabs
authorDavid Lawrence Ramsey <pooka109@gmail.com>
Tue, 18 Dec 2007 22:00:17 +0000 (22:00 +0000)
committerDavid Lawrence Ramsey <pooka109@gmail.com>
Tue, 18 Dec 2007 22:00:17 +0000 (22:00 +0000)
are placed properly when displaying translated strings in UTF-8, as
found by Jean-Philippe Guérard

git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4208 35c25a1d-7b9e-4130-9fde-d3aeb78583b8

ChangeLog
src/nano.c

index 3329b8efcb4106c794aba1a1f0d511d9cc7e2b21..f7ec7facec9acec965f9a6ffdfc88781b6ba231b 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2007-12-18  David Lawrence Ramsey  <pooka109@gmail.com>
+
+       * nano.c (print_opt_full): Use strlenpt() instead of strlen(),
+       so that tabs are placed properly when displaying translated
+       strings in UTF-8, as found by Jean-Philippe Guérard.
+
 2007-12-17  David Lawrence Ramsey  <pooka109@gmail.com>
 
        * configure.ac, doc/texinfo/nano.texi, nano.c (terminal_init):
index 6ec46014328c79b1536992b42c0924f4b47f549c..b676fc93cc6d58ff5c0a280c5e1b7c2e61f87f77 100644 (file)
@@ -752,14 +752,14 @@ void print_opt_full(const char *shortflag
        , const char *desc)
 {
     printf(" %s\t", shortflag);
-    if (strlen(shortflag) < 8)
+    if (strlenpt(shortflag) < 8)
        printf("\t");
 
 #ifdef HAVE_GETOPT_LONG
     printf("%s\t", longflag);
-    if (strlen(longflag) < 8)
+    if (strlenpt(longflag) < 8)
        printf("\t\t");
-    else if (strlen(longflag) < 16)
+    else if (strlenpt(longflag) < 16)
        printf("\t");
 #endif