all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Paul Eggert <eggert@cs.ucla.edu>
To: Stefan Kangas <stefan@marxist.se>
Cc: "Basil L. Contovounesios" <contovob@tcd.ie>, 35981-done@debbugs.gnu.org
Subject: bug#35981: [PATCH] Use ngettext in `count-lines-page'
Date: Sun, 9 Jun 2019 17:03:52 -0700	[thread overview]
Message-ID: <12809efa-ea54-d399-84c2-4fce74ab42f2@cs.ucla.edu> (raw)
In-Reply-To: <CADwFkmnnnvaimo2hc=pZtFRkOfuky5KZLq=ueFgFgh3mQX2Kpw@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 299 bytes --]

When a diagnostic this short it's typically more straightforward to give 
the translators the whole diagnostic than to ask them to figure out how 
it's pieced together and to restrict their translations algorithmically, 
so I installed the attached patch instead. Thanks for reporting the problem.


[-- Attachment #2: 0001-Fig-grammar-of-count-lines-page.patch --]
[-- Type: text/x-patch, Size: 979 bytes --]

From bcea7e843936da41619df67faedf5f508db7d722 Mon Sep 17 00:00:00 2001
From: Paul Eggert <eggert@Penguin.CS.UCLA.EDU>
Date: Sun, 9 Jun 2019 16:59:43 -0700
Subject: [PATCH] Fig grammar of count-lines-page

* lisp/textmodes/page.el (count-lines-page):
Say "Page has 1 line", not "Page has 1 lines" (Bug#35981).
---
 lisp/textmodes/page.el | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/lisp/textmodes/page.el b/lisp/textmodes/page.el
index 2b0cea4c64..8921b697f3 100644
--- a/lisp/textmodes/page.el
+++ b/lisp/textmodes/page.el
@@ -141,7 +141,9 @@ count-lines-page
       (setq total (count-lines beg end)
 	    before (count-lines beg opoint)
 	    after (count-lines opoint end))
-      (message "Page has %d lines (%d + %d)" total before after))))
+      (message (ngettext "Page has %d line (%d + %d)"
+			 "Page has %d lines (%d + %d)" total)
+	       total before after))))
 
 (defun what-page ()
   "Print page and line number of point."
-- 
2.21.0


      parent reply	other threads:[~2019-06-10  0:03 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-29  9:34 bug#35981: [PATCH] Use ngettext in `count-lines-page' Stefan Kangas
2019-05-29 11:41 ` Basil L. Contovounesios
2019-05-29 11:46   ` Stefan Kangas
2019-06-10  0:03 ` Paul Eggert [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=12809efa-ea54-d399-84c2-4fce74ab42f2@cs.ucla.edu \
    --to=eggert@cs.ucla.edu \
    --cc=35981-done@debbugs.gnu.org \
    --cc=contovob@tcd.ie \
    --cc=stefan@marxist.se \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.