aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard M. Stallman1996-03-28 04:40:34 +0000
committerRichard M. Stallman1996-03-28 04:40:34 +0000
commit25a4509f70a3f9280dc2d6cd61366a28ecef10e9 (patch)
treea05f0b6ed2b67e76e0a532cb43c58aade7f1a99c
parentb2bc29b1665501d85b855072bbc4a29d41dfebf9 (diff)
downloademacs-25a4509f70a3f9280dc2d6cd61366a28ecef10e9.tar.gz
emacs-25a4509f70a3f9280dc2d6cd61366a28ecef10e9.zip
(list-text-properties-at): Display category's properties.
-rw-r--r--lisp/facemenu.el16
1 files changed, 15 insertions, 1 deletions
diff --git a/lisp/facemenu.el b/lisp/facemenu.el
index f1d92932cb5..220b0f1fd92 100644
--- a/lisp/facemenu.el
+++ b/lisp/facemenu.el
@@ -408,10 +408,12 @@ These special properties include `invisible', `intangible' and `read-only'."
408 "Pop up a buffer listing text-properties at LOCATION." 408 "Pop up a buffer listing text-properties at LOCATION."
409 (interactive "d") 409 (interactive "d")
410 (let ((props (text-properties-at p)) 410 (let ((props (text-properties-at p))
411 category
411 str) 412 str)
412 (if (null props) 413 (if (null props)
413 (message "None") 414 (message "None")
414 (if (and (not (cdr (cdr props))) 415 (if (and (not (cdr (cdr props)))
416 (not (eq (car props) 'category))
415 (< (length (setq str (format "Text property at %d: %s %S" 417 (< (length (setq str (format "Text property at %d: %s %S"
416 p (car props) (car (cdr props))))) 418 p (car props) (car (cdr props)))))
417 (frame-width))) 419 (frame-width)))
@@ -419,9 +421,21 @@ These special properties include `invisible', `intangible' and `read-only'."
419 (with-output-to-temp-buffer "*Text Properties*" 421 (with-output-to-temp-buffer "*Text Properties*"
420 (princ (format "Text properties at %d:\n\n" p)) 422 (princ (format "Text properties at %d:\n\n" p))
421 (while props 423 (while props
424 (if (eq (car props) 'category)
425 (setq category (car (cdr props))))
422 (princ (format "%-20s %S\n" 426 (princ (format "%-20s %S\n"
423 (car props) (car (cdr props)))) 427 (car props) (car (cdr props))))
424 (setq props (cdr (cdr props))))))))) 428 (setq props (cdr (cdr props))))
429 (if category
430 (progn
431 (setq props (symbol-plist category))
432 (princ (format "\nCategory %s:\n\n" category))
433 (while props
434 (princ (format "%-20s %S\n"
435 (car props) (car (cdr props))))
436 (if (eq (car props) 'category)
437 (setq category (car (cdr props))))
438 (setq props (cdr (cdr props)))))))))))
425 439
426;;;###autoload 440;;;###autoload
427(defun facemenu-read-color (&optional prompt) 441(defun facemenu-read-color (&optional prompt)