[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Emacs i18n
From: |
Paul Eggert |
Subject: |
Re: Emacs i18n |
Date: |
Mon, 11 Mar 2019 15:51:20 -0700 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.5.1 |
On 3/11/19 2:48 PM, Juri Linkov wrote:
> Please note that you have to handle not only format-strings of
> ‘message’, but also ‘error’ and even more low-level ‘format’, i.e. all
> these (error STRING &rest ARGS) (message FORMAT-STRING &rest ARGS)
> (format-message STRING &rest OBJECTS) (format STRING &rest OBJECTS)
>
I expect that 'format' won't translate its first argument, whereas
'error', 'message', and 'format-message' will. This will be for the same
reason that 'format' does not translate quotes.
> there are many places that construct the string arguments of ‘message’
> using ‘format’ like in ‘perform-replace’:
>
Yes, quite right. These places will need to be redone so that the
translation will work properly. Here's a first cut at how to redo the
perform-replace code that you mentioned (this could get fancier if needed):
(nmessage replace-count
"Replaced %d occurrence%s"
"Replaced %d occurrences%s"
replace-count
(if (> (+ skip-read-only-count
skip-filtered-count
skip-invisible-count)
0)
(format-message
" (skipped %s)"
(mapconcat
#'identity
(delq nil (list
(if (> skip-read-only-count 0)
(format-message "%s read-only"
skip-read-only-count))
(if (> skip-invisible-count 0)
(format-message "%s invisible"
skip-invisible-count))
(if (> skip-filtered-count 0)
(format-message "%s filtered out"
skip-filtered-count))))
(gettext ", ")))
""))
- Re: Emacs i18n, (continued)
- Re: Emacs i18n, Eli Zaretskii, 2019/03/06
- Re: Emacs i18n, Paul Eggert, 2019/03/06
- Re: Emacs i18n, Eli Zaretskii, 2019/03/06
- Re: Emacs i18n, Paul Eggert, 2019/03/06
- Re: Emacs i18n, Eli Zaretskii, 2019/03/06
- Re: Emacs i18n, Paul Eggert, 2019/03/07
- Re: Emacs i18n, Jean-Christophe Helary, 2019/03/06
- Re: Emacs i18n, Paul Eggert, 2019/03/07
- Re: Emacs i18n, Richard Stallman, 2019/03/07
- Re: Emacs i18n, Juri Linkov, 2019/03/11
- Re: Emacs i18n,
Paul Eggert <=
- Re: Emacs i18n, Juri Linkov, 2019/03/12
- Re: Emacs i18n, Juri Linkov, 2019/03/17
- Re: Emacs i18n, Juri Linkov, 2019/03/18
- Re: Emacs i18n, Paul Eggert, 2019/03/18
- Re: Emacs i18n, Juri Linkov, 2019/03/19
- Re: Emacs i18n, Jean-Christophe Helary, 2019/03/11
- Re: Emacs i18n, Michael Albinus, 2019/03/12
- Re: Emacs i18n, Paul Eggert, 2019/03/06
- Re: Emacs i18n, Eli Zaretskii, 2019/03/06
- Re: Emacs i18n, Paul Eggert, 2019/03/06