From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.devel Subject: Re: Emacs i18n Date: Wed, 24 Apr 2019 23:18:34 +0300 Organization: LINKOV.NET Message-ID: <87d0lb2mip.fsf@mail.linkov.net> References: <87o97aq6gz.fsf@jidanni.org> <87tvgoud56.fsf@mail.linkov.net> <83o96wk2mi.fsf@gnu.org> <87k1hjfvjd.fsf@mail.linkov.net> <871s3p0zdz.fsf@mail.linkov.net> <83h8ckezyt.fsf@gnu.org> <87h8cjspc0.fsf@mail.linkov.net> <29a53a39-fa50-1e94-9420-a3ea1250aa44@gmail.com> <87r2azq478.fsf@mail.linkov.net> <83o963s4gx.fsf@gnu.org> <87va09ckym.fsf@mail.linkov.net> <83sgvdndt0.fsf@gnu.org> <8736ncgcnm.fsf@mail.linkov.net> <5F95E50C-2A55-4ED2-A82B-86FAAFC526ED@gmail.com> <87ef6uod20.fsf@mail.linkov.net> <878sx1cjl5.fsf@mail.linkov.net> <7E9097B4-C3F4-46AF-BA2A-2E886AB3C6AD@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="156559"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (x86_64-pc-linux-gnu) Cc: Paul Eggert , Emacs developers To: Jean-Christophe Helary Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Apr 24 22:28:58 2019 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hJOVl-000eaa-Mv for ged-emacs-devel@m.gmane.org; Wed, 24 Apr 2019 22:28:58 +0200 Original-Received: from localhost ([127.0.0.1]:46865 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hJOVk-0003dU-NF for ged-emacs-devel@m.gmane.org; Wed, 24 Apr 2019 16:28:56 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:38834) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hJOUv-0003A1-Sr for emacs-devel@gnu.org; Wed, 24 Apr 2019 16:28:09 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hJOPU-0005Fk-Qd for emacs-devel@gnu.org; Wed, 24 Apr 2019 16:22:29 -0400 Original-Received: from bird.maple.relay.mailchannels.net ([23.83.214.17]:50385) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hJOPU-00054u-9w for emacs-devel@gnu.org; Wed, 24 Apr 2019 16:22:28 -0400 X-Sender-Id: dreamhost|x-authsender|jurta@jurta.org Original-Received: from relay.mailchannels.net (localhost [127.0.0.1]) by relay.mailchannels.net (Postfix) with ESMTP id A88C53E3A9D; Wed, 24 Apr 2019 20:22:21 +0000 (UTC) Original-Received: from pdx1-sub0-mail-a34.g.dreamhost.com (unknown [100.96.28.64]) (Authenticated sender: dreamhost) by relay.mailchannels.net (Postfix) with ESMTPA id 0003A3E4290; Wed, 24 Apr 2019 20:22:20 +0000 (UTC) X-Sender-Id: dreamhost|x-authsender|jurta@jurta.org Original-Received: from pdx1-sub0-mail-a34.g.dreamhost.com (pop.dreamhost.com [64.90.62.162]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384) by 0.0.0.0:2500 (trex/5.17.2); Wed, 24 Apr 2019 20:22:21 +0000 X-MC-Relay: Neutral X-MailChannels-SenderId: dreamhost|x-authsender|jurta@jurta.org X-MailChannels-Auth-Id: dreamhost X-Chief-Army: 5065d84d6dd4ddf1_1556137341313_2286064489 X-MC-Loop-Signature: 1556137341313:999380536 X-MC-Ingress-Time: 1556137341313 Original-Received: from pdx1-sub0-mail-a34.g.dreamhost.com (localhost [127.0.0.1]) by pdx1-sub0-mail-a34.g.dreamhost.com (Postfix) with ESMTP id 9E81881AFF; Wed, 24 Apr 2019 13:22:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=linkov.net; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; s=linkov.net; bh=FcqrPNqcCCJiDNPdtzJLjU8GVMg=; b= p1Qs7e4NhHdLdhucIO9tiVNR1nZme5Q7HtqPbor/anhsNxgkpJMakegfATyxCeZK 67MRbrALJ3bL07MnvuKfxAf8xtUy/AWKweDLZXlZqG/mzrouL6tZ2efhQwNpFozu pW1GcXZdUbXsc4ESJX+merwI3pvVCHu7wwgZW38/Llo= Original-Received: from mail.jurta.org (m91-129-101-0.cust.tele2.ee [91.129.101.0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: jurta@jurta.org) by pdx1-sub0-mail-a34.g.dreamhost.com (Postfix) with ESMTPSA id F072A818DB; Wed, 24 Apr 2019 13:22:16 -0700 (PDT) X-DH-BACKEND: pdx1-sub0-mail-a34 In-Reply-To: <7E9097B4-C3F4-46AF-BA2A-2E886AB3C6AD@gmail.com> (Jean-Christophe Helary's message of "Wed, 24 Apr 2019 15:39:16 +0900") X-VR-OUT-STATUS: OK X-VR-OUT-SCORE: -100 X-VR-OUT-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgeduuddrhedvgdegfecutefuodetggdotefrodftvfcurfhrohhfihhlvgemucggtfgfnhhsuhgsshgtrhhisggvpdfftffgtefojffquffvnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenucfjughrpefhvffuohhfffgjkfgfgggtsehttdertddtredtnecuhfhrohhmpefluhhrihcunfhinhhkohhvuceojhhurhhisehlihhnkhhovhdrnhgvtheqnecukfhppeeluddruddvledruddtuddrtdenucfrrghrrghmpehmohguvgepshhmthhppdhhvghlohepmhgrihhlrdhjuhhrthgrrdhorhhgpdhinhgvthepledurdduvdelrddutddurddtpdhrvghtuhhrnhdqphgrthhhpefluhhrihcunfhinhhkohhvuceojhhurhhisehlihhnkhhovhdrnhgvtheqpdhmrghilhhfrhhomhepjhhurhhisehlihhnkhhovhdrnhgvthdpnhhrtghpthhtohepsghrrghnuggvlhhunhgvsehgmhgrihhlrdgtohhmnecuvehluhhsthgvrhfuihiivgeptd X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 23.83.214.17 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:235881 Archived-At: > So, where do we go from here now ? > > Juri, have you written documentation ? It's still WIP. First I looked how i18n is implemented in XEmacs, and discovered that whereas the interface is documented, it's not fully functional. What is worse, it's quite ugly. So I turned onto a nicer interface in CLISP that could be used as a basis of gettext interface in Emacs Lisp. > Do you want help ? Help is needed to install the standard gettext infrastructure using gettextize. Help is expected from someone who has more experience in applying gettext to other projects. Once the default gettext infrastructure is installed, I could help in adapting gettext to Emacs. Meanwhile, currently I'm replacing dired-plural-s with ngettext in bug#35287. It's not without problems: one problematic place is in dired-do-kill-lines: (defun dired-do-kill-lines (&optional arg fmt) ... (let ((count 0)) (setq count (1+ count)) (or (equal "" fmt) (message (or fmt "Killed %d line%s.") count (dired-plural-s count))) count) (defun dired-omit-expunge (&optional regexp) ... (setq count (dired-do-kill-lines nil (if dired-omit-verbose "Omitted %d line%s." ""))) The format string can't be just replaced in dired-do-kill-lines with something like (ngettext "Killed %d line." "Killed %d lines." count) because it can be called with a format string from dired-omit-expunge, but also dired-omit-expunge has no access to the variable 'count'. There are more such marginal cases, but eventually they all have to resolved somehow.