all authors and subjects in the search buffer [was: Re: [PATCH] emacs: Fix i-search to open up invisible citations as necessary]

2010-05-04 Thread David Edmondson
On Mon, 03 May 2010 13:27:35 -0700, Carl Worth  wrote:
> On Fri, 30 Apr 2010 17:00:08 +0100, David Edmondson  wrote:
> > All of the authors appear in the output already, but that doesn't seem
> > to be the case of the subjects. Would you envisage doing something
> > similar to the changes Dirk made for authors?
> 
> Right. We do have a similar approach already for picking out the "first"
> matching subject. So it would be an easy extension to have it print a
> sorted list of all the subjects.
> 
> But let's start by making the emacs interface allow for searching of the
> authors. Then we can think about whether it makes sense to list all the
> subjects as well.

Patch sent to allow searching of the hidden authors.

Given that the tags are displayed after the subject, I suspect that we
would choose to hide _all_ of the 'non-matching' subject(s), displaying
it only as necessary during isearch.

dme.
-- 
David Edmondson, http://dme.org
-- next part --
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: 



Re: all authors and subjects in the search buffer [was: Re: [PATCH] emacs: Fix i-search to open up invisible citations as necessary]

2010-05-04 Thread David Edmondson
On Mon, 03 May 2010 13:27:35 -0700, Carl Worth cwo...@cworth.org wrote:
 On Fri, 30 Apr 2010 17:00:08 +0100, David Edmondson d...@dme.org wrote:
  All of the authors appear in the output already, but that doesn't seem
  to be the case of the subjects. Would you envisage doing something
  similar to the changes Dirk made for authors?
 
 Right. We do have a similar approach already for picking out the first
 matching subject. So it would be an easy extension to have it print a
 sorted list of all the subjects.
 
 But let's start by making the emacs interface allow for searching of the
 authors. Then we can think about whether it makes sense to list all the
 subjects as well.

Patch sent to allow searching of the hidden authors.

Given that the tags are displayed after the subject, I suspect that we
would choose to hide _all_ of the 'non-matching' subject(s), displaying
it only as necessary during isearch.

dme.
-- 
David Edmondson, http://dme.org


pgpmv6lJETq06.pgp
Description: PGP signature
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


all authors and subjects in the search buffer [was: Re: [PATCH] emacs: Fix i-search to open up invisible citations as necessary]

2010-05-03 Thread Carl Worth
On Fri, 30 Apr 2010 17:00:08 +0100, David Edmondson  wrote:
> All of the authors appear in the output already, but that doesn't seem
> to be the case of the subjects. Would you envisage doing something
> similar to the changes Dirk made for authors?

Right. We do have a similar approach already for picking out the "first"
matching subject. So it would be an easy extension to have it print a
sorted list of all the subjects.

But let's start by making the emacs interface allow for searching of the
authors. Then we can think about whether it makes sense to list all the
subjects as well.

-Carl
-- next part --
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: 



Re: all authors and subjects in the search buffer [was: Re: [PATCH] emacs: Fix i-search to open up invisible citations as necessary]

2010-05-03 Thread Carl Worth
On Fri, 30 Apr 2010 17:00:08 +0100, David Edmondson d...@dme.org wrote:
 All of the authors appear in the output already, but that doesn't seem
 to be the case of the subjects. Would you envisage doing something
 similar to the changes Dirk made for authors?

Right. We do have a similar approach already for picking out the first
matching subject. So it would be an easy extension to have it print a
sorted list of all the subjects.

But let's start by making the emacs interface allow for searching of the
authors. Then we can think about whether it makes sense to list all the
subjects as well.

-Carl


pgpU2XdNN8kgA.pgp
Description: PGP signature
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


all authors and subjects in the search buffer [was: Re: [PATCH] emacs: Fix i-search to open up invisible citations as necessary]

2010-04-30 Thread David Edmondson
On Sat, 24 Apr 2010 07:42:48 -0700, Carl Worth  wrote:
> Next, I wonder if we shouldn't do something similar for the search
> view. It might be quite handy if all authors and all unique subjects for
> a thread were made available for i-search in the buffer, but hidden by
> default and expanded as needed like this. What do you think?

All of the authors appear in the output already, but that doesn't seem
to be the case of the subjects. Would you envisage doing something
similar to the changes Dirk made for authors?

dme.
-- 
David Edmondson, http://dme.org
-- next part --
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: 



[PATCH] emacs: Fix i-search to open up invisible citations as necessary

2010-04-24 Thread Dirk Hohndel
On Sat, 24 Apr 2010 07:42:48 -0700, Carl Worth  wrote:
> On Fri, 23 Apr 2010 18:39:33 +0100, David Edmondson  wrote:
> > Add an `isearch-open-invisible' property to the overlays used to hide
> > citations and signatures, together with an appropriate function to
> > leave the invisible text visible should that be required.
> 
> This is a fantastic feature, David. Thanks! This is pushed.
> 
> I knew emacs could do this kind of thing, and I had even tried to
> implement it once, but I hadn't succeeded for some reason.
> 
> Next, I wonder if we shouldn't do something similar for the search
> view. It might be quite handy if all authors and all unique subjects for
> a thread were made available for i-search in the buffer, but hidden by
> default and expanded as needed like this. What do you think?

I would love this

/D


[PATCH] emacs: Fix i-search to open up invisible citations as necessary

2010-04-24 Thread Carl Worth
On Fri, 23 Apr 2010 18:39:33 +0100, David Edmondson  wrote:
> Add an `isearch-open-invisible' property to the overlays used to hide
> citations and signatures, together with an appropriate function to
> leave the invisible text visible should that be required.

This is a fantastic feature, David. Thanks! This is pushed.

I knew emacs could do this kind of thing, and I had even tried to
implement it once, but I hadn't succeeded for some reason.

Next, I wonder if we shouldn't do something similar for the search
view. It might be quite handy if all authors and all unique subjects for
a thread were made available for i-search in the buffer, but hidden by
default and expanded as needed like this. What do you think?

-Carl
-- next part --
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: 



Re: [PATCH] emacs: Fix i-search to open up invisible citations as necessary

2010-04-24 Thread Carl Worth
On Fri, 23 Apr 2010 18:39:33 +0100, David Edmondson d...@dme.org wrote:
 Add an `isearch-open-invisible' property to the overlays used to hide
 citations and signatures, together with an appropriate function to
 leave the invisible text visible should that be required.

This is a fantastic feature, David. Thanks! This is pushed.

I knew emacs could do this kind of thing, and I had even tried to
implement it once, but I hadn't succeeded for some reason.

Next, I wonder if we shouldn't do something similar for the search
view. It might be quite handy if all authors and all unique subjects for
a thread were made available for i-search in the buffer, but hidden by
default and expanded as needed like this. What do you think?

-Carl


pgp8R9mtCafKN.pgp
Description: PGP signature
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


Re: [PATCH] emacs: Fix i-search to open up invisible citations as necessary

2010-04-24 Thread Dirk Hohndel
On Sat, 24 Apr 2010 07:42:48 -0700, Carl Worth cwo...@cworth.org wrote:
 On Fri, 23 Apr 2010 18:39:33 +0100, David Edmondson d...@dme.org wrote:
  Add an `isearch-open-invisible' property to the overlays used to hide
  citations and signatures, together with an appropriate function to
  leave the invisible text visible should that be required.
 
 This is a fantastic feature, David. Thanks! This is pushed.
 
 I knew emacs could do this kind of thing, and I had even tried to
 implement it once, but I hadn't succeeded for some reason.
 
 Next, I wonder if we shouldn't do something similar for the search
 view. It might be quite handy if all authors and all unique subjects for
 a thread were made available for i-search in the buffer, but hidden by
 default and expanded as needed like this. What do you think?

I would love this

/D
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


[PATCH] emacs: Fix i-search to open up invisible citations as necessary

2010-04-23 Thread David Edmondson
Add an `isearch-open-invisible' property to the overlays used to hide
citations and signatures, together with an appropriate function to
leave the invisible text visible should that be required.
---
 emacs/notmuch-wash.el |4 
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/emacs/notmuch-wash.el b/emacs/notmuch-wash.el
index fe33819..dd5d0a1 100644
--- a/emacs/notmuch-wash.el
+++ b/emacs/notmuch-wash.el
@@ -83,6 +83,9 @@ collapse the remaining lines into a button.")
   'help-echo "mouse-1, RET: Show signature"
   :supertype 'notmuch-wash-button-invisibility-toggle-type)

+(defun notmuch-wash-region-isearch-show (overlay)
+  (remove-from-invisibility-spec (overlay-get overlay 'invisible)))
+
 (defun notmuch-wash-region-to-button (beg end type prefix button-text)
   "Auxilary function to do the actual making of overlays and buttons

@@ -102,6 +105,7 @@ is what to put on the button."
  type "-toggle-type"
 (add-to-invisibility-spec invis-spec)
 (overlay-put overlay 'invisible invis-spec)
+(overlay-put overlay 'isearch-open-invisible 
#'notmuch-wash-region-isearch-show)
 (goto-char (1+ end))
 (save-excursion
   (goto-char (1- beg))
-- 
1.7.0