emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: easy mode-line manipulation


From: Juanma Barranquero
Subject: Re: easy mode-line manipulation
Date: Wed, 24 Oct 2001 10:37:59 +0200

On 24 Oct 2001 10:43:23 +0900, address@hidden wrote:

> how about this:
> 
>   (require 'cl)
>   (setq default-mode-line-format
>         (delete* 'line-number-mode default-mode-line-format
>                  :test (lambda (x y) (and (listp y) (eq x (car y))))))
>   (setq default-mode-line-format
>         (delete* 'column-number-mode default-mode-line-format
>                  :test (lambda (x y) (and (listp y) (eq x (car y))))))
> 
>   ;; add your customization here

Doable, obviously. I think I already said:

> Currently you can do that by "direct" manipulation of the default
> format, but that is cumbersome and error-prone.

I think you're tiptoeing over some of the things I mentioned. For
example, if your "customizations here" tries to have the same help
attribute as the default for the modeline, you'll have to manipulate
it somehow to get the attribute of some fragment of the modeline, or
duplicate the attribute. Etc.

Let's put it another way: customization of the mode-line is easy for a
elisp programmer or power user. Definitely *not* that easy for a
unskilled user. "M-x customize-group modeline" is just another way to
do raw manipulation of the mode-line-format spec.

Is there any interest in making easier for (non-power) users and
(not-so-expert) elisp programmers customizing their mode-lines?

                                                           /L/e/k/t/u




reply via email to

[Prev in Thread] Current Thread [Next in Thread]