[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/nano-modeline 2e23885 3/3: Fixed ispell spacing (close
From: |
ELPA Syncer |
Subject: |
[elpa] externals/nano-modeline 2e23885 3/3: Fixed ispell spacing (close #38) |
Date: |
Mon, 22 Nov 2021 13:57:40 -0500 (EST) |
branch: externals/nano-modeline
commit 2e2388518698551c3905c7c480ae6202260db953
Author: Nicolas P. Rougier <Nicolas.Rougier@inria.fr>
Commit: Nicolas P. Rougier <Nicolas.Rougier@inria.fr>
Fixed ispell spacing (close #38)
---
nano-modeline.el | 17 ++++++++++++++++-
1 file changed, 16 insertions(+), 1 deletion(-)
diff --git a/nano-modeline.el b/nano-modeline.el
index 967d566..47c3d87 100644
--- a/nano-modeline.el
+++ b/nano-modeline.el
@@ -359,6 +359,16 @@ Modeline is composed as:
")")
""))
+
+;; ---------------------------------------------------------------------
+(defun nano-modeline-enlarge-ispell-choices-buffer (buffer)
+ (when (string= (buffer-name buffer) "*Choices*")
+ (with-current-buffer buffer
+ ;; (enlarge-window +2)
+ (setq-local header-line-format nil)
+ (setq-local mode-line-format nil))))
+
+
;; ---------------------------------------------------------------------
(defun nano-modeline-org-agenda-mode-p ()
(derived-mode-p 'org-agenda-mode))
@@ -729,6 +739,10 @@ depending on the version of mu4e."
(add-hook 'calendar-initial-window-hook
#'nano-modeline-calendar-setup-header))
+ (with-eval-after-load 'ispell
+ (advice-add #'ispell-display-buffer :after
+ #'nano-modeline-enlarge-ispell-choices-buffer))
+
(with-eval-after-load 'org-clock
(add-hook 'org-clock-out-hook #'nano-modeline-org-clock-out))
@@ -786,7 +800,8 @@ depending on the version of mu4e."
#'nano-modeline-org-clock-out)
(remove-hook 'post-command-hook
#'nano-modeline--update-selected-window)
- (advice-remove 'mu4e~header-line-format #'nano-modeline)
+ (advice-remove #'mu4e~header-line-format #'nano-modeline)
+ (advice-remove #'ispell-display-buffer
#'nano-modeline-enlarge-ispell-choices-buffer)
(setq mode-line-format nano-modeline--saved-mode-line-format)
(setq-default mode-line-format nano-modeline--saved-mode-line-format)