mu4e: update transient support
We can now rely on transient being available.
This commit is contained in:
@ -1,4 +1,4 @@
|
|||||||
## Copyright (C) 2022-2025 Dirk-Jan C. Binnema <djcb@djcbsoftware.nl>
|
## Copyright (C) 2022-2026 Dirk-Jan C. Binnema <djcb@djcbsoftware.nl>
|
||||||
##
|
##
|
||||||
## This program is free software; you can redistribute it and/or modify
|
## This program is free software; you can redistribute it and/or modify
|
||||||
## it under the terms of the GNU General Public License as published by
|
## it under the terms of the GNU General Public License as published by
|
||||||
@ -94,8 +94,7 @@ endif
|
|||||||
#
|
#
|
||||||
#... so let's not do that!
|
#... so let's not do that!
|
||||||
|
|
||||||
# byte compile the sources that can be byte-compiled. This may exclude mu4e-transient.el and
|
# byte compile the sources that can be byte-compiled. This may exclude mu4e-dbus.el
|
||||||
# mu4e-dbus.el
|
|
||||||
foreach src : mu4e_bc_srcs
|
foreach src : mu4e_bc_srcs
|
||||||
target_name= '@BASENAME@.elc'
|
target_name= '@BASENAME@.elc'
|
||||||
target_path = join_paths(meson.current_build_dir(), target_name)
|
target_path = join_paths(meson.current_build_dir(), target_name)
|
||||||
|
|||||||
@ -1,13 +1,32 @@
|
|||||||
;;; mu4e-transient.el --- -*- coding: utf-8; lexical-binding: t -*-
|
;;; mu4e.el --- Mu-based mua for emacs -*- lexical-binding: t -*-
|
||||||
;;
|
|
||||||
;; Copyright (C) 2025 Dirk-Jan C. Binnema <djcb@djcbsoftware.nl>
|
;; Copyright (C) 2025-2026 Dirk-Jan C. Binnema
|
||||||
|
|
||||||
|
;; Author: Dirk-Jan C. Binnema <djcb@djcbsoftware.nl>
|
||||||
|
;; Maintainer: Dirk-Jan C. Binnema <djcb@djcbsoftware.nl>
|
||||||
|
|
||||||
|
;; This file is not part of GNU Emacs.
|
||||||
|
|
||||||
|
;; SPDX-License-Identifier: GPL-3.0-or-later
|
||||||
|
|
||||||
|
;; mu4e is free software: you can redistribute it and/or modify
|
||||||
|
;; it under the terms of the GNU General Public License as published by
|
||||||
|
;; the Free Software Foundation, either version 3 of the License, or
|
||||||
|
;; (at your option) any later version.
|
||||||
|
|
||||||
|
;; mu4e is distributed in the hope that it will be useful,
|
||||||
|
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
;; GNU General Public License for more details.
|
||||||
|
|
||||||
|
;; You should have received a copy of the GNU General Public License
|
||||||
|
;; along with mu4e. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
;;; Commentary:
|
;;; Commentary:
|
||||||
;;;
|
;;;
|
||||||
;;; Define "transients" for some mu4e functionality.
|
;;; Define a "transient" menu for some mu4e functionality.
|
||||||
|
|
||||||
;;; Code:
|
;;; Code:
|
||||||
(require 'mu4e)
|
|
||||||
(require 'mu4e-bookmarks)
|
(require 'mu4e-bookmarks)
|
||||||
(require 'mu4e-compose)
|
(require 'mu4e-compose)
|
||||||
(require 'mu4e-draft)
|
(require 'mu4e-draft)
|
||||||
@ -20,6 +39,9 @@
|
|||||||
|
|
||||||
;; Helpers.
|
;; Helpers.
|
||||||
|
|
||||||
|
|
||||||
|
(declare-function mu4e "mu4e")
|
||||||
|
|
||||||
(defun mu4e--toggle-description(name val)
|
(defun mu4e--toggle-description(name val)
|
||||||
"Return a string for a transient toggle with NAME.
|
"Return a string for a transient toggle with NAME.
|
||||||
Show On/Off based on value VAL."
|
Show On/Off based on value VAL."
|
||||||
@ -137,6 +159,9 @@ toggle-function is created."
|
|||||||
;;("a" "archive")
|
;;("a" "archive")
|
||||||
]])
|
]])
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
;;;###autoload(autoload 'mu4e-transient-menu "mu4e-transient" nil t)
|
||||||
(transient-define-prefix mu4e-transient-menu()
|
(transient-define-prefix mu4e-transient-menu()
|
||||||
"Mu4e main menu."
|
"Mu4e main menu."
|
||||||
[["Main"
|
[["Main"
|
||||||
|
|||||||
@ -45,6 +45,7 @@
|
|||||||
(require 'mu4e-notification)
|
(require 'mu4e-notification)
|
||||||
(require 'mu4e-server) ;; communication with backend
|
(require 'mu4e-server) ;; communication with backend
|
||||||
|
|
||||||
|
(require 'mu4e-transient)
|
||||||
(when mu4e-speedbar-support
|
(when mu4e-speedbar-support
|
||||||
(require 'mu4e-speedbar)) ;; support for speedbar
|
(require 'mu4e-speedbar)) ;; support for speedbar
|
||||||
(when mu4e-org-support
|
(when mu4e-org-support
|
||||||
|
|||||||
@ -3624,13 +3624,8 @@ the counts to latest known ones. When in the main-view, you can use
|
|||||||
@section Transient
|
@section Transient
|
||||||
@cindex transient
|
@cindex transient
|
||||||
|
|
||||||
@code{mu4e} has experimental support for the ``transient'' menus, as per
|
@code{mu4e} has support for the ``transient'' menus, as per @ref{(transient)
|
||||||
@ref{(transient) Top}. Because ``transient'' is not automatically available in
|
Top}, through @kbd{M-x mu4e-transient-menu}, or bind it to some key.
|
||||||
all Emacs version that @code{mu4e} support, you need to manually enable it:
|
|
||||||
@lisp
|
|
||||||
(when (require 'mu4e-transient nil 'noerror)
|
|
||||||
(global-set-key (kbd "C-c m") mu #'mu4e-transient-menu))
|
|
||||||
@end lisp
|
|
||||||
|
|
||||||
@node Desktop notifications
|
@node Desktop notifications
|
||||||
@section Desktop notifications
|
@section Desktop notifications
|
||||||
|
|||||||
Reference in New Issue
Block a user