Skip to content

Commit b5f4b6d

Browse files
committed
Impl completing method based on completing-read
This implementation provides a better input interface than display-completion-list. Also, if any of helm-mode, ido-ubiquitous-mode, ivy-mode is enabled, it use it automatically.
1 parent 51c73f0 commit b5f4b6d

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

php-mode.el

+6-5
Original file line numberDiff line numberDiff line change
@@ -1346,11 +1346,12 @@ for \\[find-tag] (which see)."
13461346
(delete-region beg (point))
13471347
(insert completion))
13481348
(t
1349-
(message "Making completion list...")
1350-
(with-output-to-temp-buffer "*Completions*"
1351-
(display-completion-list
1352-
(all-completions pattern php-functions)))
1353-
(message "Making completion list...%s" "done")))))))
1349+
(let ((selected (completing-read
1350+
"Select completion: "
1351+
(all-completions pattern php-functions)
1352+
nil t pattern)))
1353+
(delete-region beg (point))
1354+
(insert selected))))))))
13541355

13551356
(defun php-completion-table ()
13561357
"Build variable `php-completion-table' on demand.

0 commit comments

Comments
 (0)