Gnus development mailing list
 help / color / mirror / Atom feed
* Showing dormants when entering mail group?
@ 1998-03-14 22:03 jari.aalto
  1998-03-15  2:51 ` SL Baur
                   ` (4 more replies)
  0 siblings, 5 replies; 14+ messages in thread
From: jari.aalto @ 1998-03-14 22:03 UTC (permalink / raw)




    Thanks for the idea by SLB and others, I started marking "todo"
    articles with dormant tick in my mail groups. What is the
    elegant way to display them by default in mail groups?

    I tried putting (this is an exerpt)

    (if (not (string-match "nntp" group)) ;Show dormants
        (gnus-summary-limit-include-dormant))

    Into gnus-summary-prepare-hook function, but it rolled suicide
    (infinite recursive call). Yow, I thought 
    gnus-summary-prepare-hook runs only after summary was created and
    that any additional formatting commands would be placed in that hook.

    What the next step?
    jari


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Showing dormants when entering mail group?
  1998-03-14 22:03 Showing dormants when entering mail group? jari.aalto
@ 1998-03-15  2:51 ` SL Baur
  1998-03-15 10:26   ` jari.aalto
  1998-03-15 18:41   ` Per Abrahamsen
  1998-03-15 19:39 ` Hallvard B Furuseth
                   ` (3 subsequent siblings)
  4 siblings, 2 replies; 14+ messages in thread
From: SL Baur @ 1998-03-15  2:51 UTC (permalink / raw)


jari aalto <jari.aalto@poboxes.com> writes:

>     Thanks for the idea by SLB and others, I started marking "todo"
>     articles with dormant tick in my mail groups. What is the
>     elegant way to display them by default in mail groups?

O.K.  I did some digging and unfortunately the behavior of suppressing 
childless dormants appears to be hardcoded.  Rats.

Would it help if I got down on my knees and begged like a dog for a
customizable option to suppress this?  Pretty please Lars?

gnus-sum.el:
(defun gnus-summary-limit-children (thread)
  "Return 1 if this subthread is visible and 0 if it is not."
  ;; First we get the number of visible children to this thread.  This
  ;; is done by recursing down the thread using this function, so this
  ;; will really go down to a leaf article first, before slowly
  ;; working its way up towards the root.
  (when thread
    (let ((children
           (if (cdr thread)
               (apply '+ (mapcar 'gnus-summary-limit-children
                                 (cdr thread)))
             0))
          (number (mail-header-number (car thread)))
          score)
      (if (and
           (not (memq number gnus-newsgroup-marked))
           (or
            ;; If this article is dormant and has absolutely no visible
            ;; children, then this article isn't visible.
            (and (memq number gnus-newsgroup-dormant)
                 (zerop children))
 ...


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Showing dormants when entering mail group?
  1998-03-15  2:51 ` SL Baur
@ 1998-03-15 10:26   ` jari.aalto
  1998-03-15 18:41   ` Per Abrahamsen
  1 sibling, 0 replies; 14+ messages in thread
From: jari.aalto @ 1998-03-15 10:26 UTC (permalink / raw)


| 98-03-14 SL Baur <steve@xemacs.org> list.ding
| jari aalto <jari.aalto@poboxes.com> writes:
| 
| >     elegant way to display them by default in mail groups?
| 
| O.K.  I did some digging and unfortunately the behavior of suppressing 
| childless dormants appears to be hardcoded.  Rats.

Yow...so it seems. double rats.

| Would it help if I got down on my knees and begged like a dog for a
| customizable option to suppress this?  Pretty please Lars?
|
|             ;; If this article is dormant and has absolutely no visible
|             ;; children, then this article isn't visible.
|             (and (memq number gnus-newsgroup-dormant)
|                  (zerop children))

Wish for f'coming variable:

- If variable is string: match regexp against group name --> is match,
  enable showing dormants in the group. (this is usefull when separating
  work mail, private mail, Mailing lists and nntp)
- If variable is symbol and not nil: call user function to find out if
  dormats are shown. non-nil return value shows dormants.

That should give enought rope...
jari


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Showing dormants when entering mail group?
  1998-03-15  2:51 ` SL Baur
  1998-03-15 10:26   ` jari.aalto
@ 1998-03-15 18:41   ` Per Abrahamsen
  1998-03-15 20:50     ` jari.aalto
                       ` (2 more replies)
  1 sibling, 3 replies; 14+ messages in thread
From: Per Abrahamsen @ 1998-03-15 18:41 UTC (permalink / raw)


SL Baur <steve@xemacs.org> writes:

> O.K.  I did some digging and unfortunately the behavior of suppressing 
> childless dormants appears to be hardcoded.  Rats.

It happens to be the whole idea behind the dormant mark.  

I think it is better to start working on support for real labels, or
to start using subgroups as labels, instead of changing a feature like
dormant articles into something for which it wasn't designed.


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Showing dormants when entering mail group?
  1998-03-14 22:03 Showing dormants when entering mail group? jari.aalto
  1998-03-15  2:51 ` SL Baur
@ 1998-03-15 19:39 ` Hallvard B Furuseth
  1998-03-15 23:14 ` Justin Sheehy
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 14+ messages in thread
From: Hallvard B Furuseth @ 1998-03-15 19:39 UTC (permalink / raw)


Jari Aalto writes:

>     Thanks for the idea by SLB and others, I started marking "todo"
>     articles with dormant tick in my mail groups.

I use `!*'.  That is, `ticked and cached'.  It works fine, though I
admit it takes a bit more disk space than necessary:-)

-- 
Hallvard


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Showing dormants when entering mail group?
  1998-03-15 18:41   ` Per Abrahamsen
@ 1998-03-15 20:50     ` jari.aalto
  1998-03-15 21:24       ` Hallvard B Furuseth
  1998-03-15 23:09     ` Hrvoje Niksic
  1998-03-16  8:07     ` SL Baur
  2 siblings, 1 reply; 14+ messages in thread
From: jari.aalto @ 1998-03-15 20:50 UTC (permalink / raw)


| 98-03-15 Per Abrahamsen <abraham@dina.kvl.dk> list.ding
| SL Baur <steve@xemacs.org> writes:
| 
| > O.K.  I did some digging and unfortunately the behavior of suppressing 
| > childless dormants appears to be hardcoded.  Rats.
| 
| It happens to be the whole idea behind the dormant mark.  
| 
| I think it is better to start working on support for real labels, or
| to start using subgroups as labels, instead of changing a feature like
| dormant articles into something for which it wasn't designed.

I still think it would be nice if there we gnus-show-dormants that
I could put to my private mail groups Group parameter list to
show dormants immediately..

At work I have lot of time schedules and things to do and I wish
there were also a way to set a "time" (in days?) limit during which
the message must be handled (or answered to).

How do people currently deal with messages that can be classified
as  "answer within 4 days or else...boom"

jari



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Showing dormants when entering mail group?
  1998-03-15 20:50     ` jari.aalto
@ 1998-03-15 21:24       ` Hallvard B Furuseth
  0 siblings, 0 replies; 14+ messages in thread
From: Hallvard B Furuseth @ 1998-03-15 21:24 UTC (permalink / raw)


Jari Aalto writes:

> I still think it would be nice if there we gnus-show-dormants that
> I could put to my private mail groups Group parameter list to
> show dormants immediately..

If you want them to be shown immediatly, why mark them as dormant?

> How do people currently deal with messages that can be classified
> as  "answer within 4 days or else...boom"

I just answered how I do it in Gnus.  Other answers:
Xcalendar. Diary. Xalarm.  Save them to a TODO mail folder.

The idea is to use the right tool for the job instead of desperatly
trying to use a feature which is supposed to be used for almost the
inverse situation.

-- 
Hallvard


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Showing dormants when entering mail group?
  1998-03-15 18:41   ` Per Abrahamsen
  1998-03-15 20:50     ` jari.aalto
@ 1998-03-15 23:09     ` Hrvoje Niksic
  1998-03-16  7:08       ` Yair Friedman
  1998-03-16  8:07     ` SL Baur
  2 siblings, 1 reply; 14+ messages in thread
From: Hrvoje Niksic @ 1998-03-15 23:09 UTC (permalink / raw)


Per Abrahamsen <abraham@dina.kvl.dk> writes:

> I think it is better to start working on support for real labels, or
> to start using subgroups as labels, instead of changing a feature
> like dormant articles into something for which it wasn't designed.

I agree.

-- 
Hrvoje Niksic <hniksic@srce.hr> | Student at FER Zagreb, Croatia
--------------------------------+--------------------------------
By any chance, have you seen a summoned 9th order fire elemental
wandering around?  No?  Oh..  Tell me if you do.


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Showing dormants when entering mail group?
  1998-03-14 22:03 Showing dormants when entering mail group? jari.aalto
  1998-03-15  2:51 ` SL Baur
  1998-03-15 19:39 ` Hallvard B Furuseth
@ 1998-03-15 23:14 ` Justin Sheehy
  1998-03-16  4:13 ` Wes Hardaker
  1998-03-19 12:37 ` Lars Magne Ingebrigtsen
  4 siblings, 0 replies; 14+ messages in thread
From: Justin Sheehy @ 1998-03-15 23:14 UTC (permalink / raw)


<jari.aalto@poboxes.com> writes:

>     Thanks for the idea by SLB and others, I started marking "todo"
>     articles with dormant tick in my mail groups.

Why on earth would one do this?

The dormant mark makes no sense for `todo' items.

Standard ticks (`!') or simple unreadedness would make much more sense.

Another idea would be a separate group with (display . all)
that you move your todo items into.  There are other alternatives as
well, I am sure.

> What is the elegant way to display them by default in mail groups?

There isn't one.  I think that is silly to do so, because then they
are no different from ticks.

If you are in a mail group, and you want something to act like it has
the `!' mark, just use that mark.

-- 
Justin Sheehy

In a cloud bones of steel.
  




^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Showing dormants when entering mail group?
  1998-03-14 22:03 Showing dormants when entering mail group? jari.aalto
                   ` (2 preceding siblings ...)
  1998-03-15 23:14 ` Justin Sheehy
@ 1998-03-16  4:13 ` Wes Hardaker
  1998-03-19 12:37 ` Lars Magne Ingebrigtsen
  4 siblings, 0 replies; 14+ messages in thread
From: Wes Hardaker @ 1998-03-16  4:13 UTC (permalink / raw)
  Cc: Ding mailing list

[-- Attachment #1: Type: text/plain, Size: 1043 bytes --]

>>>>> On 15 Mar 1998 00:03:38 +0200, <jari.aalto@poboxes.com> said:

jari> Thanks for the idea by SLB and others, I started marking "todo"
jari> articles with dormant tick in my mail groups. What is the
jari> elegant way to display them by default in mail groups?

Ok, fyi, this long thread has gotten enough interest that I'd post my
currently used hack to do similar displays of expitory threads.  The
difference is minimal, and enclosed in the hack is a new 'display'
group parameter support for a string to force listing/excluding
articles of a certain type.

The problem is, it doesn't work quite right.  It shows all the
articles, but ends up marking all of them but the last one as 'O' even 
though it should be reading the mark on them not changing it (even
Lars told me so).

The end result, if someone fixes it, it should be able to do what you
want (display dormant marks), with minor tweaks.  I haven't had the
time to look into it further myself.

-- 
"Ninjas aren't dangerous.  They're more afraid of you than you are of them."


[-- Attachment #2: Type: text/plain, Size: 3498 bytes --]

diff -c -r1.1.1.14 gnus-sum.el
*** gnus-sum.el 1998/03/09 17:49:04     1.1.1.14
--- gnus-sum.el 1998/03/09 17:50:02
***************
*** 3897,3914 ****
  
  (defun gnus-articles-to-read (group &optional read-all)
    ;; Find out what articles the user wants to read.
!   (let* ((articles
          ;; Select all articles if `read-all' is non-nil, or if there
          ;; are no unread articles.
!         (if (or read-all
!                 (and (zerop (length gnus-newsgroup-marked))
!                      (zerop (length gnus-newsgroup-unreads)))
!                 (eq (gnus-group-find-parameter group 'display)
!                     'all))
!             (gnus-uncompress-range (gnus-active group))
            (sort (append gnus-newsgroup-dormant gnus-newsgroup-marked
                          (copy-sequence gnus-newsgroup-unreads))
!                 '<)))
         (scored-list (gnus-killed-articles gnus-newsgroup-killed articles))
         (scored (length scored-list))
         (number (length articles))
--- 3905,3956 ----
  
  (defun gnus-articles-to-read (group &optional read-all)
    ;; Find out what articles the user wants to read.
!   (let* ((display (gnus-group-find-parameter group 'display))
!        tmparticles artmark
!        (articles
          ;; Select all articles if `read-all' is non-nil, or if there
          ;; are no unread articles.
!         (cond 
!          ((or read-all
!               (and (zerop (length gnus-newsgroup-marked))
!                    (zerop (length gnus-newsgroup-unreads)))
!               (eq display 'all))
!           (gnus-uncompress-range (gnus-active group)))
!          ((stringp display)
!           (message gnus-newsgroup-headers)
!           (setq tmparticles (gnus-uncompress-range (gnus-active group)))
!           (setq articles nil)
!           (if (string-equal (substring display 0 1) "-")
!               (progn
!                 (setq display (substring display 1))
!                 (while (not (null tmparticles))
!                   (setq artmark 
!                         (char-to-string 
!                          (gnus-article-mark (car tmparticles))))
!                   (if (or (not artmark)
!                           (not (string-match artmark display)))
!                       (setq articles 
!                             (append (list (car tmparticles)) articles)))
!                   (setq tmparticles (cdr tmparticles))))
!             (while (not (null tmparticles))
!               (setq artmark 
!                     (char-to-string (gnus-article-mark (car tmparticles))))
!               (if (and artmark (string-match artmark display))
!                   (setq articles
!                         (append (list (car tmparticles)) articles)))
!               (setq tmparticles (cdr tmparticles))))
!           articles)
!          ((eq display 'not-expired)
!           (setq articles (gnus-uncompress-range (gnus-active group)))
!           (setq tmparticles gnus-newsgroup-expirable)
!           (while (not (null tmparticles))
!             (setq articles (delq (car tmparticles) articles))
!             (setq tmparticles (cdr tmparticles)))
!           articles)
!          (t
            (sort (append gnus-newsgroup-dormant gnus-newsgroup-marked
                          (copy-sequence gnus-newsgroup-unreads))
!                 '<))))
         (scored-list (gnus-killed-articles gnus-newsgroup-killed articles))
         (scored (length scored-list))
         (number (length articles))

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Showing dormants when entering mail group?
  1998-03-15 23:09     ` Hrvoje Niksic
@ 1998-03-16  7:08       ` Yair Friedman
  0 siblings, 0 replies; 14+ messages in thread
From: Yair Friedman @ 1998-03-16  7:08 UTC (permalink / raw)


Hrvoje Niksic <hniksic@srce.hr> writes:

> Per Abrahamsen <abraham@dina.kvl.dk> writes:
> 
> > I think it is better to start working on support for real labels, or
> > to start using subgroups as labels, instead of changing a feature
> > like dormant articles into something for which it wasn't designed.
> 
> I agree.

It's in the TODO list for ages, I tried to start something, but it came
beyond my elisp knowledge. :(

I'd really like to have a user-defined marks but labels will be enough
for my purposes.
--
Yair.


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Showing dormants when entering mail group?
  1998-03-15 18:41   ` Per Abrahamsen
  1998-03-15 20:50     ` jari.aalto
  1998-03-15 23:09     ` Hrvoje Niksic
@ 1998-03-16  8:07     ` SL Baur
  1998-03-16 16:00       ` Per Abrahamsen
  2 siblings, 1 reply; 14+ messages in thread
From: SL Baur @ 1998-03-16  8:07 UTC (permalink / raw)


Per Abrahamsen <abraham@dina.kvl.dk> writes:

> SL Baur <steve@xemacs.org> writes:
>> O.K.  I did some digging and unfortunately the behavior of suppressing 
>> childless dormants appears to be hardcoded.  Rats.

> It happens to be the whole idea behind the dormant mark.  

Why?  I tried using the dormant mark as a means of quickly seeing
which messages of mine had been responded to in a (Mail) group.  What
immediately turned me off about it is that once a message disappears
the entire group has to be rescanned to make these messages reappear.
I believe my objection to this would be resolved if there was a means
of having dormants older than a certain age (from a group parameter)
appear by default.

How are dormants supposed to be used?

> I think it is better to start working on support for real labels, or
> to start using subgroups as labels, instead of changing a feature like
> dormant articles into something for which it wasn't designed.

What are subgroups?

User-defined marks would be nice, or anything I can get access to in
`gnus-summary-highlight'.


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Showing dormants when entering mail group?
  1998-03-16  8:07     ` SL Baur
@ 1998-03-16 16:00       ` Per Abrahamsen
  0 siblings, 0 replies; 14+ messages in thread
From: Per Abrahamsen @ 1998-03-16 16:00 UTC (permalink / raw)


SL Baur <steve@xemacs.org> writes:

> Per Abrahamsen <abraham@dina.kvl.dk> writes:
> 
> > SL Baur <steve@xemacs.org> writes:
> >> O.K.  I did some digging and unfortunately the behavior of suppressing 
> >> childless dormants appears to be hardcoded.  Rats.
> 
> > It happens to be the whole idea behind the dormant mark.  
> 
> Why?  

Why what?

> I tried using the dormant mark as a means of quickly seeing
> which messages of mine had been responded to in a (Mail) group.

And what made you use dormant instead of ticks?

> What
> immediately turned me off about it is that once a message disappears
> the entire group has to be rescanned to make these messages reappear.

/ D

> I believe my objection to this would be resolved if there was a means
> of having dormants older than a certain age (from a group parameter)
> appear by default.

Just use the tick mark.

> How are dormants supposed to be used?

I have a KILL file like this:

(or (string-match "nn\\(draft:\\|ml:\\|tp\\+\\|dir:\\)" gnus-newsgroup-name)
    (gnus-kill "From" "BJÆF\\|Per Abrahamsen"
	       '(gnus-summary-mark-as-dormant 1)))

This way I don't have to see my own boring articles, except when
someone responds.
> 
> > I think it is better to start working on support for real labels, or
> > to start using subgroups as labels, instead of changing a feature like
> > dormant articles into something for which it wasn't designed.
> 
> What are subgroups?

nnml:work.misc
nnml:work.todo
nnml:work.done
nnml:work.reference
nnvirtual:my-mail



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Showing dormants when entering mail group?
  1998-03-14 22:03 Showing dormants when entering mail group? jari.aalto
                   ` (3 preceding siblings ...)
  1998-03-16  4:13 ` Wes Hardaker
@ 1998-03-19 12:37 ` Lars Magne Ingebrigtsen
  4 siblings, 0 replies; 14+ messages in thread
From: Lars Magne Ingebrigtsen @ 1998-03-19 12:37 UTC (permalink / raw)


<jari.aalto@poboxes.com> writes:

> (if (not (string-match "nntp" group)) ;Show dormants
> (gnus-summary-limit-include-dormant))
> 
> Into gnus-summary-prepare-hook function, but it rolled suicide
> (infinite recursive call). Yow, I thought 
> gnus-summary-prepare-hook runs only after summary was created and
> that any additional formatting commands would be placed in that hook.

It does, and they should.  However,
`gnus-summary-limit-include-dormant' is not a command for doing
"additional formatting" -- it's a function that prepares the summary
buffer.  Which explains the infloop.

Bind `gnus-summary-prepare-hook' to nil before calling any functions
that call that hook from that hook.  If you knowwhaddImean.

-- 
(domestic pets only, the antidote for overdose, milk.)
  larsi@gnus.org * Lars Magne Ingebrigtsen


^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~1998-03-19 12:37 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1998-03-14 22:03 Showing dormants when entering mail group? jari.aalto
1998-03-15  2:51 ` SL Baur
1998-03-15 10:26   ` jari.aalto
1998-03-15 18:41   ` Per Abrahamsen
1998-03-15 20:50     ` jari.aalto
1998-03-15 21:24       ` Hallvard B Furuseth
1998-03-15 23:09     ` Hrvoje Niksic
1998-03-16  7:08       ` Yair Friedman
1998-03-16  8:07     ` SL Baur
1998-03-16 16:00       ` Per Abrahamsen
1998-03-15 19:39 ` Hallvard B Furuseth
1998-03-15 23:14 ` Justin Sheehy
1998-03-16  4:13 ` Wes Hardaker
1998-03-19 12:37 ` Lars Magne Ingebrigtsen

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).