Commit 170faae3 authored by Stefan Kangas's avatar Stefan Kangas

Add new command apropos-function (Bug#41021)

* lisp/apropos.el (apropos-function): New command.
* etc/NEWS: Announce it.
parent 4fc066a6
Pipeline #6338 failed with stage
in 58 minutes and 32 seconds
......@@ -529,6 +529,9 @@ prefix on the Subject line in various languages.
These new navigation commands are bound to 'n' and 'p' in
'apropos-mode'.
*** New command 'apropos-function'.
This works like 'C-u M-x apropos-command' but is more discoverable.
** CC Mode
*** Added support for Doxygen documentation style.
......
......@@ -543,6 +543,20 @@ will be buffer-local when set."
(and (local-variable-if-set-p symbol)
(get symbol 'variable-documentation)))))
;;;###autoload
(defun apropos-function (pattern)
"Show functions that match PATTERN.
PATTERN can be a word, a list of words (separated by spaces),
or a regexp (using some regexp special characters). If it is a word,
search for matches for that word as a substring. If it is a list of words,
search for matches for any two (or more) of those words.
This is the same as running `apropos-command' with a \\[universal-argument] prefix,
or a non-nil `apropos-do-all' argument."
(interactive (list (apropos-read-pattern "function")))
(apropos-command pattern t))
;; For auld lang syne:
;;;###autoload
(defalias 'command-apropos 'apropos-command)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment