From: Lars Ingebrigtsen <larsi@gnus.org>
To: "Basil L. Contovounesios" <contovob@tcd.ie>
Cc: 34476@debbugs.gnu.org, "積丹尼 Dan Jacobson" <jidanni@jidanni.org>
Subject: bug#34476: fluffy whitespace in the mode-line, despite it running off the screen
Date: Fri, 07 Aug 2020 10:00:35 +0200 [thread overview]
Message-ID: <87eeoi7un0.fsf@gnus.org> (raw)
In-Reply-To: <m3r26y51e7.fsf@gnus.org> (Lars Ingebrigtsen's message of "Tue, 09 Jul 2019 23:44:16 +0200")
Lars Ingebrigtsen <larsi@gnus.org> writes:
> "Basil L. Contovounesios" <contovob@tcd.ie> writes:
>
>> Instead of, or in addition to, a user option, perhaps a new mode line
>> construct would be more general. There is already a way to specify a
>> minimum field width, for example, so perhaps it would be possible to
>> also specify a maximum default width.
>
> Do you mean on a per-field basis? Hm... I'm not sure that's generally
> useful -- when chopping down a field, there's often field-specific ways
> to shorten things (i.e., just chopping the ends off of things isn't
> always the best thing to do).
>
> But in any case, it's orthogonal to whether to compact the white space,
> which entails no information loss and can be done generally. I think.
I had a look at this, thinking that this would be easy to implement. We
could have, for instance, a variable like `mode-line-compact' that would
default to nil (current behaviour), t (always compact) and `long'
(compact if the mode line is wider than the window size).
However, the mode line generation is done in a very low-level manner --
in display_mode_element. And it calls display_string directly for each
element? If I'm reading the code correctly?
static int
display_mode_line (struct window *w, enum face_id face_id, Lisp_Object format)
[...]
mode_line_target = MODE_LINE_DISPLAY;
Yeah, I think so.
So it doesn't create a string, and then display it, so there's really no
way to post-process the entire string before it's displayed, I think?
Which makes this rather difficult to implement.
Hm... well, since this is an optional thing users can switch on,
perhaps making it slightly slower wouldn't be that much of a problem.
Let's see...
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
next prev parent reply other threads:[~2020-08-07 8:00 UTC|newest]
Thread overview: 39+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-02-14 13:34 bug#34476: fluffy whitespace in the mode-line, despite it running off the screen 積丹尼 Dan Jacobson
2019-07-09 16:43 ` Lars Ingebrigtsen
2019-07-09 20:46 ` Basil L. Contovounesios
2019-07-09 21:44 ` Lars Ingebrigtsen
2020-08-07 8:00 ` Lars Ingebrigtsen [this message]
2020-08-07 8:31 ` Lars Ingebrigtsen
2020-08-07 11:32 ` Eli Zaretskii
2020-08-07 11:41 ` Lars Ingebrigtsen
2020-08-07 11:59 ` Eli Zaretskii
2020-08-07 12:15 ` Lars Ingebrigtsen
2020-08-07 13:52 ` Eli Zaretskii
2020-08-08 9:11 ` Lars Ingebrigtsen
2020-08-08 9:48 ` Eli Zaretskii
2020-08-08 10:01 ` Eli Zaretskii
2020-08-08 11:18 ` Lars Ingebrigtsen
2020-08-08 12:55 ` Eli Zaretskii
2020-08-08 14:16 ` Lars Ingebrigtsen
2020-08-08 15:00 ` Eli Zaretskii
2020-08-09 9:56 ` Lars Ingebrigtsen
2020-08-09 14:07 ` Eli Zaretskii
2020-08-10 14:46 ` Eli Zaretskii
2020-08-10 14:56 ` Lars Ingebrigtsen
2020-08-14 10:46 ` Eli Zaretskii
2020-08-14 12:00 ` Lars Ingebrigtsen
2020-08-14 13:16 ` Eli Zaretskii
2020-08-15 8:47 ` Eli Zaretskii
2020-08-15 10:55 ` Lars Ingebrigtsen
2020-08-15 15:12 ` Eli Zaretskii
2020-08-16 11:21 ` Lars Ingebrigtsen
2020-08-16 14:43 ` Eli Zaretskii
2020-08-17 8:33 ` Lars Ingebrigtsen
2020-08-17 14:17 ` Eli Zaretskii
2020-12-29 3:54 ` Lars Ingebrigtsen
2020-12-29 15:02 ` Eli Zaretskii
2020-12-29 15:07 ` Lars Ingebrigtsen
2020-12-29 15:54 ` Eli Zaretskii
2020-12-29 17:04 ` martin rudalics
2020-12-30 2:36 ` Lars Ingebrigtsen
2020-08-08 11:18 ` Lars Ingebrigtsen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87eeoi7un0.fsf@gnus.org \
--to=larsi@gnus.org \
--cc=34476@debbugs.gnu.org \
--cc=contovob@tcd.ie \
--cc=jidanni@jidanni.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.