[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Before l10n, better practices for (message) ?
From: |
Jean-Christophe Helary |
Subject: |
Re: Before l10n, better practices for (message) ? |
Date: |
Tue, 23 May 2017 10:18:46 +0900 |
> On May 23, 2017, at 9:59, Tino Calancha <address@hidden> wrote:
> On Tue, 23 May 2017, Jean-Christophe Helary wrote:
>
>> I just bumped into an English/code bug this morning. In package.el, when 1
>> package is not needed anymore, the message is:
>>
>> "Package menu: Operation finished. 1 packages are no longer needed, type
>> ‘M-x package-autoremove’ to remove them"
...
>> So I'm asking whether do we have "best practices" for using messages...
> This was discussed in
> https://lists.gnu.org/archive/html/emacs-devel/2016-09/msg00502.html
>
> I proposed to add a simple function `string-plural-s' to standarize those
> plurarizations.
Yes, but no.
As a person who pays his bills doing translation and l10n, I would *never*
recommend to create UI strings programatically based on *grammatical*
assumptions. In fact I would forbid that if I could :) And I think that should
be an Emacs policy for all UI strings...
I'm currently going through package.el and the easiest solution I have for now
is replace things like "%d package%s to install" (where %s is "s" depending on
whether %d is greater than 1...) into "Number of packages to install: %d.".
The packages.el authors have created incredible messages where "ing" is
replaced by "ed" depending on whether the process is running or completed, just
so as to save a few lines of static strings. Of course, the code is very
clever, but if we want to create a base for l10n one day, all these clever
grammatical hacks must permanently go away...
So, as I just wrote, I'm working on package.el right now and I'll submit a
patch, and when I'm done, I'd like to see what kind of mechanisms we have (or
we need to create) to extract strings and use localized ressources.
Jean-Christophe
- Before l10n, better practices for (message) ?, Jean-Christophe Helary, 2017/05/22
- Re: Before l10n, better practices for (message) ?, Tino Calancha, 2017/05/22
- Re: Before l10n, better practices for (message) ?,
Jean-Christophe Helary <=
- Re: Before l10n, better practices for (message) ?, Eli Zaretskii, 2017/05/22
- Re: Before l10n, better practices for (message) ?, Jean-Christophe Helary, 2017/05/22
- Re: Before l10n, better practices for (message) ?, Eli Zaretskii, 2017/05/23
- Re: Before l10n, better practices for (message) ?, Jean-Christophe Helary, 2017/05/23
- Re: Before l10n, better practices for (message) ?, Eli Zaretskii, 2017/05/23
- Re: Before l10n, better practices for (message) ?, Jean-Christophe Helary, 2017/05/23
- Re: Before l10n, better practices for (message) ?, Paul Eggert, 2017/05/24
- Re: Before l10n, better practices for (message) ?, Jean-Christophe Helary, 2017/05/24
- Re: Before l10n, better practices for (message) ?, Eli Zaretskii, 2017/05/24
- Re: Before l10n, better practices for (message) ?, Jean-Christophe Helary, 2017/05/24