summaryrefslogtreecommitdiff
path: root/lisp/indent.el
diff options
context:
space:
mode:
authorRichard M. Stallman <rms@gnu.org>1994-06-20 01:52:51 +0000
committerRichard M. Stallman <rms@gnu.org>1994-06-20 01:52:51 +0000
commit2f815c8d1a21cf5cfdcb7d4c971243914e093f6f (patch)
tree818b080e5013c6baceea67992065c5ce42c67e30 /lisp/indent.el
parent83171e456794d7e12e79e654d3613620ed6d36dd (diff)
downloademacs-2f815c8d1a21cf5cfdcb7d4c971243914e093f6f.tar.gz
(tab-to-tab-stop): Combine new indentation with previous.
Diffstat (limited to 'lisp/indent.el')
-rw-r--r--lisp/indent.el5
1 files changed, 4 insertions, 1 deletions
diff --git a/lisp/indent.el b/lisp/indent.el
index e7f4605b682..17e58241fd1 100644
--- a/lisp/indent.el
+++ b/lisp/indent.el
@@ -238,7 +238,10 @@ Use \\[edit-tab-stops] to edit them interactively."
(while (and tabs (>= (current-column) (car tabs)))
(setq tabs (cdr tabs)))
(if tabs
- (indent-to (car tabs))
+ (let ((opoint (point)))
+ (skip-chars-backward " \t")
+ (delete-region (point) opoint)
+ (indent-to (car tabs)))
(insert ?\ ))))
(defun move-to-tab-stop ()