GNU bug report logs - #41250
28.0.50; Dired displays unconditionally ls-switches on modeline

Previous Next

Package: emacs;

Reported by: Arthur Miller <arthur.miller <at> live.com>

Date: Thu, 14 May 2020 01:43:01 UTC

Severity: minor

Tags: fixed

Found in version 28.0.50

Fixed in version 28.1

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Arthur Miller <arthur.miller <at> live.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 41250 <at> debbugs.gnu.org, Drew Adams <drew.adams <at> oracle.com>, juri <at> linkov.net
Subject: bug#41250: 28.0.50; Dired displays unconditionally ls-switches on modeline
Date: Fri, 15 May 2020 23:08:46 +0200
Eli Zaretskii <eliz <at> gnu.org> writes:

>> Date: Fri, 15 May 2020 11:55:46 -0700 (PDT)
>> From: Drew Adams <drew.adams <at> oracle.com>
>> Cc: 41250 <at> debbugs.gnu.org, Juri Linkov <juri <at> linkov.net>
>> 
>> an integer - show first N chars of switches
>
> I don't think this is a useful value: the user will rarely know how
> much space is available on the mode line.  Also, truncating without
> showing ellipsis or some other sign of truncation is IMO a sub-optimal
> UI.
>
> Thanks.

After I saw Drews mail and patch, and answered, I was thinking
additionally, and I am actually now wondering, why is it assumed that
Dired will show sorting order on modeline by default? I mean other modes
does not do similar. Say, cc-mode does not show which current identation
scheme I use, or something similar. Why is it assumed for Dired? I don't
have historical insight so I don't know why original author(s) decided
to make it so?

If Dired show just, word "Dired" as it's lighter only, as other modes do,
then maybe Drews idea to have a format string is maybe the most flexible
one? For example we could have a format string, by default nil or just
"", which user could set to whatever. Or there could be a hook, say

(defun dired-display-mode-line-info (info-message)
    (setq mode-name (concat mode-name " " info-message)
    (force-mode-line-update)))

with some checks for empty stirng and so on. I ment just as a quick
illustration.

Then users could put for themselves the info they wishes to be
displayed on modeline: sorting order, or number of fles, or current moon
phase? Or they will be like and would prefer to show nothing.

Maybe you have already discussed this when dired was written? In that
case I am just curious why it was decided that Dired should show extra
info on modeline? If anybody remembers, or even know, of course.




This bug report was last modified 4 years and 288 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.