Gnus development mailing list
 help / color / mirror / Atom feed
From: Romain Francoise <romain@orebokech.com>
Subject: Re: CVS update of gnus/lisp (ChangeLog gnus-sum.el)
Date: Tue, 16 Nov 2004 19:23:51 +0100	[thread overview]
Message-ID: <87is85tzyg.fsf@orebokech.com> (raw)
In-Reply-To: <m3u0rshyfw.fsf@defun.localdomain> (Jesper Harder's message of "Sun, 14 Nov 2004 23:12:51 +0100")

Jesper Harder <harder@ifa.au.dk> writes:

>> As a side(?) effect of this change my `gnus-summary-expunge-below'
>> gets reset to nil every time I have visited a summary buffer.
>> 
>> Is this the intended behaviour? How do I give it a global value
>> then?

> I guess it is, see below:

> `gnus-summary-expunge-below'
>      Don't display the summary lines of articles that have scores lower
>      than this variable.  This is `nil' by default, which means that no
>      articles will be hidden.  This variable is local to the summary
>      buffers, and has to be set from `gnus-summary-mode-hook'.

This is wrong.  Why then would there be a defcustom for it?

In gnus-sum you will see that some local variables get their value from
global values (cons cells who have a 'global cdr), and your change has
the side effect of making all global values be cleared on summary exit,
losing the customization.  This is also why articles with a negative
score are no longer marked as read: gnus-summary-mark-below gets reset
to nil from its default value of zero.

I suggest the following patch which fixes both problems: it removes the
"also clear global values" part, which in fact never worked since global
variable were apparently not reset.
(It may be fuzzy, I have other changes in gnus-sum.el.)

Index: gnus-sum.el
===================================================================
RCS file: /usr/local/cvsroot/gnus/lisp/gnus-sum.el,v
retrieving revision 7.66
diff -u -r7.66 gnus-sum.el
--- gnus-sum.el	7 Nov 2004 22:00:10 -0000	7.66
+++ gnus-sum.el	16 Nov 2004 18:18:30 -0000
@@ -6704,12 +6718,6 @@
 	  (gnus-summary-clear-local-variables))
 	(when (get-buffer gnus-article-buffer)
 	  (bury-buffer gnus-article-buffer))
-	;; We clear the global counterparts of the buffer-local
-	;; variables as well, just to be on the safe side.
-	(set-buffer gnus-group-buffer)
-	(gnus-summary-clear-local-variables)
-	(let ((gnus-summary-local-variables gnus-newsgroup-variables))
-	  (gnus-summary-clear-local-variables))
 	;; Return to group mode buffer.
 	(when (eq mode 'gnus-summary-mode)
 	  (gnus-kill-buffer buf)))

-- 
Romain Francoise <romain@orebokech.com> | There's no stronger wind than
it's a miracle -- http://orebokech.com/ | the one that blows down a
                                        | lonesome railroad line.



  parent reply	other threads:[~2004-11-16 18:23 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <E1CQv51-00070O-00@quimby.gnus.org>
2004-11-11 18:18 ` Arne Jørgensen
2004-11-14 22:12   ` Jesper Harder
2004-11-15 11:06     ` Arne Jørgensen
2004-11-16 18:23     ` Romain Francoise [this message]
2004-12-09 14:31       ` Katsumi Yamaoka
2004-12-09 23:59         ` Arnaud Giersch
2004-12-10  0:11           ` Katsumi Yamaoka

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87is85tzyg.fsf@orebokech.com \
    --to=romain@orebokech.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).