Mercurial > vim
diff src/fileio.c @ 14585:c8f07e8b273e v8.1.0306
patch 8.1.0306: plural messages are not translated properly
commit https://github.com/vim/vim/commit/da6e8919e75fa8f961d1b805e877c8a92e76dafb
Author: Bram Moolenaar <Bram@vim.org>
Date: Tue Aug 21 15:12:14 2018 +0200
patch 8.1.0306: plural messages are not translated properly
Problem: Plural messages are not translated properly.
Solution: Add more usage of NGETTEXT(). (Sergey Alyoshin)
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Tue, 21 Aug 2018 15:15:06 +0200 |
parents | 80f715651c4c |
children | 0a3b9ecf7cb8 |
line wrap: on
line diff
--- a/src/fileio.c +++ b/src/fileio.c @@ -5349,16 +5349,11 @@ msg_add_lines( "%ldL, %lldC", lnum, (long long)nchars); else { - if (lnum == 1) - STRCPY(p, _("1 line, ")); - else - sprintf((char *)p, _("%ld lines, "), lnum); + sprintf((char *)p, NGETTEXT("%ld line, ", "%ld lines, ", lnum), lnum); p += STRLEN(p); - if (nchars == 1) - STRCPY(p, _("1 character")); - else - vim_snprintf((char *)p, IOSIZE - (p - IObuff), - _("%lld characters"), (long long)nchars); + vim_snprintf((char *)p, IOSIZE - (p - IObuff), + NGETTEXT("%lld character", "%lld characters", nchars), + (long long)nchars); } }