diff options
| author | Gerd Moellmann | 2000-11-28 11:54:12 +0000 |
|---|---|---|
| committer | Gerd Moellmann | 2000-11-28 11:54:12 +0000 |
| commit | dfe8ece3726a0ee4b9a8a977fd527eb666e6e9c0 (patch) | |
| tree | 6ddb543719580451648d3f86809f28d53bd9da1c | |
| parent | 7cb668991105849ed4561b102d8550ff7f519583 (diff) | |
| download | emacs-dfe8ece3726a0ee4b9a8a977fd527eb666e6e9c0.tar.gz emacs-dfe8ece3726a0ee4b9a8a977fd527eb666e6e9c0.zip | |
(delete-horizontal-space): Handle minibuffer prompt.
| -rw-r--r-- | lisp/simple.el | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lisp/simple.el b/lisp/simple.el index 0e70e83a157..13020a98a52 100644 --- a/lisp/simple.el +++ b/lisp/simple.el | |||
| @@ -333,7 +333,8 @@ Leave one space or none, according to the context." | |||
| 333 | "Delete all spaces and tabs around point." | 333 | "Delete all spaces and tabs around point." |
| 334 | (interactive "*") | 334 | (interactive "*") |
| 335 | (skip-chars-backward " \t") | 335 | (skip-chars-backward " \t") |
| 336 | (delete-region (point) (progn (skip-chars-forward " \t") (point)))) | 336 | (let ((start (max (minibuffer-prompt-end) (point)))) |
| 337 | (delete-region start (progn (skip-chars-forward " \t") (point))))) | ||
| 337 | 338 | ||
| 338 | (defun just-one-space () | 339 | (defun just-one-space () |
| 339 | "Delete all spaces and tabs around point, leaving one space." | 340 | "Delete all spaces and tabs around point, leaving one space." |