From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/50787 Path: main.gmane.org!not-for-mail From: Kevin Greiner Newsgroups: gmane.emacs.gnus.general Subject: Re: trouble with gnus-define-group-parameter Date: Tue, 11 Mar 2003 14:25:45 -0600 Sender: owner-ding@hpc.uh.edu Message-ID: References: <4nwuj7krtf.fsf@lockgroove.bwh.harvard.edu> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1047414702 3523 80.91.224.249 (11 Mar 2003 20:31:42 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Tue, 11 Mar 2003 20:31:42 +0000 (UTC) Original-X-From: owner-ding@hpc.uh.edu Tue Mar 11 21:31:40 2003 Return-path: Original-Received: from malifon.math.uh.edu ([129.7.128.13]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 18sqKW-0000UX-00 for ; Tue, 11 Mar 2003 21:26:32 +0100 Original-Received: from sina.hpc.uh.edu ([129.7.128.10] ident=lists) by malifon.math.uh.edu with esmtp (Exim 3.20 #1) id 18sqKD-0001iX-00; Tue, 11 Mar 2003 14:26:13 -0600 Original-Received: by sina.hpc.uh.edu (TLB v0.09a (1.20 tibbs 1996/10/09 22:03:07)); Tue, 11 Mar 2003 14:27:13 -0600 (CST) Original-Received: from sclp3.sclp.com (sclp3.sclp.com [66.230.238.2]) by sina.hpc.uh.edu (8.9.3/8.9.3) with SMTP id OAA21261 for ; Tue, 11 Mar 2003 14:27:01 -0600 (CST) Original-Received: (qmail 17910 invoked by alias); 11 Mar 2003 20:25:56 -0000 Original-Received: (qmail 17904 invoked from network); 11 Mar 2003 20:25:55 -0000 Original-Received: from quimby.gnus.org (80.91.224.244) by 66.230.238.6 with SMTP; 11 Mar 2003 20:25:55 -0000 Original-Received: from news by quimby.gnus.org with local (Exim 3.12 #1 (Debian)) id 18sqg6-0003jO-00 for ; Tue, 11 Mar 2003 21:48:50 +0100 Original-To: ding@gnus.org Original-Path: not-for-mail Original-Newsgroups: gnus.ding Original-Lines: 62 Original-NNTP-Posting-Host: h-66-134-21-50.hstqtx02.covad.net Original-X-Trace: quimby.gnus.org 1047415730 13930 66.134.21.50 (11 Mar 2003 20:48:50 GMT) Original-X-Complaints-To: usenet@quimby.gnus.org Original-NNTP-Posting-Date: 11 Mar 2003 20:48:50 GMT User-Agent: Gnus/5.090016 (Oort Gnus v0.16) Emacs/21.2 (windows-nt) Cancel-Lock: sha1:pKA0qs9bWA0LFiHpP9G11ogVAMg= Precedence: list X-Majordomo: 1.94.jlt7 Xref: main.gmane.org gmane.emacs.gnus.general:50787 X-Report-Spam: http://spam.gmane.org/gmane.emacs.gnus.general:50787 Ted Zlatanov writes: > I'm defining these two group parameters: > > (gnus-define-group-parameter > ham-marks > :parameter-type '(choice :tag "Ham marks" > :value nil > (list :tag "Ham mark choices" > (set > (variable-item gnus-del-mark) > (variable-item gnus-read-mark) > (variable-item gnus-killed-mark) > (variable-item gnus-kill-file-mark) > (variable-item gnus-low-score-mark)))) > > :parameter-document > "Marks considered ham (positively not spam). Such articles will be > processed as ham (non-spam) on group exit. When nil, the global > spam-ham-marks variable takes precedence.") > > (gnus-define-group-parameter > spam-marks > :parameter-type '(choice :tag "Spam marks" > :value nil > (list :tag "Spam mark choices" > (set > (variable-item gnus-spam-mark) > (variable-item gnus-killed-mark) > (variable-item gnus-kill-file-mark) > (variable-item gnus-low-score-mark)))) > > :parameter-document > "Marks considered spam. > Such articles will be processed as spam on group exit. When nil, the global > spam-spam-marks variable takes precedence.")) > > I can customize the parameter just fine, but then > > (gnus-parameter-ham-marks gnus-newsgroup-name) > > returns nil no matter what. Anyone with a clue as to what I'm doing wrong? Not really. The gnus-define-group-parameter macro expanded to include this definition for ham-marks. Perhaps you can eval it then step through it with the debugger. (defun gnus-parameter-ham-marks (name) "" (and name (or (gnus-group-find-parameter name (quote ham-marks) nil) (let ((alist gnus-parameter-ham-marks-alist) elem value) (while (setq elem (pop alist)) (when (and name (string-match (car elem) name)) (setq alist nil value (cdr elem)))) (if (consp value) (car value) value))))) Kevin