Commit Graph

119 Commits

Author SHA1 Message Date
Dirk-Jan C. Binnema 4182e599de mu4e-view: update baseline display
Make it a bit less prominent; and add a command mu4e-baseline-time.
2023-01-14 09:04:43 +02:00
Dirk-Jan C. Binnema 10041eb2e1 mu4e: implement mu4e-query-items
Implement function / datas structure to conveniently aggregate all
query-related data, for reuse in various places in mu4e...

... to start with the main menu, which gets much simpler. And the
modeline.
2023-01-13 21:56:15 +02:00
Dirk-Jan C. Binnema f5f03e8f91 mu4e-main: add menu to menubar 2023-01-09 22:45:53 +02:00
Dirk-Jan C. Binnema b11293147f mu4e: move mu4e~headers-jump-to-maildir to search
... to mu4e-search-maildir.

Where we can, we move appropriate code from the overpopulated
mu4e-headers.el to mu4e-search, and update users.
2023-01-09 22:43:39 +02:00
Dirk-Jan C. Binnema 5e5a74ed22 mu4e: use caching for modeline items
Avoid excessive (unnecessary) recalculation.
2023-01-08 13:54:47 +02:00
Dirk-Jan C. Binnema 49e094531c mu4e: add support for :favorite bookmark
Show favorite bookmark in main-screen (highlighted)

Add baseline-reset when main screen is shown or when the favority
bookmark is searched.

Some code cleanup
2023-01-07 15:40:30 +02:00
Dirk-Jan C. Binnema ba5026e7dc mu4e: support showing 'baseline' query-results
Add the concept of a query results baseline, i.e., the result for
bookmark-queries at some particular point in time. Later, we can compare
the results with the then-current query-results.

Show the delta in the main view. Add mu4e-reset-baseline-query-results
to reset the baseline to 'now'. By default, we automatically reset when
explicitly (interactively) going to the main-view, i.e., M-x mu4e.
2023-01-01 15:01:08 +02:00
Dirk-Jan C. Binnema e435692bb2 mu4e-main: refactor bookmark/maildir menu creation
There was quite a bit of duplicate code, refactor it to reduce.
2022-12-30 23:30:45 +02:00
Dirk-Jan C. Binnema 3e3aeead9b Revert "Add support for empty and string maildir shortcuts"
This reverts commit be695579c6.

The change didn't look very nice (keynames are not aligned etc.), and in
hindsight we should probably implement this slightly differently.
2022-12-30 16:19:19 +02:00
Dirk-Jan C. Binnema 9e1f0931f4 mu4e-main: fix byte-compiler warning 2022-12-29 08:43:42 +02:00
Dirk-Jan C. Binnema eb8160e8ed mu4e-main: restore mail-menu support for split-window mode 2022-12-29 00:23:32 +02:00
Dirk-Jan C. Binnema 15fadee730 mu4e-main: whitespace 2022-12-29 00:22:48 +02:00
Dirk-Jan C. Binnema 56099998e4
Merge pull request #2292 from manufactory/master
More customizable maildir shortcuts
2022-12-28 10:55:57 +02:00
Mickey Petersen 8ea01241ca Change how *mu4e-main* is displayed and default to full frame 2022-12-17 15:13:17 +00:00
Dirk-Jan C. Binnema 7d9a9d8a7c mu4e-main: make main-window full-screen again
Make the main-window fullscreen again, as before.
2022-12-13 09:36:42 +02:00
Dirk-Jan C. Binnema de8b4f0e32 mu4e-main: whitespace updates 2022-12-13 09:36:16 +02:00
Mickey Petersen 04903c568d Move defcustoms to mu4e-window.el 2022-12-09 09:01:18 +00:00
Mickey Petersen 69a17bfcb9 Multiple buffer support and standardised window and buffer handling 2022-11-29 11:33:07 +00:00
Sean Farley 89acde3f9c mu4e-main: automatically update the mail counts after indexing
It always struck me as a bit odd to force the user to refresh the main
view after updating and indexing their mail. This change creates a hook
that will simply call `revert-buffer' after an indexing completes.
2022-09-04 16:54:24 -05:00
Dirk-Jan C. Binnema 68753f9e84 mu4e: move all obsolete aliases to mu4e-obsolete
Unclutter the rest of the code a bit.
2022-08-20 14:24:24 +03:00
Dirk-Jan C. Binnema 39d7096bba mu4e-main: rewrite mu4e--main-menu
The old one had bit-rotted quite a bit.

Fixes #2296.
2022-07-07 00:52:32 +03:00
Manuel Wiesinger be695579c6 Add support for empty and string maildir shortcuts 2022-07-04 12:54:13 +02:00
Dirk-Jan C. Binnema a1f0c5e9eb mu4e: fix emacs-29 bytecompiler warnings
Wrong single quotes.
2022-05-28 00:51:08 +03:00
Daniel Fleischer eebb0eddd6 Last updated timestamp in the main screen
* mu4e/mu4e-main.el: showing last updated

based on the `:tstamp` of `mu4e-index-update-status` plist.
2022-04-18 19:06:54 +03:00
Dirk-Jan C. Binnema cc3be78dc5 mu4e-main: use mu4e~headers-jump-to-maildir
Re-fix hasty earlier fix; and improve the code a bit.

HT: @tsdh.
2022-01-29 19:53:37 +02:00
Dirk-Jan C. Binnema b8e696000f mu4e-main: fix jump-to-maildir typo
Fixes: #2206
2022-01-29 15:55:51 +02:00
Dirk-Jan C. Binnema a4707afe12 mu4e: cleanups and flycheck fixes
- Remove some unused faces
- Fix some flycheck warnings
- Replace some `cl-` functions with `pcase` and `seq`
2022-01-23 14:27:00 +02:00
Dirk-Jan C. Binnema 5d155841a6 mu4e: Use mu4e-query-rewrite-function
The (new) mu4e-search-query-rewrite-function is a bit too long, let's keep the
old one.
2021-10-31 11:26:58 +02:00
Dirk-Jan C. Binnema 5db8fdc49d mu4e: Do not defvar abbrev tables
I'm not quite sure why it was done in the first place, and it seems to have
unwanted side-effects. So let's turn it off and see if anything breaks.

Fixes: #2146.
2021-10-06 08:11:30 +03:00
Dirk-Jan C. Binnema 9157d9102d mu4e-utils: refactor into mu4e-helpers, separate files
Usurp more of the utils code than can be re-used without further dependencies in
helpers.

Split off specific parts in their own file.

After the helper/utils changes, update the rest of mu4e to take the changes into
account.
2021-08-29 21:40:42 +03:00
Dirk-Jan C. Binnema 3cd127d8ae mu4e-search: split off search functionality in minor-mode
Split off the search functionality from mu4e-headers.el into a new
mu4e-search.el.

Clean up things a bit and create a minor mode in which to add the keybindings.

Enable this in main/headers/view.
2021-08-29 20:30:29 +03:00
Dirk-Jan C. Binnema 035977a89a mu4e-context: make it a minor-mode
Add mu4e-context-minor-mode, for re-use in other parts of mu4e.

Update those parts + documentation.
2021-08-29 20:30:29 +03:00
Dirk-Jan C. Binnema f69214b4df mu4e-main: refresh after context-switch
Fixes: #2062.
2021-07-29 23:24:13 +03:00
Salman Mohammadi 539a946aa4
mu4e/*: fix license notice at the start of source files
At the start of mu4e/* files, the license has been wrongly attributed
to GNU Emacs instead of mu4e.

Fixes https://github.com/djcb/mu/issues/2019
2021-05-29 23:45:10 +02:00
Dirk-Jan C. Binnema b09b3cb2bb mu4e-main: fix hide-personal-addresses typo
Fixes #1879.
2021-01-03 14:58:28 +02:00
Tassilo Horn fe6cbf5949 Use mu4e-query-rewrite-function also for computing bookmark counts
Until now, the bookmark queries were sent to mu in their original form.  Thus,
if you have `mu4e-query-rewrite-function` set, the numbers shown next to the
bookmarks didn't reflect the actual number of query results you'd get when
opening a bookmark view.

With this commit, the `mu4e-query-rewrite-function` is applied and the result
is sent to mu for evaluation (in `mu4e~start`) and the likewise the rewritten
queries are used to find the matching one in the last query results (in
`mu4e~main-bookmarks`).

* mu4e/mu4e-utils.el (mu4e~start): Send the rewritten queries for evaluation to
mu.
* mu4e/mu4e-main.el (mu4e~main-bookmarks): Compare last mu query results with
rewritten queries.
2020-12-13 17:06:11 +01:00
Dirk-Jan C. Binnema 273eb822d5 mu4e: add mu4e-last-query-result[s]
This makes the most recent results from the queries (i.e. the numbers)
available using the supported 'mu4e-' API.

Fixes: #1845.
2020-12-06 14:48:46 +02:00
Dirk-Jan C. Binnema 5e069d9a6f mu4e: support regexp patterns for personal addresses 2020-10-17 15:38:24 +03:00
Dirk-Jan C. Binnema 73be015cd0 fixup: mu4e: some cleanups / bytecomp warning fixes 2020-05-28 10:21:16 +03:00
Dirk-Jan C. Binnema 454e8d9a3a mu4e: allow for hiding fully read maildirs/bookmarks
Add a variable mu4e-main-hide-fully-read to control whether to _not_ show
maildir / bookmark links if they're fully read.
2020-05-27 18:56:23 +03:00
Sean Farley 3ea1784aad mu4e-main: use `string-width' over `length'
Better for utf-8 but still difficult to align due to non-monospaced
characters.
2020-05-26 23:12:26 +03:00
Sean Farley d68c0fd5b5 mu4e-main: decode strings as utf-8
This fixes both bookmarks and maildirs with non-ASCII names. Thanks to
@scturtle for pointing this out!
2020-05-26 23:12:26 +03:00
Sean Farley 9f1e231824 mu4e-main: fix off-by-one error in `mu4e~main-action-str'
For bookmarks, which specify the key combo instead of using the first
character of the string had an off-by-one error in the mouse
highlighting since it wasn't consuming that first letter.
2020-05-26 23:12:26 +03:00
Sean Farley 5110b02349 mu4e-main: use longest bookmark/mailder count in bookmarks section 2020-05-26 23:12:26 +03:00
Sean Farley a070cca79d mu4e-main: add new method for constructing the maildir list
This method is exactly like `mu4e~main-bookmarks' but for maildirs
instead of bookmarks.
2020-05-26 23:12:26 +03:00
Jonas Bernoulli 564d892701 Fix typos 2020-05-12 23:56:55 +02:00
Manuel Argüelles 36701c9336 mu4e: change spacing in main view for info section
Change the spaces to tab to be consistent with the other entries in the
main view.
2020-05-08 11:24:31 -05:00
Dirk-Jan C. Binnema 1919146b94 mu4e: centralize mode-line context setting code
Add mu4e-context-in-modeline to handle all setting of context in the
mode-line, to address some corner-cases with the current setup.
2020-05-01 22:44:45 +03:00
Dennis Ogbe a153e08edb fix `mu4e-main-buffer-hide-personal-addresses' 2020-04-22 16:55:27 -04:00
Dirk-Jan C. Binnema 26fb011026 mu4e: main: don't use string-join, it's too new
Fixes #1636
2020-04-08 11:26:12 +03:00