changeset 34206:18117bc6bcdd

(tpu-help): Fixed previous screen logic. (tpu-search-highlight): Fixed comparison of overlay end positions. (tpu-trim-line-ends): Implemented trimming logic locally.
author Gerd Moellmann <gerd@gnu.org>
date Tue, 05 Dec 2000 13:58:49 +0000
parents cc7549690c7a
children 93dbe8902ff0
files lisp/emulation/tpu-edt.el
diffstat 1 files changed, 8 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/emulation/tpu-edt.el	Tue Dec 05 13:58:36 2000 +0000
+++ b/lisp/emulation/tpu-edt.el	Tue Dec 05 13:58:49 2000 +0000
@@ -994,6 +994,7 @@
 	        	  (scroll-other-window -8)
 	        	(error nil)))
 	             (t
+	              (forward-line -1)
 	              (backward-page)
 	              (forward-line 1)
 	              (tpu-line-to-top-of-window))))
@@ -1116,7 +1117,8 @@
   (if (tpu-check-match)
       (move-overlay tpu-search-overlay
                     (tpu-match-beginning) (tpu-match-end) (current-buffer))
-    (unless (= (overlay-start tpu-search-overlay) (overlay-end tpu-search-overlay))
+    (unless (equal (overlay-start tpu-search-overlay)
+		   (overlay-end tpu-search-overlay))
       (move-overlay tpu-search-overlay 1 1 (current-buffer)))))
 
 (defun tpu-search nil
@@ -1665,7 +1667,11 @@
 (defun tpu-trim-line-ends nil
   "Removes trailing whitespace from every line in the buffer."
   (interactive)
-  (picture-clean))
+  (save-match-data
+    (save-excursion
+      (goto-char (point-min))
+      (while (re-search-forward "[ \t][ \t]*$" nil t)
+	(delete-region (match-beginning 0) (match-end 0))))))
 
 
 ;;;