Emacs - How to Consolidate: Easier (s) for Minor Modes

Is it possible to consolidate :lighterson-line regimes when there is a certain combination of active secondary modes? If so, how please?

Example:

  • Minor mode number one has: a lighter " -"

  • Minor mode number two has: a lighter " +"

If both auxiliary modes are active in the buffer, then consolidate the lighters: " ±"

+4
source share
1 answer

You can dynamically change the ignition value for any minor mode by changing minor-mode-alist:

(setcar (cdr (assq 'MODE minor-mode-alist)) VALUE)

, . , , - "".

, , , . delight.el , mylibrary.el, :

(delight '((mode+ (mode- " ±" " +") "mylibrary")
           (mode- (mode+ "" " -") "mylibrary")))

- , , ; , . - .

+6

Source: https://habr.com/ru/post/1542570/


All Articles