diff options
| author | Martin Rudalics <rudalics@gmx.at> | 2015-04-23 09:11:59 +0200 |
|---|---|---|
| committer | Martin Rudalics <rudalics@gmx.at> | 2015-04-23 09:11:59 +0200 |
| commit | 62fe329762301b4edf546e74893d9169906ffa96 (patch) | |
| tree | bd89aeb9d7b6a3137f3cead291993ac243e6bd77 /lisp/wid-edit.el | |
| parent | 557c7d6fc6a6520a7ca92d2d006299fae0978aa3 (diff) | |
| download | emacs-62fe329762301b4edf546e74893d9169906ffa96.tar.gz | |
Fix following doc-links in `widget-documentation-link-action'
* lisp/wid-edit.el (widget-documentation-link-action): Make
following doc-links less simplistic (Bug#20398).
Diffstat (limited to 'lisp/wid-edit.el')
| -rw-r--r-- | lisp/wid-edit.el | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/lisp/wid-edit.el b/lisp/wid-edit.el index 04a900f23c0..0a9578391e0 100644 --- a/lisp/wid-edit.el +++ b/lisp/wid-edit.el @@ -2846,9 +2846,17 @@ The following properties have special meanings for this widget: (if (and (fboundp symbol) (boundp symbol)) ;; If there are two doc strings, give the user a way to pick one. (apropos (concat "\\`" (regexp-quote string) "\\'")) - (if (fboundp symbol) - (describe-function symbol) - (describe-variable symbol))))) + (cond + ((fboundp symbol) + (describe-function symbol)) + ((facep symbol) + (describe-face symbol)) + ((featurep symbol) + (describe-package symbol)) + ((or (boundp symbol) (get symbol 'variable-documentation)) + (describe-variable symbol)) + (t + (message "No documentation available for %s" symbol)))))) (defcustom widget-documentation-links t "Add hyperlinks to documentation strings when non-nil." |
