From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#41250: 28.0.50; Dired displays unconditionally ls-switches on modeline Date: Fri, 02 Oct 2020 09:31:45 +0300 Message-ID: <837ds9gmum.fsf@gnu.org> References: <87v9ky9p6o.fsf@mail.linkov.net> <654acc31-015d-4552-bd9b-3b8c69661fcd@default> <0957af50-7f85-455a-9d2c-e96451727872@default> <6073a2d5-4024-465d-8293-88ad7f6127ed@default> <87mu172qxb.fsf@gnus.org> <87sgazi550.fsf@mail.linkov.net> <87tuvfxdsf.fsf@gnus.org> <875z7vdol3.fsf@mail.linkov.net> <87pn63xcgp.fsf@gnus.org> <874knd7mow.fsf@mail.linkov.net> <877ds91zvy.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="18914"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 41250@debbugs.gnu.org, arthur.miller@live.com, juri@linkov.net To: Lars Ingebrigtsen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Oct 02 08:33:37 2020 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1kOEdN-0004ll-Kl for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 02 Oct 2020 08:33:37 +0200 Original-Received: from localhost ([::1]:53976 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kOEdM-0006DP-5y for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 02 Oct 2020 02:33:36 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:45182) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kOEco-0006DC-1D for bug-gnu-emacs@gnu.org; Fri, 02 Oct 2020 02:33:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:55864) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kOEcn-0004xQ-OG for bug-gnu-emacs@gnu.org; Fri, 02 Oct 2020 02:33:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kOEcn-00078F-Ka for bug-gnu-emacs@gnu.org; Fri, 02 Oct 2020 02:33:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 02 Oct 2020 06:33:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 41250 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: fixed Original-Received: via spool by 41250-submit@debbugs.gnu.org id=B41250.160162032227342 (code B ref 41250); Fri, 02 Oct 2020 06:33:01 +0000 Original-Received: (at 41250) by debbugs.gnu.org; 2 Oct 2020 06:32:02 +0000 Original-Received: from localhost ([127.0.0.1]:39177 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kOEbp-00076o-N3 for submit@debbugs.gnu.org; Fri, 02 Oct 2020 02:32:02 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:38142) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kOEbl-00076P-Ml for 41250@debbugs.gnu.org; Fri, 02 Oct 2020 02:32:00 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:41526) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kOEbe-0004t6-EI; Fri, 02 Oct 2020 02:31:50 -0400 Original-Received: from [176.228.60.248] (port=4927 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kOEbc-0004Bi-ES; Fri, 02 Oct 2020 02:31:50 -0400 In-Reply-To: <877ds91zvy.fsf@gnus.org> (message from Lars Ingebrigtsen on Thu, 01 Oct 2020 21:59:13 +0200) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:189622 Archived-At: > From: Lars Ingebrigtsen > Date: Thu, 01 Oct 2020 21:59:13 +0200 > Cc: 41250@debbugs.gnu.org, Arthur Miller > > Juri Linkov writes: > > > But anyway I think that it would be better to keep > > 'truncate-string-to-width', and to turn 'truncate-string-ellipsis' > > into a user option (defvar -> defcustom) with the default value > > computed as (if (char-displayable-p ?…) "…" "...") > > > > If this doesn't work on dynamically created mixed X/tty frames, then > > maybe allow some value (e.g. 'auto-detect') for > > 'truncate-string-ellipsis', so 'truncate-string-to-width' would call > > (if (char-displayable-p ?…) "…" "...") every time when > > 'truncate-string-to-width' is used and recompute the value of > > ellipsis. > > The variable doesn't work as is (because of the problem of mixed > frames), and `auto-detect' doesn't have much meaning, which is why this > should never have been a variable in the first place. > > Instead of trying to fix that mess, I thought it would be easier to > introduce a new function that does the right thing automatically, and > without a gazillion optional parameters, and then make the old function > obsolete. How about making char-displayable-p accept an optional argument, a frame for which to perform the test?