From efa7686817c301b5c5bf3d1c4684c0000a106fbb Mon Sep 17 00:00:00 2001 From: jao Date: Sun, 31 Mar 2024 05:30:31 +0100 Subject: more room in notmuch-hello --- custom/jao-custom-notmuch.el | 31 ++++++++++++++++++------------- 1 file changed, 18 insertions(+), 13 deletions(-) diff --git a/custom/jao-custom-notmuch.el b/custom/jao-custom-notmuch.el index 2a48e3b..524a767 100644 --- a/custom/jao-custom-notmuch.el +++ b/custom/jao-custom-notmuch.el @@ -258,9 +258,9 @@ (use-package jao-notmuch :demand t) ;;; hello -;; (defun jao-notmuch-hello--header () (insert " ")) -;; (when (display-graphic-p) -;; (add-to-list 'notmuch-hello-sections 'jao-notmuch-hello--header)) +(defun jao-notmuch-hello--header () (insert " ")) +(when (display-graphic-p) + (add-to-list 'notmuch-hello-sections 'jao-notmuch-hello--header)) (add-to-list 'notmuch-hello-sections 'notmuch-hello-insert-alltags t) @@ -318,6 +318,11 @@ notmuch-show-logo nil notmuch-show-empty-saved-searches nil) + (add-to-list 'display-buffer-alist + '("\\*notmuch-hello\\*" + (display-buffer-reuse-window) + (body-function . (lambda (w) (set-window-margins w 1))))) + :hook ((notmuch-hello-refresh . jao-notmuch-notify)) :config @@ -325,16 +330,16 @@ (add-hook 'jao-afio-switch-hook #'jao-notmuch-refresh-hello)) :bind (:map notmuch-hello-mode-map - (("a" . jao-notmuch-refresh-agenda) - ("g" . jao-notmuch-refresh-hello) - ("j" . jao-notmuch-jump-search) - ("n" . jao-notmuch-hello-next) - ("p" . widget-backward) - ("SPC" . widget-button-press) - ("/" . consult-notmuch) - ("." . jao-notmuch-hello-first) - ("[" . jao-notmuch-hello-prev-section) - ("]" . jao-notmuch-hello-next-section)))) + (("a" . jao-notmuch-refresh-agenda) + ("g" . jao-notmuch-refresh-hello) + ("j" . jao-notmuch-jump-search) + ("n" . jao-notmuch-hello-next) + ("p" . widget-backward) + ("SPC" . widget-button-press) + ("/" . consult-notmuch) + ("." . jao-notmuch-hello-first) + ("[" . jao-notmuch-hello-prev-section) + ("]" . jao-notmuch-hello-next-section)))) ;;; show (defun jao-notmuch-open-enclosure (add) -- cgit v1.2.3