aboutsummaryrefslogtreecommitdiffstats
path: root/lisp/emulation
diff options
context:
space:
mode:
authorGerd Moellmann <[email protected]>2000-12-05 13:58:49 +0000
committerGerd Moellmann <[email protected]>2000-12-05 13:58:49 +0000
commitd49af51c3213e22620724f05283059619f808556 (patch)
treecfb8f7c7763d7dafd1a88801f863b80842f778e3 /lisp/emulation
parent7422819c95c989c261c9e846e87262a9aaf30408 (diff)
(tpu-help): Fixed previous screen logic.
(tpu-search-highlight): Fixed comparison of overlay end positions. (tpu-trim-line-ends): Implemented trimming logic locally.
Diffstat (limited to 'lisp/emulation')
-rw-r--r--lisp/emulation/tpu-edt.el10
1 files changed, 8 insertions, 2 deletions
diff --git a/lisp/emulation/tpu-edt.el b/lisp/emulation/tpu-edt.el
index ac313289a5..21891d2486 100644
--- a/lisp/emulation/tpu-edt.el
+++ b/lisp/emulation/tpu-edt.el
@@ -994,6 +994,7 @@ This is useful for inserting control characters."
(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 @@ kills modified buffers without asking."
(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 @@ or each line of the entire buffer if no region is selected."
(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))))))
;;;