From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Ulrich =?utf-8?Q?M=C3=BCller?= Newsgroups: gmane.emacs.devel Subject: Re: Disambiguate modeline character for UTF-8? Date: Thu, 06 Jul 2023 20:44:05 +0200 Message-ID: References: <83wo1p73d2.fsf@gnu.org> <6ccde339-2bf1-3a4d-61bb-734046bf02d5@cs.ucla.edu> <83r1rx6vgv.fsf@gnu.org> <83lfi56te9.fsf@gnu.org> <83cz16k2kx.fsf@gnu.org> <833522jwvr.fsf@gnu.org> <87wmzdjk6l.fsf@yahoo.com> <219844d2-ca07-30f4-4e2c-1b1df76d0fa5@cs.ucla.edu> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="19507"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.3 (gnu/linux) Cc: emacs-devel@gnu.org To: Paul Eggert Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu Jul 06 20:45:12 2023 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1qHTya-0004wd-0p for ged-emacs-devel@m.gmane-mx.org; Thu, 06 Jul 2023 20:45:12 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qHTxk-00025v-OP; Thu, 06 Jul 2023 14:44:20 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qHTxi-00025c-0x for emacs-devel@gnu.org; Thu, 06 Jul 2023 14:44:18 -0400 Original-Received: from woodpecker.gentoo.org ([2001:470:ea4a:1:5054:ff:fec7:86e4] helo=smtp.gentoo.org) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_CHACHA20_POLY1305:256) (Exim 4.90_1) (envelope-from ) id 1qHTxc-0008Or-Ef for emacs-devel@gnu.org; Thu, 06 Jul 2023 14:44:17 -0400 In-Reply-To: <219844d2-ca07-30f4-4e2c-1b1df76d0fa5@cs.ucla.edu> (Paul Eggert's message of "Thu, 6 Jul 2023 10:37:53 -0700") Received-SPF: pass client-ip=2001:470:ea4a:1:5054:ff:fec7:86e4; envelope-from=ulm@gentoo.org; helo=smtp.gentoo.org X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 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-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:307530 Archived-At: >>>>> On Thu, 06 Jul 2023, Paul Eggert wrote: > On 2023-07-06 06:08, Ulrich Mueller wrote: >> for both UTF-7 and koi8-u the coded character set is not >> Unicode but only a subset of it > It would be helpful to use 'u' when only a subset of Unicode can be > represented, as a clue that something odd is going on, compared to the > more-usual 'U'. How about the following patch then? >From b33df88e456092e89bad52565b68a77ea3d0c71a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ulrich=20M=C3=BCller?= Date: Thu, 6 Jul 2023 20:36:09 +0200 Subject: [PATCH] Disambiguate mode line indication for utf-8 and utf-16 * lisp/international/mule-conf.el (utf-7): * lisp/language/cyrillic.el (koi8-u): Change mnemonic letters to ?u and ?K, respectively. --- lisp/international/mule-conf.el | 2 +- lisp/language/cyrillic.el | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/lisp/international/mule-conf.el b/lisp/international/mule-conf.el index a27aaf9e522..f65f124b633 100644 --- a/lisp/international/mule-conf.el +++ b/lisp/international/mule-conf.el @@ -1600,7 +1600,7 @@ 'ascii (define-coding-system 'utf-7 "UTF-7 encoding of Unicode (RFC 2152)." :coding-type 'utf-8 - :mnemonic ?U + :mnemonic ?u :mime-charset 'utf-7 :charset-list '(unicode) :pre-write-conversion 'utf-7-pre-write-conversion diff --git a/lisp/language/cyrillic.el b/lisp/language/cyrillic.el index 7af87e65703..1ad1302095b 100644 --- a/lisp/language/cyrillic.el +++ b/lisp/language/cyrillic.el @@ -126,7 +126,10 @@ 'cp878 (define-coding-system 'koi8-u "KOI8-U 8-bit encoding for Cyrillic (MIME: KOI8-U)" :coding-type 'charset - :mnemonic ?U + ;; This used to be ?U which collided with UTF-8. ?K is also used + ;; for Korean, but it shouldn't be a real conflict since Cyrillic + ;; and Hangul can be disambiguated from context. + :mnemonic ?K :charset-list '(koi8-u) :mime-charset 'koi8-u) -- 2.41.0