From: yamaoka Date: Thu, 13 Feb 2003 00:37:27 +0000 (+0000) Subject: Synch to Oort Gnus. X-Git-Tag: t-gnus-6_15_17-00-quimby~69 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=5106eb7a474db3ef9171b58a116645ef3cb3a951;p=elisp%2Fgnus.git- Synch to Oort Gnus. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 121ed5f..5c7b65b 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,10 @@ +2003-02-13 Katsumi Yamaoka + + * gnus-art.el (gnus-article-only-boring-p): Make sure that the + gnus-article-boring-faces variable is bound; use gnus-faces-at. + + * gnus-util.el (gnus-faces-at): New macro. + 2003-02-13 Michael Shields * gnus-cite.el diff --git a/lisp/gnus-art.el b/lisp/gnus-art.el index 53394c2..40cb604 100644 --- a/lisp/gnus-art.el +++ b/lisp/gnus-art.el @@ -5129,19 +5129,15 @@ Argument LINES specifies lines to be scrolled down." Something \"interesting\" is a word of at least two letters that does not have a face in `gnus-article-boring-faces'." (when (and gnus-article-skip-boring - gnus-article-boring-faces) + (boundp 'gnus-article-boring-faces) + (symbol-value 'gnus-article-boring-faces)) (save-excursion (catch 'only-boring (while (re-search-forward "\\b\\w\\w" nil t) (forward-char -1) (when (not (gnus-intersection - (cons (plist-get (text-properties-at (point)) - 'face) - (mapcar-extents - '(lambda (extent) - (extent-property extent 'face)) - nil (current-buffer) (point) (point))) - gnus-article-boring-faces)) + (gnus-faces-at (point)) + (symbol-value 'gnus-article-boring-faces))) (throw 'only-boring nil))) (throw 'only-boring t))))) diff --git a/lisp/gnus-util.el b/lisp/gnus-util.el index 551f264..6bd573d 100644 --- a/lisp/gnus-util.el +++ b/lisp/gnus-util.el @@ -744,6 +744,24 @@ and `print-level' to nil." b (setq b (next-single-property-change b 'gnus-face nil end)) prop val)))))) +(defmacro gnus-faces-at (pos) + "Return a list of faces at POS." + (if (featurep 'xemacs) + `(let* ((pos ,pos) + (faces (list (get-text-property pos 'face)))) + (mapcar-extents + (lambda (extent) + (pushnew (extent-property extent 'face) faces)) + nil (current-buffer) pos pos) + (delq nil faces)) + `(let* ((pos ,pos) + (faces (list (get-text-property pos 'face))) + (overlays (overlays-at pos))) + (while overlays + (pushnew (plist-get (overlay-properties (pop overlays)) 'face) + faces)) + (delq nil faces)))) + ;;; Protected and atomic operations. dmoore@ucsd.edu 21.11.1996 ;;; The primary idea here is to try to protect internal datastructures ;;; from becoming corrupted when the user hits C-g, or if a hook or