emacs-devel
[Top][All Lists]
Advanced

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

Re: Dashes in mode-line


From: Julien Danjou
Subject: Re: Dashes in mode-line
Date: Tue, 19 Oct 2010 16:59:59 +0200
User-agent: Gnus/5.110011 (No Gnus v0.11) Emacs/24.0.50 (gnu/linux)

On Tue, Oct 19 2010, Eli Zaretskii wrote:

> Using window-system is not right here, because the DOS port defines a
> non-nil value, but uses a text terminal.

Fine, new version attached.

>From 52ffac3b023140720b76c0e4b20c681c0754e26c Mon Sep 17 00:00:00 2001
From: Julien Danjou <address@hidden>
Date: Mon, 18 Oct 2010 15:33:31 +0200
Subject: [PATCH] bindings: remove dashes in mode-line

Signed-off-by: Julien Danjou <address@hidden>
---
 etc/tutorials/TUTORIAL |   12 ++++++------
 lisp/ChangeLog         |    4 ++++
 lisp/bindings.el       |   11 ++++++-----
 3 files changed, 16 insertions(+), 11 deletions(-)

diff --git a/etc/tutorials/TUTORIAL b/etc/tutorials/TUTORIAL
index 1d80f4e..f566df9 100644
--- a/etc/tutorials/TUTORIAL
+++ b/etc/tutorials/TUTORIAL
@@ -498,12 +498,12 @@ you save, Emacs leaves the original file under a changed 
name in case
 you later decide that your changes were a mistake.
 
 If you look near the bottom of the screen you will see a line that
-begins and ends with dashes, and starts with "--:--- TUTORIAL" or
-something like that.  This part of the screen normally shows the name
-of the file that you are visiting.  Right now, you are visiting a file
-called "TUTORIAL" which is your personal scratch copy of the Emacs
-tutorial.  When you find a file with Emacs, that file's name will
-appear in that precise spot.
+begins with dashes, and starts with "--:--- TUTORIAL" or something
+like that.  This part of the screen normally shows the name of the
+file that you are visiting.  Right now, you are visiting a file called
+"TUTORIAL" which is your personal scratch copy of the Emacs tutorial.
+When you find a file with Emacs, that file's name will appear in that
+precise spot.
 
 One special thing about the command for finding a file is that you
 have to say what file name you want.  We say the command "reads an
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 0e20ffd..2316a22 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,7 @@
+2010-10-18  Julien Danjou  <address@hidden>
+
+       * bindings.el: Replaces dashes by spaces in default `mode-line-format'.
+
 2010-10-17  Agustín Martín  <address@hidden>
 
        * textmodes/ispell.el (ispell-aspell-find-dictionary): Fix
diff --git a/lisp/bindings.el b/lisp/bindings.el
index d19db2c..753e8a5 100644
--- a/lisp/bindings.el
+++ b/lisp/bindings.el
@@ -318,7 +318,7 @@ Keymap to display on column and line numbers.")
 mouse-2: Make current window occupy the whole frame\n\
 mouse-3: Remove current window from display")
        (recursive-edit-help-echo "Recursive edit, type C-M-c to get out")
-       (dashes (propertize "--" 'help-echo help-echo))
+       (spaces (propertize "  " 'help-echo help-echo))
        (standard-mode-line-format
        (list
         "%e"
@@ -334,9 +334,10 @@ mouse-3: Remove current window from display")
         '(vc-mode vc-mode)
         (propertize "  " 'help-echo help-echo)
         'mode-line-modes
-        `(which-func-mode ("" which-func-format ,dashes))
-        `(global-mode-string ("" global-mode-string ,dashes))
-        (propertize "-%-" 'help-echo help-echo)))
+        `(which-func-mode ("" which-func-format ,spaces))
+        `(global-mode-string ("" global-mode-string ,spaces))
+         `(:eval (when (or (not window-system) (eq window-system 'pc))
+                   ,(propertize "-%-" 'help-echo help-echo)))))
        (standard-mode-line-modes
        (list
         (propertize "%[" 'help-echo recursive-edit-help-echo)
@@ -362,7 +363,7 @@ mouse-3: Toggle minor modes"
                                 'mouse-2 #'mode-line-widen))
         (propertize ")" 'help-echo help-echo)
         (propertize "%]" 'help-echo recursive-edit-help-echo)
-        (propertize "--" 'help-echo help-echo)))
+         spaces))
 
        (standard-mode-line-position
        `((-3 ,(propertize
-- 
1.7.2.3


-- 
Julien Danjou
// ᐰ <address@hidden>   http://julien.danjou.info

reply via email to

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