From: Gerd Moellmann Date: Wed, 3 Nov 1999 23:50:40 +0000 (+0000) Subject: (PC-do-completion): Use minibuffer-prompt-end to X-Git-Tag: emacs-pretest-21.0.90~6181 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=f08d8594378870b383b9b1fb5076da7676c17ebb;p=emacs.git (PC-do-completion): Use minibuffer-prompt-end to find the start of the text. Use field-string to read the user input. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 48e3cacb3a8..a73988eb4be 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +1999-11-04 Gerd Moellmann + + * complete.el (PC-do-completion): Use minibuffer-prompt-end to + find the start of the text. Use field-string to read the user + input. + 1999-11-03 Gerd Moellmann * faces.el (make-face-bold, make-face-unbold, make-face-italic) diff --git a/lisp/complete.el b/lisp/complete.el index c755f725c57..5d457e27069 100644 --- a/lisp/complete.el +++ b/lisp/complete.el @@ -370,7 +370,7 @@ The function takes no arguments, and typically looks at the value of `minibuffer-completion-table' and the minibuffer contents.") (defun PC-do-completion (&optional mode beg end) - (or beg (setq beg (point-min))) + (or beg (setq beg (minibuffer-prompt-end))) (or end (setq end (point-max))) (let* ((table minibuffer-completion-table) (pred minibuffer-completion-predicate) @@ -646,7 +646,7 @@ of `minibuffer-completion-table' and the minibuffer contents.") ;; We changed it... enough to be complete? (and (eq mode 'exit) - (PC-is-complete-p (buffer-string) table pred)) + (PC-is-complete-p (field-string) table pred)) ;; If totally ambiguous, display a list of completions (if (or completion-auto-help