From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Chong Yidong Newsgroups: gmane.emacs.devel Subject: Re: tabulated-list-init-header and glyphless-char-display Date: Sun, 10 Apr 2011 14:11:31 -0400 Message-ID: <87mxjyht7w.fsf@stupidchicken.com> References: <83mxk0u0g7.fsf@gnu.org> <874o68zjhi.fsf@stupidchicken.com> <83k4f4twam.fsf@gnu.org> <8762qnxm44.fsf@stupidchicken.com> <83hba6rqtm.fsf@gnu.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1302459106 22378 80.91.229.12 (10 Apr 2011 18:11:46 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sun, 10 Apr 2011 18:11:46 +0000 (UTC) Cc: monnier@iro.umontreal.ca, emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Apr 10 20:11:41 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Q8z6r-0001Z6-2Z for ged-emacs-devel@m.gmane.org; Sun, 10 Apr 2011 20:11:41 +0200 Original-Received: from localhost ([127.0.0.1]:53989 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q8z6o-0003qC-EP for ged-emacs-devel@m.gmane.org; Sun, 10 Apr 2011 14:11:38 -0400 Original-Received: from [140.186.70.92] (port=40932 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q8z6k-0003pv-9R for emacs-devel@gnu.org; Sun, 10 Apr 2011 14:11:35 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Q8z6j-0000vv-45 for emacs-devel@gnu.org; Sun, 10 Apr 2011 14:11:34 -0400 Original-Received: from vm-emlprdomr-05.its.yale.edu ([130.132.50.146]:39950) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Q8z6j-0000vq-0x; Sun, 10 Apr 2011 14:11:33 -0400 Original-Received: from furball (c-71-192-165-84.hsd1.ct.comcast.net [71.192.165.84]) (authenticated bits=0) by vm-emlprdomr-05.its.yale.edu (8.14.4/8.14.4) with ESMTP id p3AIBVTX015302 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Sun, 10 Apr 2011 14:11:32 -0400 Original-Received: by furball (Postfix, from userid 1000) id BD16C160461; Sun, 10 Apr 2011 14:11:31 -0400 (EDT) In-Reply-To: <83hba6rqtm.fsf@gnu.org> (Eli Zaretskii's message of "Sun, 10 Apr 2011 19:53:09 +0300") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) X-Scanned-By: MIMEDefang 2.71 on 130.132.50.146 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 130.132.50.146 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:138357 Archived-At: Eli Zaretskii writes: >> For instance, if you do (aset glyphless-char-display ?a 'empty-box), >> that tells Emacs that "a" is a glyphless character, and causes all >> "a"'s to be displayed as empty boxes. > > That's right, but why would you do something like that with a > characters that is perfectly displayable? You should only do that > with characters that cannot be displayed, like unencodable characters > on a tty. That's what I was trying to convey; sorry if I failed to > get that across. I think what you have in mind (correct me if I'm wrong) is to do some kind of terminal detection, and then conditionally set up the glyphless-char-display char table in the tabulated-list buffer. That solution is not satisfactory, because it won't work in the multi-tty case. The same buffer might be simultaneously displayed on a text terminal and on X, and we want the X display to work properly. The correct fix is to provide some way to say "in the no-font case, display this character in this way". There's currently no multi-tty compatible way to do this for one specific character. An alternative to my earlier text-property-based proposal is to extend glyphless-char-display's extra slot, so that in addition to the symbols `hex-code' and `empty-box', it can hold yet another char table for resolving the display of individual fontless characters. However, this has the undesireable (though minor) side-effect of changing display in the main part of the buffer, so I still prefer the text-property-based solution.