[slime-cvs] CVS slime

CVS User heller heller at common-lisp.net
Tue Dec 9 07:47:59 UTC 2008


Update of /project/slime/cvsroot/slime
In directory cl-net:/tmp/cvs-serv6278

Modified Files:
	ChangeLog slime.el 
Log Message:
Make the modeline a bit shorter.

* slime.el (slime-compute-modeline-string): Remove PKG: and CON:
to save space.
(slime-compute-modeline-connection-state): Don't include zeros.

--- /project/slime/cvsroot/slime/ChangeLog	2008/12/09 07:47:47	1.1594
+++ /project/slime/cvsroot/slime/ChangeLog	2008/12/09 07:47:59	1.1595
@@ -1,4 +1,12 @@
-2008-12-09   David Reitter <david.reitter at gmail.com>
+2008-12-09  Helmut Eller  <heller at common-lisp.net>
+
+	Make the modeline a bit shorter.
+
+	* slime.el (slime-compute-modeline-string): Remove PKG: and CON:
+	to save space.
+	(slime-compute-modeline-connection-state): Don't include zeros.
+
+2008-12-09  David Reitter <david.reitter at gmail.com>
 
 	* slime.el (slime-repl-mode): Use `run-mode-hooks' rather than
 	just `run-hooks'.  That way, after-change-major-mode-hook is
--- /project/slime/cvsroot/slime/slime.el	2008/12/09 07:47:48	1.1072
+++ /project/slime/cvsroot/slime/slime.el	2008/12/09 07:47:59	1.1073
@@ -488,18 +488,18 @@
               ;; attached to it, e.g. the one resulting from
               ;; `slime-interrupt'.
               (sldbs   (length (sldb-buffers conn))))
-          (if (= sldbs 0)
-              (format "%s" rex-cs)
-              (format "%s/%s"
-                      (if (= rex-cs 0) 0 (- rex-cs sldb-cs)) 
-                      sldbs)))
+          (cond ((and (= sldbs 0) (zerop rex-cs)) nil)
+                ((= sldbs 0) (format "%s" rex-cs))
+                (t (format "%s/%s"
+                           (if (= rex-cs 0) 0 (- rex-cs sldb-cs)) 
+                           sldbs))))
       (slime-connection-state-as-string new-state))))
 
 (defun slime-compute-modeline-string (conn state pkg)
   (concat (when (or conn pkg)             "[")
-          (when pkg                       (format "PKG:%s" pkg))
+          (when pkg                       (format "%s" pkg))
           (when (and (or conn state) pkg) ", ")
-          (when conn                      (format "CON:%s" conn))
+          (when conn                      (format "%s" conn))
           (when state                     (format "{%s}" state))
           (when (or conn pkg)             "]")))
 





More information about the slime-cvs mailing list