emacs-devel
[Top][All Lists]
Advanced

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

Re: Suggestions for mode-line-format changes


From: Kim F. Storm
Subject: Re: Suggestions for mode-line-format changes
Date: 21 Aug 2002 02:25:57 +0200
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50

I wrote:

> Now that the mode-line-position information has been moved
> from the end of the mode line, and vc-mode is moved there too,
> the space between the buffer name and the mode-line-modes
> has become pretty crowded.
> 

Actually, I think the new position of "mode-line-position" in the mode line
is a drawback compared to the former position at the end of the mode line!

Try turning on column-number-mode, goto to the first line of a
non-empty buffer and hold down the right arrow key to advance through
the characters and lines of the buffer.

Notice how the mode line information to the right of the
mode-line-position starts jumping forth and back when the column goes
from 9 to 10 and from the end of line column back to 0.

Likewise, if you just start writing in the buffer, the same jumpyness
is seen in the mode line as you enter the 10th character of a line
and you press RET.

IMO, this is really, really annoying.  I never saw any such jumpyness
with the old position.


I liked the old position better, but if we want to keep it in the new
position, I think padding of the whole mode-line-position
[specified inside mode-line-position itself, of course] should be
added.

Using my suggested format, I tried to add padding like this:

        (setq-default mode-line-position 
                      '((15 (-3 . "%p") " (%l,%c)")))

but this doesn't work as the entire padding is done to the end of the
%p part.

I then tried

        (setq-default mode-line-position 
                      '((15 "" (-3 . "%p") " (%l,%c)")))

but then the "" is padded to 15 spaces which doesn't help either.


The following works by padding at the end of the combined string, but
then the "Bottom" string isn't truncated to "Bot":

(setq-default mode-line-position 
              '((15 "%p (%l,%c)")))


It seems that it doesn't work to combine padding and trunction like
        (15 (-3 ...) ...)

That's a bug IMO.


-- 
Kim F. Storm <address@hidden> http://www.cua.dk





reply via email to

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