aboutsummaryrefslogtreecommitdiffhomepage
path: root/notmuch.el
Commit message (Collapse)AuthorAge
* emacs: Move emacs UI (currently just one file) to subdirectory.Gravatar David Bremner2010-03-09
| | | | | | Add emacs/Makefile.local and emacs/Makefile. Move emacs targets into emacs/Makefile.local, but leave the byte compilation rule in the top level Makefile.
* emacs: Fix refresh of search results to leave cursor on current thread.Gravatar Carl Worth2010-03-09
| | | | | | | | | | This has been broken since the addition of support for streaming search results to the emacs interface. With the old apparoach it was easy to simply wait for all search results to land in the buffer and then search for the desired line. With streaming results, we have to save the target off to the side and allow the process filter and sentinel functions to correctly respond when the target thread appears.
* emacs: Fix documentation of notmuch-search-remove-tag.Gravatar Carl Worth2010-03-09
| | | | | | | The behavior was changed in commit 4aff2ca55bfe285ced36e9fe02c907d8b4120672 to affect all messages in the thread (and not only those matching the current search) but the documentation was not updated (until now).
* emacs: Fix backspace to not scroll more than the previous messageGravatar Carl Worth2010-03-09
| | | | | The bug was occuring due to counting invisible lines, but then scrolling past them since they are invisible.
* emacs: Unbreak notmuch-show-rewind (the function to which Backspace is bound)Gravatar Carl Worth2010-03-09
| | | | | | | Commit 095a02211e696434e5b41a85ab516b3a639f9a9b broke the backspace key by trying to execute nil as a function, (which obviously won't work), when it was intended as a return value. Fix this now, (and pine for a test suite that exercises the emacs user-interface of notmuch).
* emacs: Make 'n' and 'p' navigate only open messages.Gravatar Carl Worth2010-02-26
| | | | | And add new 'N' and 'P' keybindings for navigating through messages that are open or closed.
* emacs: Don't open unread messages by default.Gravatar Carl Worth2010-02-26
| | | | | | | | | When searching for an individual message, (by message id, say), it's really annoying to have the entire thread open just because the thread was archived without ever having been read. This means that the "unread" tag is a lot less special, and it really just exists as a mild cue for the user.
* emacs: Avoid removing the unread tag due to internal navigationGravatar Carl Worth2010-02-24
| | | | | | | | | | Sometimes the internals of the implementation navigate among messages, (as opposed to the user explicitly requesting the next message to be shown). In these cases we don't want to remove the unread tag from the message navigated to. This fixes a bug where invocation of notmuch-show-next-unread-message would clear the unread tag from all messages in a thread.
* Simplify "unread" tag handling in emacs UI.Gravatar Jameson Rollins2010-02-24
| | | | | | | | | | | | | | | | | This patch is intended to greatly simplify the handling of the "unread" tag in the emacs UI. This patch adds a new function 'notmuch-show-mark-read', that removes the "unread" tag in notmuch-show-mode. This function is then executed as a notmuch-show-hook, and by notmuch-show-next-message. All of the functions that explicitly marked messages as unread are removed or renamed. The idea here is that the user should never have to worry about manipulating the "unread" tag. The tag should persist until the user actually views a message, at which point it should be automatically removed. This patch simplifies the notmuch.el quite a bit, removing a lot of somewhat redundant functions, and reducing clutter in the name and key-mapping space.
* notmuch.el: Emphasize the 'i' of 'ID' in the documentation for 'c i'.Gravatar Carl Worth2010-02-20
| | | | | We're using 'i' in the keybinding, so it helps to have a capital 'I' in the help string to empahsize the point.
* Change the stash keybinding from 'z' to 'c'. And use 'i' for message ID.Gravatar Carl Worth2010-02-20
| | | | | | | | | | | | In spite of being implemented with the word "stash" in the function names, the documentation (and hence help strings) for each function already use the word "Copy" to describe the action. So 'c' is a much more natural key-binding, (particularly since 'z' didn't map to any real word anyway). We also use 'i' for the message ID copying of the submap. This is intended to align mnemonically with the "id:" prefix already used for message IDs.
* notmuch.el: add a submap (on "z" for "ztash") to stash things.Gravatar David Bremner2010-02-20
| | | | | | | | | | | | | | Provide key bindings for stuffing various RFC822 header fields and other metadata into the emacs kill-ring as text. The bindings are as follows: z F notmuch-show-stash-filename z T notmuch-show-stash-tags z c notmuch-show-stash-cc z d notmuch-show-stash-date z f notmuch-show-stash-from z m notmuch-show-stash-message-id z s notmuch-show-stash-subject z t notmuch-show-stash-to
* notmuch.el: convert sparse keymap to a list in ↵Gravatar David Bremner2010-02-20
| | | | | | | | | notmuch-substitute-one-command-key-with-prefix The previous version would crash when a key was bound to a sparse keymap, since apparently these are not straightforward lists. The usage of map-keymap is a bit obscure: it only has side-effects, no return value.
* Add functions notmuch-show-get-(bcc, cc, date, from, subject, to).Gravatar David Bremner2010-02-20
| | | | | | | Return the corresponding header field for the current message as a string. These are thin wrappers around notmuch-show-get-header, which means they each cause a full parse of the RFC822 header. The main idea is to fix an api.
* notmuch-show-get-header: new function; return alist of parsed header fields.Gravatar David Bremner2010-02-20
| | | | | | | | This function parses the displayed message to recover header fields. It uses mailheader.el to do the actual header parsing, after preprocessing to remove indentation. It relies on the variables notmuch-show-message-begin-regexp, notmuch-show-header-begin-regexp, and notmuch-show-message-end-regexp.
* notmuch.el: Delete some trailing whitespace.Gravatar Carl Worth2010-02-20
| | | | I'm not sure when this managed to creep in, but we don't want it.
* notmuch.el: Fix bug from message with ':' in the From address.Gravatar Carl Worth2010-02-11
| | | | | | | | | | | Eric reported that a particular thread was non-functional in the notmuch-search mode in the emacs client. It was easy enough to trace the bug down to a broken regular expression (using ':' instead of ';'). The bug would be triggered by a message with ':' in the From address. This is something I hope to add to the test suite as soon as we have support for testing the emacs interface there.
* notmuch.el: Handle attached images via an external viewer.Gravatar Carl Worth2010-02-10
| | | | | | | | | We temporarily override the mm-inline-media-tests variable so that the only parts inserted into the temporary buffer (and lost) are those parts that the user has already seen in the notmuch-show buffer. Anything else, (such as images), will now be left to be handled via mailcap, just like other attachment types.
* notmuch.el: Fix indentation.Gravatar Carl Worth2010-02-10
| | | | This line was indented incorrectly which can be confusing.
* notmuch.el: Avoid infinite loop marking up message with no parts.Gravatar Carl Worth2010-02-10
| | | | | | | | | | | | | | | The infinite loop was triggered by a message consisting of a single attachment within the body, (and no "part") tags. We need to do things in response to this bug (beyond this specific fix): 1. Create a test suite that exercises our emacs frontend so that bugs like this do not come back to haunt us after we fix them once. 2. Switch from our ad-hoc regexp based search of message-part delimeters to known-good code for parsing a structured document, (for example, the outstanding JSON patches).
* Reintroduce HTML inlining, with a much needed optimizationGravatar Alexander Botero-Lowry2010-02-09
| | | | | | Now instead of requiring every single message be parsed, we now check the Content-type in the parsed headers and only do HTML inlining if it's text/html
* Allow folders with no messages to be elided from listGravatar Keith Packard2010-02-08
| | | | | | | This makes it easier to see folders with messages. Eliding empty folders is togged with the 'e' binding. Signed-off-by: Keith Packard <keithp@keithp.com>
* Look at whitespace to separate folder name from countGravatar Keith Packard2010-02-08
| | | | | | This allows folder names to contain any non-blank characters Signed-off-by: Keith Packard <keithp@keithp.com>
* Add 'm' and ' ' bindings to notmuch-folder viewGravatar Keith Packard2010-02-08
| | | | | | | This allows the user to compose new mail from the folder view, and also to use <space> to show the current folder. Signed-off-by: Keith Packard <keithp@keithp.com>
* emacs: Use font-lock-comment-face to highlight citation buttonGravatar Kan-Ru Chen2010-02-08
| | | | Signed-off-by: Kan-Ru Chen <kanru@kanru.info>
* notmuch.el: show some of citation even when hiding.Gravatar David Bremner2010-02-08
| | | | | | | | | - rename notmuch-show-citation-lines-min to n-s-c-l-prefix - call forward-line with the appropriate parameter to adjust region to be hidden. - change citation button text so that it makes (some) sense when citation is shown Reviewed-by: Kan-Ru Chen <kanru@kanru.info>
* notmuch.el: Refactor citation markup. Variables for minimum size, button text.Gravatar David Bremner2010-02-08
| | | | | | | | | | | | | | | | | | | | | This is a fairly intrusive rewrite. - I pulled the common code for the signature and citation case out into a separate function. This is not so much shorter, but I think it will be easier to maintain. - I replaced the sequence of (looking-at blah) (forward-line) with a single re-search-forward per citation. New variables - notmuch-show-signature-button-format, notmuch-show-citation-button-format Allow customization of button text. - notmuch-show-citation-lines-min Do not buttonize citations below the given threshold. Reviewed-by: Kan-Ru Chen <kanru@kanru.info>
* notmuch.el: Use emacs built-in forward-button and backward-buttonGravatar Kan-Ru Chen2010-02-05
| | | | | | There are built-ins, so why not use them? Signed-off-by: Kan-Ru Chen <kanru@kanru.info>
* Use forward-line instead of next-lineGravatar Carl Worth2010-02-05
| | | | | | We do this all the time, but at least emacs is kind enough to remind us, (when compiling), that next-line is only intended for interactive use, and we should use forward-line inside of lisp code.
* notmuch.el: Add missing documentation for the new 'h' keybinding.Gravatar Carl Worth2010-02-05
| | | | | Without this, our help screen displayed 'h' with no description of what it does.
* notmuch.el: Add keybinding to toggle display of message body and headers.Gravatar Kan-Ru Chen2010-02-05
| | | | | | | I really missed this feature. Added notmuch-show-toggle-current-body and notmuch-show-toggle-current-header and bind them to 'b' and 'h'. Signed-off-by: Kan-Ru Chen <kanru@kanru.info>
* emacs: Add instructions to the hidden citations/signatures.Gravatar Carl Worth2009-12-11
| | | | | | | | We've received a user report that the hidden citations were annoying since the user couldn't tell what was being referred to by subsequent text. Apparently it wasn't obvious enough that the hidden citation could be revealed by clicking or by pressing Enter. So make the button text say as much.
* emacs: Don't insert extra line after citations.Gravatar Carl Worth2009-12-11
| | | | | This extra line had been annoying me for a while, so I'm glad to see it go away.
* emacs: Don't regard a manually indented '>' as introducing a citation.Gravatar Carl Worth2009-12-11
| | | | | | | | | | In the message mentioned in the previous commit, an ASCII diagram was included in which '>' was used as the first non-whitespace character in a line. Notmuch previously (and mistakenly) regarded this as a citation. We fix this by only regarding a '>' in the first column of an email as introducing a citation.
* emacs: Avoid infinite loop when marking up citations.Gravatar Carl Worth2009-12-11
| | | | | | | | | | | | | | | | Thanks to Dirk Hohndel for reporting the bug. The infinite loop was first noticed in the following message (available from the Linux kernel mailing list): alpine.LFD.2.00.0912081304070.3560@localhost.localdomain Note that the bug does not show up when viewing the message in isolation---the bug was triggered only when viewing this file indented to a depth of at least 13. The fix is simply to use a marker rather than an integer position when recording a point we plan to move back to later, (since inserting the indented button causes the buffer position of the desired marker to change).
* Expand scope of items considered when saving attachmentsGravatar Keith Amidon2009-12-10
| | | | | | | | Previously only mime parts that indicated specified a "disposition" of "attachment" were saved. However there are time when it is important to be able to save inline content as well. After this commit any mime part that specifies a filename will be considered when saving attachments.
* emacs: Fix '+' and '-' in case of thread no longer matching current search.Gravatar Carl Worth2009-12-10
| | | | | | | | | | | | | | | | | | | Similar to the way thread-viewing was broken after a thread was archived, (and recently fixed), tag manipulation has also been broken when the thread no longer matches the current search. This also means that the behavior of '+' and '-' are now different than that of '*'. The '+' and '-' bindings now return to the previous behavior old affecting all messages in the thread, (and not simply those matching the search). I actually prefer this behavior, since otherwise a '-' operation on a thread might not actually remove the tag from the thread, (since it could operate on a subset of the thread and not hit all messages with the given tag). So I'd now like to fix '*' to be consistent with '+' and '-', for which we add an item to TODO.
* notmuch.el: patch notmuch-show to call notmuch show without query-context ↵Gravatar David Bremner2009-12-10
| | | | | | | | (i.e. without tag:inbox) if the first query returns nothing. This fixes the annoying bug of archiving a thread, and then going back to open it and getting an error. It needs the notmuch-show API changing patch of 1259979997-31544-3-git-send-email-david@tethera.net.
* notmuch-show: add optional argument for query context instead of using ↵Gravatar David Bremner2009-12-10
| | | | | | | | | global binding notmuch-search-query-string Also modify the one call to notmuch-show in notmuch.el. This makes the call (notmuch-show thread-id) will work when there is no binding for notmuch-search-query-string; e.g. when called from user code outside notmuch.
* notmuch-search-process-filter: add text properties for authors and subject ↵Gravatar David Bremner2009-12-10
| | | | | | | | to each line Add functions notmuch-search-find-authors and notmuch-find-subject to match notmuch-find-thread-id. These functions are just a wrapper around get-text-property, but in principle that could change.
* Revert "Add some very rudimentary support for handling html parts"Gravatar Carl Worth2009-12-07
| | | | | | | | This reverts commit ed16edc94d6a50ca86ff1575d9ea6fb9168b2e81. The performance hit is just far too severe, (threads with many HTML messages make emacs stop and pause for seconds before displaying the thread even if most of the HTML messages are entirely hidden).
* Make search filters handle disjunctive queries.Gravatar Jed Brown2009-12-04
| | | | | | | | | | | | | notmuch-search-filter now accepts an arbitrary query and will group if necessary so that we get tag:inbox AND (gravy OR biscuits) instead of the former tag:inbox AND gravy OR biscuits Signed-off-by: Jed Brown <jed@59A2.org>
* emacs: Open only matched (and unread) messages when displaying a thread.Gravatar Carl Worth2009-12-03
| | | | | | | | | | This is the long-awaited feature that when viewing a thread resulting from a search, only the messages that actually match the search will be opened initially (in addition to unread messages). So now, it's finally useful to tag a single message in a giant thread, and then do a search later and easily find just the single tagged message.
* emacs: Make message-summary button extend to very beginning of message.Gravatar Carl Worth2009-12-03
| | | | | | | | There's no visible change here---we're just making the button extend through the invisible portions of the message before the message-summary line. The reason this is important is that it's easy for the user to position point at the (invisible) `point-min', so we want to ensure that there's a valid button there.
* Since we know what these buttons do it seems like the underlines areGravatar Alexander Botero-Lowry2009-12-03
| | | | unnecessary.
* emacs: notmuch-fontify-headers: Remove unneeded progn and indent correctly.Gravatar Carl Worth2009-12-03
| | | | | | | The defun special form doesn't require a progn. And the remainder of the function was previously indented in a misleading way, (as if each "if" was always evaluated, rather than each only being evaluated if all the previous evaluated to nil).
* emacs: Make message-summary button begin at beginning of line.Gravatar Carl Worth2009-12-03
| | | | | Otherwise, RET is unreliable for opening/closing messages when navigating through messages with 'n' and 'p'.
* emacs: Highlight message-summary with background-color instead of inverse video.Gravatar Carl Worth2009-12-03
| | | | | Also, do this with a notmuch-message-summary-face variable so that the user can easily customize the desried effect.
* emacs: Make the message-summary highlighting extend to end of visible line.Gravatar Carl Worth2009-12-03
| | | | | This will look much nicer than the highlighting terminating at the end of the summary text.
* emacs: Fix notmuch-show-next-open-message.Gravatar Carl Worth2009-12-03
| | | | | | | This function was still implemented in terms of the old, global toggle for visibility of unread messages, (which no longer exists). Fix it to use the local 'invisibility-spec property on the button controlling message visibility.