delete inside pager

2002-04-13 Thread Flavien

Hi,


I'd like to be able to delete a message while inside the pager, and then
go to the next unread message. What I have set up now is the following :

macro pager d 'exitdelete-messageprevious-entrynext-unreaddisplay-message' 
'delete and go to next unread'

It works pretty good, except when there is no more unread message (the
next-unread does not move the cursor, so it displays the previous entry,
which I just read so hit delete because I think it's a duplicate...).

What I'd like is display-message-only-if-unread, so that it gets me back
to the index when there are no more unread messages.

Any hint ?


Flavien.



Re: delete inside pager

2002-04-13 Thread Rafael C. Gawenda

Quoting Flavien, Sat Apr 13 16:34:17 +0200 2002 (CEST)

 Hi,


 I'd like to be able to delete a message while inside the pager, and then
 go to the next unread message. What I have set up now is the following :

 macro pager d 'exitdelete-messageprevious-entrynext-unreaddisplay-message' 
'delete and go to next unread'

macro pager deletedelete-messagenext-unread

 Any hint ?

I'm using this one, but I don't know if it matches your goal.

-- 
Rafael C. Gawenda, rgawenda/at/pobox/dot/com
2:348/610@fidonet; GnuPG key: 0x5C4839A5; Registered LiNUX User #93375
Guru, n. A computer owner who can read the manual.



msg27126/pgp0.pgp
Description: PGP signature


Re: delete inside pager

2002-04-13 Thread Flavien

Rafael C. Gawenda wrote :
 
 I'm using this one, but I don't know if it matches your goal.

 macro pager delete  delete-messagenext-unread

[The one above does not work. I suppose you thought :
 macro pager 'd' 'delete-messagenext-unread'

This one has a problem.
Test case :
N   Subject: Foo
N   Subject: Bar
N   Subject: Gee

Your press Enter  to  read  Foo,  then  you  press  D.  What  happens  ?
delete-message deletes Foo and points  the  pager  to  Bar.  Then  the
next-unread points to Gee. In fact, Bar is no more new, but you've not
read it ! :-(


Another suggestion ?


Flavien.
-- 
* LG loves czech girls.
vincent LG: do they have additional interesting features other girls
don't have? ;) -- #Debian



Re: delete inside pager

2002-04-13 Thread Holger Lillqvist

On Apr 13, Flavien [EMAIL PROTECTED] wrote:

 [The one above does not work. I suppose you thought :
  macro pager 'd' 'delete-messagenext-unread'
 
 This one has a problem.
 Test case :
 N   Subject: Foo
 N   Subject: Bar
 N   Subject: Gee
 
 Your press Enter  to  read  Foo,  then  you  press  D.  What  happens  ?
 delete-message deletes Foo and points  the  pager  to  Bar.  Then  the
 next-unread points to Gee. In fact, Bar is no more new, but you've not
 read it ! :-(
 Another suggestion ?

You need to set/unset $resolve, which determines if mutt moves to the
next entry or not after an action like delete. Something like:

macro pager d :set noresolveenterdelete-messagenext-unread \
:set resolveenter

Holger