1 ;;; gnus-cus.el --- customization commands for Gnus
3 ;; Copyright (C) 1996,1999, 2000 Free Software Foundation, Inc.
5 ;; Author: Per Abrahamsen <abraham@dina.kvl.dk>
8 ;; This file is part of GNU Emacs.
10 ;; GNU Emacs is free software; you can redistribute it and/or modify
11 ;; it under the terms of the GNU General Public License as published by
12 ;; the Free Software Foundation; either version 2, or (at your option)
15 ;; GNU Emacs is distributed in the hope that it will be useful,
16 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
17 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 ;; GNU General Public License for more details.
20 ;; You should have received a copy of the GNU General Public License
21 ;; along with GNU Emacs; see the file COPYING. If not, write to the
22 ;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
23 ;; Boston, MA 02111-1307, USA.
37 ;; There should be special validation for this.
38 (define-widget 'gnus-email-address 'string
41 (defun gnus-custom-mode ()
42 "Major mode for editing Gnus customization buffers.
44 The following commands are available:
46 \\[widget-forward] Move to next button or editable field.
47 \\[widget-backward] Move to previous button or editable field.
48 \\[widget-button-click] Activate button under the mouse pointer.
49 \\[widget-button-press] Activate button under point.
51 Entry to this mode calls the value of `gnus-custom-mode-hook'
52 if that value is non-nil."
53 (kill-all-local-variables)
54 (setq major-mode 'gnus-custom-mode
55 mode-name "Gnus Customize")
56 (use-local-map widget-keymap)
58 (when (and (facep 'custom-button-face)
59 (facep 'custom-button-pressed-face))
60 (set (make-local-variable 'widget-button-face)
62 (set (make-local-variable 'widget-button-pressed-face)
63 'custom-button-pressed-face)
64 (set (make-local-variable 'widget-mouse-face)
65 'custom-button-pressed-face))
66 (when (and (boundp 'custom-raised-buttons)
67 (symbol-value 'custom-raised-buttons))
68 (set (make-local-variable 'widget-push-button-prefix) "")
69 (set (make-local-variable 'widget-push-button-suffix) "")
70 (set (make-local-variable 'widget-link-prefix) "")
71 (set (make-local-variable 'widget-link-suffix) ""))
72 (gnus-run-hooks 'gnus-custom-mode-hook))
74 ;;; Group Customization:
76 (defconst gnus-group-parameters
77 '((to-address (gnus-email-address :tag "To Address") "\
78 This will be used when doing followups and posts.
80 This is primarily useful in mail groups that represent closed
81 mailing lists--mailing lists where it's expected that everybody that
82 writes to the mailing list is subscribed to it. Since using this
83 parameter ensures that the mail only goes to the mailing list itself,
84 it means that members won't receive two copies of your followups.
86 Using `to-address' will actually work whether the group is foreign or
87 not. Let's say there's a group on the server that is called
88 `fa.4ad-l'. This is a real newsgroup, but the server has gotten the
89 articles from a mail-to-news gateway. Posting directly to this group
90 is therefore impossible--you have to send mail to the mailing list
93 The gnus-group-split mail splitting mechanism will behave as if this
94 address was listed in gnus-group-split Addresses (see below).")
96 (to-list (gnus-email-address :tag "To List") "\
97 This address will be used when doing a `a' in the group.
99 It is totally ignored when doing a followup--except that if it is
100 present in a news group, you'll get mail group semantics when doing
103 The gnus-group-split mail splitting mechanism will behave as if this
104 address was listed in gnus-group-split Addresses (see below).")
106 (extra-aliases (choice
112 (gnus-email-address :tag "Address")))
113 (gnus-email-address :tag "Address")) "\
114 Store messages posted from or to this address in this group.
116 You must be using gnus-group-split for this to work. The VALUE of the
117 nnmail-split-fancy SPLIT generated for this group will match these
120 (split-regexp (regexp :tag "gnus-group-split Regular Expression") "\
121 Like gnus-group-split Address, but expects a regular expression.")
123 (split-exclude (list :tag "gnus-group-split Restricts"
125 :inline t (regexp :tag "Restrict"))) "\
126 Regular expression that cancels gnus-group-split matches.
128 Each entry is added to the nnmail-split-fancy SPLIT as a separate
131 (split-spec (choice :tag "gnus-group-split Overrider"
132 (sexp :tag "Fancy Split")
133 (const :tag "Catch All" catch-all)
134 (const :tag "Ignore" nil)) "\
135 Override all other gnus-group-split fields.
137 In `Fancy Split', you can enter any nnmail-split-fancy SPLIT. Note
138 that the name of this group won't be automatically assumed, you have
139 to add it to the SPLITs yourself. This means you can use such splits
140 to split messages to other groups too.
142 If you select `Catch All', this group will get postings for any
143 messages not matched in any other group. It overrides the variable
144 gnus-group-split-default-catch-all-group.
146 Selecting `Ignore' forces no SPLIT to be generated for this group,
147 disabling all other gnus-group-split fields.")
149 (broken-reply-to (const :tag "Broken Reply To" t) "\
150 Ignore `Reply-To' headers in this group.
152 That can be useful if you're reading a mailing list group where the
153 listserv has inserted `Reply-To' headers that point back to the
154 listserv itself. This is broken behavior. So there!")
156 (to-group (string :tag "To Group") "\
157 All posts will be sent to the specified group.")
159 (gcc-self (choice :tag "GCC"
161 (const :tag "To current group" t)
163 (string :format "%v" :hide-front-space t)) "\
164 Specify default value for GCC header.
166 If this symbol is present in the group parameter list and set to `t',
167 new composed messages will be `Gcc''d to the current group. If it is
168 present and set to `none', no `Gcc:' header will be generated, if it
169 is present and a string, this string will be inserted literally as a
170 `gcc' header (this symbol takes precedence over any default `Gcc'
171 rules as described later).")
173 (expiry-wait (choice :tag "Expire Wait"
177 (number :hide-front-space t
181 Overrides any `nnmail-expiry-wait' and `nnmail-expiry-wait-function'
182 when expiring expirable messages. The value can either be a number of
183 days (not necessarily an integer) or the symbols `never' or
186 (expiry-target (choice :tag "Expiry Target"
189 (function :format "%v" nnmail-)
191 Where expired messages end up.
193 Overrides `nnmail-expiry-target', which see.")
195 (score-file (file :tag "Score File") "\
196 Make the specified file into the current score file.
197 This means that all score commands you issue will end up in this file.")
199 (adapt-file (file :tag "Adapt File") "\
200 Make the specified file into the current adaptive file.
201 All adaptive score entries will be put into this file.")
203 (admin-address (gnus-email-address :tag "Admin Address") "\
204 Administration address for a mailing list.
206 When unsubscribing to a mailing list you should never send the
207 unsubscription notice to the mailing list itself. Instead, you'd
208 send messages to the administrative address. This parameter allows
209 you to put the admin address somewhere convenient.")
211 (display (choice :tag "Display"
215 Which articles to display on entering the group.
218 Display all articles, both read and unread.
221 Display the default visible articles, which normally includes
222 unread and ticked articles.")
224 (comment (string :tag "Comment") "\
225 An arbitrary comment on the group.")
227 (visible (const :tag "Permanently visible" t) "\
228 Always display this group, even when there are no unread articles
231 (charset (symbol :tag "Charset") "\
232 The default charset to use in the group.")
235 (choice :tag "Ignored charsets"
237 (repeat (symbol))) "\
238 List of charsets that should be ignored.
240 When these charsets are used in the \"charset\" parameter, the
241 default charset will be used instead.")
244 (choice :tag "Highlight words"
246 (repeat (list (regexp :tag "Highlight regexp")
247 (number :tag "Group for entire word" 0)
248 (number :tag "Group for displayed part" 0)
250 gnus-emphasis-highlight-words))))
252 See gnus-emphasis-alist.")
255 (choice :tag "Posting style"
261 (const signature-file)
266 (string :format "%v"))))
268 See gnus-posting-styles."))
269 "Alist of valid group or topic parameters.
271 Each entry has the form (NAME TYPE DOC), where NAME is the parameter
272 itself (a symbol), TYPE is the parameters type (a sexp widget), and
273 DOC is a documentation string for the parameter.")
275 (defconst gnus-extra-topic-parameters
276 '((subscribe (regexp :tag "Subscribe") "\
277 If `gnus-subscribe-newsgroup-method' or
278 `gnus-subscribe-options-newsgroup-method' is set to
279 `gnus-subscribe-topics', new groups that matches this regexp will
280 automatically be subscribed to this topic"))
281 "Alist of topic parameters that are not also group parameters.
283 Each entry has the form (NAME TYPE DOC), where NAME is the parameter
284 itself (a symbol), TYPE is the parameters type (a sexp widget), and
285 DOC is a documentation string for the parameter.")
287 (defconst gnus-extra-group-parameters
288 '((uidvalidity (string :tag "IMAP uidvalidity") "\
289 Server-assigned value attached to IMAP groups, used to maintain consistency."))
290 "Alist of group parameters that are not also topic parameters.
292 Each entry has the form (NAME TYPE DOC), where NAME is the parameter
293 itself (a symbol), TYPE is the parameters type (a sexp widget), and
294 DOC is a documentation string for the parameter.")
295 (defvar gnus-custom-params)
296 (defvar gnus-custom-method)
297 (defvar gnus-custom-group)
298 (defvar gnus-custom-topic)
300 (defun gnus-group-customize (group &optional topic)
301 "Edit the group or topic on the current line."
302 (interactive (list (gnus-group-group-name) (gnus-group-topic-name)))
304 (types (mapcar (lambda (entry)
305 `(cons :format "%v%h\n"
307 (const :format "" ,(nth 0 entry))
309 (append gnus-group-parameters
310 (reverse gnus-group-parameters-more)
312 gnus-extra-group-parameters
313 gnus-extra-topic-parameters)))))
314 (unless (or group topic)
315 (error "No group on current line"))
316 (when (and group topic)
317 (error "Both a group an topic on current line"))
318 (unless (or topic (setq info (gnus-get-info group)))
319 (error "Killed group; can't be edited"))
321 (kill-buffer (gnus-get-buffer-create "*Gnus Customize*"))
322 (switch-to-buffer (gnus-get-buffer-create "*Gnus Customize*"))
324 (make-local-variable 'gnus-custom-group)
325 (setq gnus-custom-group group)
326 (make-local-variable 'gnus-custom-topic)
327 (setq gnus-custom-topic topic)
328 (buffer-disable-undo)
329 (widget-insert "Customize the ")
331 (widget-create 'info-link
332 :help-echo "Push me to learn more."
333 :tag "group parameters"
334 "(gnus)Group Parameters")
335 (widget-create 'info-link
336 :help-echo "Push me to learn more."
337 :tag "topic parameters"
338 "(gnus)Topic Parameters"))
339 (widget-insert " for <")
340 (widget-insert (gnus-group-decoded-name (or group topic)))
341 (widget-insert "> and press ")
342 (widget-create 'push-button
344 :help-echo "Push me when done customizing."
345 :action 'gnus-group-customize-done)
346 (widget-insert ".\n\n")
347 (make-local-variable 'gnus-custom-params)
348 (setq gnus-custom-params
349 (widget-create 'group
351 (gnus-info-params info)
352 (gnus-topic-parameters topic))
358 These special parameters are recognized by Gnus.
359 Check the [ ] for the parameters you want to apply to this group or
360 to the groups in this topic, then edit the value to suit your taste."
364 :format "%t:\n%h%v%i\n\n"
366 Set variables local to the group you are entering.
368 If you want to turn threading off in `news.answers', you could put
369 `(gnus-show-threads nil)' in the group parameters of that group.
370 `gnus-show-threads' will be made into a local variable in the summary
371 buffer you enter, and the form `nil' will be `eval'ed there.
373 This can also be used as a group-specific hook function, if you'd
374 like. If you want to hear a beep when you enter a group, you could
375 put something like `(dummy-variable (ding))' in the parameters of that
376 group. `dummy-variable' will be set to the result of the `(ding)'
377 form, but who cares?"
378 (list :format "%v" :value (nil nil)
379 (symbol :tag "Variable")
384 :tag "Unknown entries"
387 (widget-insert "\n\nYou can also edit the ")
388 (widget-create 'info-link
390 :help-echo "Push me to learn more about select methods."
391 "(gnus)Select Methods")
392 (widget-insert " for the group.\n")
393 (setq gnus-custom-method
396 :value (gnus-info-method info))))
397 (use-local-map widget-keymap)
400 (goto-char (point-min))))
402 (defun gnus-group-customize-done (&rest ignore)
403 "Apply changes and bury the buffer."
405 (if gnus-custom-topic
406 (gnus-topic-set-parameters gnus-custom-topic
407 (widget-value gnus-custom-params))
408 (gnus-group-edit-group-done 'params gnus-custom-group
409 (widget-value gnus-custom-params))
410 (gnus-group-edit-group-done 'method gnus-custom-group
411 (widget-value gnus-custom-method)))
414 ;;; Score Customization:
416 (defconst gnus-score-parameters
417 '((mark (number :tag "Mark") "\
418 The value of this entry should be a number.
419 Any articles with a score lower than this number will be marked as read.")
421 (expunge (number :tag "Expunge") "\
422 The value of this entry should be a number.
423 Any articles with a score lower than this number will be removed from
424 the summary buffer.")
426 (mark-and-expunge (number :tag "Mark-and-expunge") "\
427 The value of this entry should be a number.
428 Any articles with a score lower than this number will be marked as
429 read and removed from the summary buffer.")
431 (thread-mark-and-expunge (number :tag "Thread-mark-and-expunge") "\
432 The value of this entry should be a number.
433 All articles that belong to a thread that has a total score below this
434 number will be marked as read and removed from the summary buffer.
435 `gnus-thread-score-function' says how to compute the total score
438 (files (repeat :inline t :tag "Files" file) "\
439 The value of this entry should be any number of file names.
440 These files are assumed to be score files as well, and will be loaded
441 the same way this one was.")
443 (exclude-files (repeat :inline t :tag "Exclude-files" file) "\
444 The clue of this entry should be any number of files.
445 These files will not be loaded, even though they would normally be so,
446 for some reason or other.")
448 (eval (sexp :tag "Eval" :value nil) "\
449 The value of this entry will be `eval'el.
450 This element will be ignored when handling global score files.")
452 (read-only (boolean :tag "Read-only" :value t) "\
453 Read-only score files will not be updated or saved.
454 Global score files should feature this atom.")
456 (orphan (number :tag "Orphan") "\
457 The value of this entry should be a number.
458 Articles that do not have parents will get this number added to their
459 scores. Imagine you follow some high-volume newsgroup, like
460 `comp.lang.c'. Most likely you will only follow a few of the threads,
461 also want to see any new threads.
463 You can do this with the following two score file entries:
466 (mark-and-expunge -100)
468 When you enter the group the first time, you will only see the new
469 threads. You then raise the score of the threads that you find
470 interesting (with `I T' or `I S'), and ignore (`C y') the rest.
471 Next time you enter the group, you will see new articles in the
472 interesting threads, plus any new threads.
474 I.e.---the orphan score atom is for high-volume groups where there
475 exist a few interesting threads which can't be found automatically
476 by ordinary scoring rules.")
478 (adapt (choice :tag "Adapt"
482 :hide-front-space t)) "\
483 This entry controls the adaptive scoring.
484 If it is `t', the default adaptive scoring rules will be used. If it
485 is `ignore', no adaptive scoring will be performed on this group. If
486 it is a list, this list will be used as the adaptive scoring rules.
487 If it isn't present, or is something other than `t' or `ignore', the
488 default adaptive scoring rules will be used. If you want to use
489 adaptive scoring on most groups, you'd set `gnus-use-adaptive-scoring'
490 to `t', and insert an `(adapt ignore)' in the groups where you do not
491 want adaptive scoring. If you only want adaptive scoring in a few
492 groups, you'd set `gnus-use-adaptive-scoring' to `nil', and insert
493 `(adapt t)' in the score files of the groups where you want it.")
495 (adapt-file (file :tag "Adapt-file") "\
496 All adaptive score entries will go to the file named by this entry.
497 It will also be applied when entering the group. This atom might
498 be handy if you want to adapt on several groups at once, using the
499 same adaptive file for a number of groups.")
501 (local (repeat :tag "Local"
502 (group :value (nil nil)
503 (symbol :tag "Variable")
504 (sexp :tag "Value"))) "\
505 The value of this entry should be a list of `(VAR VALUE)' pairs.
506 Each VAR will be made buffer-local to the current summary buffer,
507 and set to the value specified. This is a convenient, if somewhat
508 strange, way of setting variables in some groups if you don't like
510 (touched (sexp :format "Touched\n") "Internal variable."))
511 "Alist of valid symbolic score parameters.
513 Each entry has the form (NAME TYPE DOC), where NAME is the parameter
514 itself (a symbol), TYPE is the parameters type (a sexp widget), and DOC is a
515 documentation string for the parameter.")
517 (define-widget 'gnus-score-string 'group
518 "Edit score entries for string-valued headers."
519 :convert-widget 'gnus-score-string-convert)
521 (defun gnus-score-string-convert (widget)
522 ;; Set args appropriately.
523 (let* ((tag (widget-get widget :tag))
524 (item `(const :format "" :value ,(downcase tag)))
525 (match '(string :tag "Match"))
526 (score '(choice :tag "Score"
527 (const :tag "default" nil)
528 (integer :format "%v"
529 :hide-front-space t)))
530 (expire '(choice :tag "Expire"
531 (const :tag "off" nil)
532 (integer :format "%v"
533 :hide-front-space t)))
534 (type '(choice :tag "Type"
536 ;; I should really create a forgiving :match
537 ;; function for each type below, that only
538 ;; looked at the first letter.
539 (const :tag "Regexp" r)
540 (const :tag "Regexp (fixed case)" R)
541 (const :tag "Substring" s)
542 (const :tag "Substring (fixed case)" S)
543 (const :tag "Exact" e)
544 (const :tag "Exact (fixed case)" E)
545 (const :tag "Word" w)
546 (const :tag "Word (fixed case)" W)
547 (const :tag "default" nil)))
548 (group `(group ,match ,score ,expire ,type))
549 (doc (concat (or (widget-get widget :doc)
550 (concat "Change score based on the " tag
553 You can have an arbitrary number of score entries for this header,
554 each score entry has four elements:
556 1. The \"match element\". This should be the string to look for in the
559 2. The \"score element\". This number should be an integer in the
560 neginf to posinf interval. This number is added to the score
561 of the article if the match is successful. If this element is
562 not present, the `gnus-score-interactive-default-score' number
563 will be used instead. This is 1000 by default.
565 3. The \"date element\". This date says when the last time this score
566 entry matched, which provides a mechanism for expiring the
567 score entries. It this element is not present, the score
568 entry is permanent. The date is represented by the number of
569 days since December 31, 1 ce.
571 4. The \"type element\". This element specifies what function should
572 be used to see whether this score entry matches the article.
574 There are the regexp, as well as substring types, and exact match,
575 and word match types. If this element is not present, Gnus will
576 assume that substring matching should be used. There is case
577 sensitive variants of all match types.")))
578 (widget-put widget :args `(,item
583 :format "%t:\n%h%v%i\n\n"
585 :value ("" nil nil s)
590 (define-widget 'gnus-score-integer 'group
591 "Edit score entries for integer-valued headers."
592 :convert-widget 'gnus-score-integer-convert)
594 (defun gnus-score-integer-convert (widget)
595 ;; Set args appropriately.
596 (let* ((tag (widget-get widget :tag))
597 (item `(const :format "" :value ,(downcase tag)))
598 (match '(integer :tag "Match"))
599 (score '(choice :tag "Score"
600 (const :tag "default" nil)
601 (integer :format "%v"
602 :hide-front-space t)))
603 (expire '(choice :tag "Expire"
604 (const :tag "off" nil)
605 (integer :format "%v"
606 :hide-front-space t)))
607 (type '(choice :tag "Type"
614 (group `(group ,match ,score ,expire ,type))
615 (doc (concat (or (widget-get widget :doc)
616 (concat "Change score based on the " tag
618 (widget-put widget :args `(,item
623 :format "%t:\n%h%v%i\n\n"
627 (define-widget 'gnus-score-date 'group
628 "Edit score entries for date-valued headers."
629 :convert-widget 'gnus-score-date-convert)
631 (defun gnus-score-date-convert (widget)
632 ;; Set args appropriately.
633 (let* ((tag (widget-get widget :tag))
634 (item `(const :format "" :value ,(downcase tag)))
635 (match '(string :tag "Match"))
636 (score '(choice :tag "Score"
637 (const :tag "default" nil)
638 (integer :format "%v"
639 :hide-front-space t)))
640 (expire '(choice :tag "Expire"
641 (const :tag "off" nil)
642 (integer :format "%v"
643 :hide-front-space t)))
644 (type '(choice :tag "Type"
650 (group `(group ,match ,score ,expire ,type))
651 (doc (concat (or (widget-get widget :doc)
652 (concat "Change score based on the " tag
655 For the Date header we have three kinda silly match types: `before',
656 `at' and `after'. I can't really imagine this ever being useful, but,
657 like, it would feel kinda silly not to provide this function. Just in
658 case. You never know. Better safe than sorry. Once burnt, twice
659 shy. Don't judge a book by its cover. Never not have sex on a first
660 date. (I have been told that at least one person, and I quote,
661 \"found this function indispensable\", however.)
663 A more useful match type is `regexp'. With it, you can match the date
664 string using a regular expression. The date is normalized to ISO8601
665 compact format first---`YYYYMMDDTHHMMSS'. If you want to match all
666 articles that have been posted on April 1st in every year, you could
667 use `....0401.........' as a match string, for instance. (Note that
668 the date is kept in its original time zone, so this will match
669 articles that were posted when it was April 1st where the article was
670 posted from. Time zones are such wholesome fun for the whole family,
672 (widget-put widget :args `(,item
677 :format "%t:\n%h%v%i\n\n"
681 (defvar gnus-custom-scores)
682 (defvar gnus-custom-score-alist)
684 (defun gnus-score-customize (file)
685 "Customize score file FILE."
686 (interactive (list gnus-current-score-file))
687 (let ((scores (gnus-score-load file))
688 (types (mapcar (lambda (entry)
689 `(group :format "%v%h\n"
691 (const :format "" ,(nth 0 entry))
693 gnus-score-parameters)))
695 (kill-buffer (gnus-get-buffer-create "*Gnus Customize*"))
696 (switch-to-buffer (gnus-get-buffer-create "*Gnus Customize*"))
698 (make-local-variable 'gnus-custom-score-alist)
699 (setq gnus-custom-score-alist scores)
700 (widget-insert "Customize the ")
701 (widget-create 'info-link
702 :help-echo "Push me to learn more."
704 "(gnus)Score File Format")
705 (widget-insert " for\n\t")
707 (widget-insert "\nand press ")
708 (widget-create 'push-button
710 :help-echo "Push me when done customizing."
711 :action 'gnus-score-customize-done)
713 Check the [ ] for the entries you want to apply to this score file, then
714 edit the value to suit your taste. Don't forget to mark the checkbox,
715 if you do all your changes will be lost. ")
716 (widget-create 'push-button
717 :action (lambda (&rest ignore)
718 (require 'gnus-audio)
719 (gnus-audio-play "Evil_Laugh.au"))
721 (widget-insert "\n\n")
722 (make-local-variable 'gnus-custom-scores)
723 (setq gnus-custom-scores
724 (widget-create 'group
726 `(checklist :inline t
728 (gnus-score-string :tag "From")
729 (gnus-score-string :tag "Subject")
730 (gnus-score-string :tag "References")
731 (gnus-score-string :tag "Xref")
732 (gnus-score-string :tag "Extra")
733 (gnus-score-string :tag "Message-ID")
734 (gnus-score-integer :tag "Lines")
735 (gnus-score-integer :tag "Chars")
736 (gnus-score-date :tag "Date")
737 (gnus-score-string :tag "Head"
739 Match all headers in the article.
741 Using one of `Head', `Body', `All' will slow down scoring considerable.
743 (gnus-score-string :tag "Body"
745 Match the body sans header of the article.
747 Using one of `Head', `Body', `All' will slow down scoring considerable.
749 (gnus-score-string :tag "All"
751 Match the entire article, including both headers and body.
753 Using one of `Head', `Body', `All' will slow down scoring
756 (gnus-score-string :tag
759 Score all followups to the specified authors.
761 This entry is somewhat special, in that it will match the `From:'
762 header, and affect the score of not only the matching articles, but
763 also all followups to the matching articles. This allows you
764 e.g. increase the score of followups to your own articles, or decrease
765 the score of followups to the articles of some known trouble-maker.
767 (gnus-score-string :tag "Thread"
769 Add a score entry on all articles that are part of a thread.
771 This match key works along the same lines as the `Followup' match key.
772 If you say that you want to score on a (sub-)thread that is started by
773 an article with a `Message-ID' X, then you add a `thread' match. This
774 will add a new `thread' match for each article that has X in its
775 `References' header. (These new `thread' matches will use the
776 `Message-ID's of these matching articles.) This will ensure that you
777 can raise/lower the score of an entire thread, even though some
778 articles in the thread may not have complete `References' headers.
779 Note that using this may lead to undeterministic scores of the
780 articles in the thread.
784 :tag "Unknown entries"
786 (use-local-map widget-keymap)
789 (defun gnus-score-customize-done (&rest ignore)
790 "Reset the score alist with the present value."
791 (let ((alist gnus-custom-score-alist)
792 (value (widget-value gnus-custom-scores)))
793 (setcar alist (car value))
794 (setcdr alist (cdr value))
795 (gnus-score-set 'touched '(t) alist))
802 ;;; gnus-cus.el ends here