From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Richard Stallman Newsgroups: gmane.emacs.devel Subject: Re: Display of undisplayable characters: \U01F3A8 instead of diamond Date: Tue, 30 Aug 2022 00:12:02 -0400 Message-ID: References: <87edx28cl1.fsf@disroot.org> <83y1v7w6eu.fsf@gnu.org> Reply-To: rms@gnu.org Content-Type: text/plain; charset=Utf-8 Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="17164"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Aug 30 06:12:48 2022 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 1oSscI-0004GQ-VX for ged-emacs-devel@m.gmane-mx.org; Tue, 30 Aug 2022 06:12:47 +0200 Original-Received: from localhost ([::1]:51164 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oSscH-0008Px-Dc for ged-emacs-devel@m.gmane-mx.org; Tue, 30 Aug 2022 00:12:45 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:50726) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oSsbb-0007l1-SF for emacs-devel@gnu.org; Tue, 30 Aug 2022 00:12:03 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:46746) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oSsbb-0000F9-Js for emacs-devel@gnu.org; Tue, 30 Aug 2022 00:12:03 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=Date:References:Subject:In-Reply-To:To:From: mime-version; bh=pJEn9uEXUkIuKSOW1WYNiGvhYrEvKzYbQrxWQug+Gss=; b=jeSex769u3KO CQ+qocx99oIMR/+FOvvf4HhM4HiBJw2T2Te/mwGOIp8r+1xOZi9g8bgGbeKvX3ESLaxM4WSixq1Eg ThJMbxmsXYMFt06YzQGynyf+63WXSXY4ZMQd+ECj0Vyk9eLvEJ7VSKDx4RlKBT3qLuXA81RIkee/n wWNeiwgLtE6vpK8lBvkxKjC4gLPIwEPagKYEEOUZO4c2IxBdBNY6vslVwNfEFgnsFvP/nn5nsKVbD wG3LNUwXs87GjDHqlodivaF66+fCLofFkA9clqa6nzAWGAVXZXMQNBh16zbF0/pSQPKfU7qq2iewq Ki+URPq0A8zh/LD4jJtBag==; Original-Received: from rms by fencepost.gnu.org with local (Exim 4.90_1) (envelope-from ) id 1oSsba-00065k-NL; Tue, 30 Aug 2022 00:12:03 -0400 In-Reply-To: <83y1v7w6eu.fsf@gnu.org> (message from Eli Zaretskii on Mon, 29 Aug 2022 16:00:57 +0300) 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" Xref: news.gmane.io gmane.emacs.devel:294322 Archived-At: [[[ To any NSA and FBI agents reading my email: please consider ]]] [[[ whether defending the US Constitution against all enemies, ]]] [[[ foreign or domestic, requires you to follow Snowden's example. ]]] > No, because displaying a non-ASCII character on a text-mode terminal > requires to encode it. Maybe the existing mechamisms will insist on encoring it, but I think it won't be hard to bypass that step. The user could specify the encoded sequence to send, by putting that sequence in a variable as a string or vector. Then redisplay simply has to send the sequence of characters from the vector, _as if_ they were the result of encoding something. > > but what is so bad about sending a glyph that the terminal can't > > display? What bad results does it cause? > It could mess up the display, because sending commands to the terminal > driver also involves sequences of unprintable bytes. In some cases, maybe there is a risk it could do that. But if the user uses the feature I propose just above, perse will be responsible for specifying a sequence that displays as a character. So that won't mess up the display. > This arranges for all the characters beyond 255 to be displayed as the > diamond with a special face. (You can, of course, adjust the range of > characters for which this is done according to your needs, or have > several disjoint ranges instead of just one.) > Would that be good enough for your use patterns? With 255 specified, it would not be adequate. The Linux console handles the Greek alphabet, the Russian alphabet, and I am not sure what else. Using several disjoint ranges could do the job, I suppose, if someone can tell me how to determine what those ranges should be. Could this be figured out automatically by calling char-displayable-p on each character code? Up to what number would that loop have to run? -- Dr Richard Stallman (https://stallman.org) Chief GNUisance of the GNU Project (https://gnu.org) Founder, Free Software Foundation (https://fsf.org) Internet Hall-of-Famer (https://internethalloffame.org)