GNU bug report logs - #53776
Modeline indicator when using define-minor-mode

Previous Next

Package: emacs;

Reported by: goncholden <goncholden <at> protonmail.com>

Date: Fri, 4 Feb 2022 11:56:01 UTC

Severity: wishlist

Tags: notabug

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: Phil Sainty <psainty <at> orcon.net.nz>
To: goncholden <goncholden <at> protonmail.com>
Cc: 53776 <at> debbugs.gnu.org, Stephen Berman <stephen.berman <at> gmx.net>
Subject: bug#53776: Modeline indicator when using define-minor-mode
Date: Sat, 05 Feb 2022 13:12:58 +1300
On 2022-02-05 02:22, goncholden wrote:
> Because one can easily add minor-modes that exceed the mode-line
> mini-buffer, is there
> the capability of making a hierarchical modeline indicator.
> 
> e.g.
> 
> Emacs-Lisp
> company
> Outl
> Gon -> rich
>     -> gudin
>     -> cholden

I've not seen anything which looks like your example, however there
are several libraries available which are designed to reclaim space
in the mode-line by manipulating the appearance of the minor mode
lighter text and/or major mode names.

https://github.com/tarsius/minions turns the minor mode list into
a menu, if you do want a (usually hidden) vertical listing.

If you just want to rename (or hide) certain names, take a look at
https://www.emacswiki.org/emacs/DelightedModes (or alternatively
blackout.el, dim.el, or diminish.el, which are all similar).

https://github.com/Malabarba/rich-minority is an approach which
lets you target rendered lighters with regexps, and modify them
using text properties.

I haven't seen anything "hierarchical" (but then minor modes have
no inherent hierarchy), however you could fake it to some extent by
using conditional elements in your mode-line constructs to combine
multiple lighters into a single multi-mode lighter.  For example:
https://stackoverflow.com/questions/23944477/emacs-how-to-consolidate-lighters-for-minor-modes


-Phil





This bug report was last modified 3 years and 104 days ago.

Previous Next


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