changeset 17167:81e18e642412

(apropos): Print all property symbols.
author Karl Heuer <kwzh@gnu.org>
date Mon, 17 Mar 1997 09:54:01 +0000
parents 1c7f93c8670b
children 53314a257690
files lisp/apropos.el
diffstat 1 files changed, 15 insertions(+), 15 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/apropos.el	Mon Mar 17 09:37:32 1997 +0000
+++ b/lisp/apropos.el	Mon Mar 17 09:54:01 1997 +0000
@@ -185,24 +185,24 @@
   (apropos-print
    (or do-all apropos-do-all)
    (lambda (p)
-     (let (symbol doc)
+     (let (symbol doc properties)
        (while p
 	 (setcar p (list
 		    (setq symbol (car p))
-		    (if (fboundp symbol)
-			(if (setq doc (documentation symbol t))
-			    (substring doc 0 (string-match "\n" doc))
-			  "(not documented)"))
-		    (if (boundp symbol)
-			(if (setq doc (documentation-property
-				       symbol 'variable-documentation t))
-			    (substring doc 0
-				       (string-match "\n" doc))
-			  "(not documented)"))
-		    (if (setq doc (symbol-plist symbol))
-			(if (eq (/ (length doc) 2) 1)
-			    (format "1 property (%s)" (car doc))
-			  (concat (/ (length doc) 2) " properties")))))
+		    (when (fboundp symbol)
+		      (if (setq doc (documentation symbol t))
+			  (substring doc 0 (string-match "\n" doc))
+			"(not documented)"))
+		    (when (boundp symbol)
+		      (if (setq doc (documentation-property
+				     symbol 'variable-documentation t))
+			  (substring doc 0 (string-match "\n" doc))
+			"(not documented)"))
+		    (when (setq properties (symbol-plist symbol))
+		      (setq doc (list (car properties)))
+		      (while (setq properties (cdr (cdr properties)))
+			(setq doc (cons (car properties) doc)))
+		      (mapconcat #'symbol-name (nreverse doc) " "))))
 	 (setq p (cdr p)))))
    nil))