Mercurial > emacs
comparison lisp/facemenu.el @ 44678:dec3101535fc
(list-text-properties-at): Command deleted.
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Fri, 19 Apr 2002 00:27:07 +0000 |
parents | 352a26294253 |
children | beb07a65a445 |
comparison
equal
deleted
inserted
replaced
44677:b8ccc58cc821 | 44678:dec3101535fc |
---|---|
458 These special properties include `invisible', `intangible' and `read-only'." | 458 These special properties include `invisible', `intangible' and `read-only'." |
459 (interactive "*r") ; error if buffer is read-only despite the next line. | 459 (interactive "*r") ; error if buffer is read-only despite the next line. |
460 (let ((inhibit-read-only t)) | 460 (let ((inhibit-read-only t)) |
461 (remove-text-properties | 461 (remove-text-properties |
462 start end '(invisible nil intangible nil read-only nil)))) | 462 start end '(invisible nil intangible nil read-only nil)))) |
463 | 463 |
464 ;;; Describe-Text Mode. | 464 ;;; Describe-Text Mode. |
465 | 465 |
466 (defun describe-text-done () | 466 (defun describe-text-done () |
467 "Delete the current window or bury the current buffer." | 467 "Delete the current window or bury the current buffer." |
468 (interactive) | 468 (interactive) |
546 (describe-text-widget value)) | 546 (describe-text-widget value)) |
547 (t | 547 (t |
548 (describe-text-sexp value)))) | 548 (describe-text-sexp value)))) |
549 (widget-insert "\n") | 549 (widget-insert "\n") |
550 (setq properties (cdr (cdr properties))))) | 550 (setq properties (cdr (cdr properties))))) |
551 | 551 |
552 ;;; Describe-Text Commands. | 552 ;;; Describe-Text Commands. |
553 | 553 |
554 (defun describe-text-category (category) | 554 (defun describe-text-category (category) |
555 "Describe a text property category." | 555 "Describe a text property category." |
556 (interactive "S") | 556 (interactive "S") |
616 (when properties | 616 (when properties |
617 (widget-insert "There are text properties here:\n") | 617 (widget-insert "There are text properties here:\n") |
618 (describe-text-properties properties)) | 618 (describe-text-properties properties)) |
619 (describe-text-mode) | 619 (describe-text-mode) |
620 (goto-char (point-min))))))) | 620 (goto-char (point-min))))))) |
621 | 621 |
622 ;;; List Text Properties | |
623 | |
624 ;;;###autoload | |
625 (defun list-text-properties-at (p) | |
626 "Pop up a buffer listing text-properties at LOCATION." | |
627 (interactive "d") | |
628 (let ((props (text-properties-at p)) | |
629 category | |
630 str) | |
631 (if (null props) | |
632 (message "None") | |
633 (if (and (not (cdr (cdr props))) | |
634 (not (eq (car props) 'category)) | |
635 (< (length (setq str (format "Text property at %d: %s %S" | |
636 p (car props) (car (cdr props))))) | |
637 (frame-width))) | |
638 (message "%s" str) | |
639 (with-output-to-temp-buffer "*Text Properties*" | |
640 (princ (format "Text properties at %d:\n\n" p)) | |
641 (setq help-xref-stack nil) | |
642 (while props | |
643 (if (eq (car props) 'category) | |
644 (setq category (car (cdr props)))) | |
645 (princ (format "%-20s %S\n" | |
646 (car props) (car (cdr props)))) | |
647 (setq props (cdr (cdr props)))) | |
648 (if category | |
649 (progn | |
650 (setq props (symbol-plist category)) | |
651 (princ (format "\nCategory %s:\n\n" category)) | |
652 (while props | |
653 (princ (format "%-20s %S\n" | |
654 (car props) (car (cdr props)))) | |
655 (if (eq (car props) 'category) | |
656 (setq category (car (cdr props)))) | |
657 (setq props (cdr (cdr props))))))))))) | |
658 | |
659 ;;;###autoload | 622 ;;;###autoload |
660 (defun facemenu-read-color (&optional prompt) | 623 (defun facemenu-read-color (&optional prompt) |
661 "Read a color using the minibuffer." | 624 "Read a color using the minibuffer." |
662 (let ((col (completing-read (or prompt "Color: ") | 625 (let ((col (completing-read (or prompt "Color: ") |
663 (or facemenu-color-alist | 626 (or facemenu-color-alist |