emacs-devel
[Top][All Lists]
Advanced

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

Patch to lisp/bs.el


From: CHENG Gao
Subject: Patch to lisp/bs.el
Date: Sat, 20 Nov 2004 00:13:39 +0800
User-agent: Gnus/5.110003 (No Gnus v0.3) Emacs/21.3.50 (windows-nt)

Reading Coding Conventions, I found it's not desirable to use
next-line/previous-line. Searching Emacs files generate some files that
dont follow this.

Below is patch to lisp/bs.el with next-line/previous replaced with
forward-line.

--- bs.el.orig  2004-11-19 23:55:04.000000000 +0800
+++ bs.el       2004-11-19 23:56:08.000000000 +0800
@@ -1006,7 +1006,7 @@
   "Move cursor vertically up one line.
 If on top of buffer list go to last line."
   (interactive "p")
-  (previous-line 1)
+  (forward-line -1)
   (if (<= (count-lines 1 (point)) (1- bs-header-lines-length))
       (progn
        (goto-char (point-max))
@@ -1027,7 +1027,7 @@
   (let ((last (line-end-position)))
     (if (eq last (point-max))
        (goto-line (1+ bs-header-lines-length))
-      (next-line 1))))
+      (forward-line 1))))
 
 (defun bs-visits-non-file (buffer)
   "Return t or nil whether BUFFER visits no file.

-- 
德不孤,必有邻
         -- 《论语-里仁》






reply via email to

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