Function: gnus-topic-hierarchical-parameters
gnus-topic-hierarchical-parameters is a byte-compiled function defined
in gnus-topic.el.gz.
Signature
(gnus-topic-hierarchical-parameters TOPIC &optional GROUP-PARAMS-LIST)
Documentation
Compute the topic parameters for TOPIC.
Possibly inherit parameters from topics above TOPIC. If optional argument GROUP-PARAMS-LIST is non-nil, use it as the basis for inheritance.
Source Code
;; Defined in /usr/src/emacs/lisp/gnus/gnus-topic.el.gz
(defun gnus-topic-hierarchical-parameters (topic &optional group-params-list)
"Compute the topic parameters for TOPIC.
Possibly inherit parameters from topics above TOPIC.
If optional argument GROUP-PARAMS-LIST is non-nil, use it as the basis for
inheritance."
(let ((params-list
;; We probably have lots of nil elements here, so we remove them.
;; Probably faster than doing this "properly".
(delq nil (cons group-params-list
(mapcar #'gnus-topic-parameters
(gnus-current-topics topic)))))
param out params)
;; Now we have all the parameters, so we go through them
;; and do inheritance in the obvious way.
(let (posting-style)
(while (setq params (pop params-list))
(while (setq param (pop params))
(when (atom param)
(setq param (cons param t)))
(cond ((eq (car param) 'posting-style)
(let ((param (cdr param))
elt)
(while (setq elt (pop param))
(unless (assoc (car elt) posting-style)
(push elt posting-style)))))
(t
(unless (assq (car param) out)
(push param out))))))
(and posting-style (push (cons 'posting-style posting-style) out)))
;; Return the resulting parameter list.
out))