From ffd0ee8ae1808b378b16f842e2c5e917209daf29 Mon Sep 17 00:00:00 2001 From: Kévin Le Gouguec Date: Sat, 31 Aug 2019 11:59:22 +0200 Subject: Stop delight'ing compilation-in-progress with Emacs≥27 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The code below works with the new indicator, but it's a bit ugly. (let ((props (text-properties-at 0 (car (alist-get 'compilation-in-progress mode-line-modes))))) (setf (car (alist-get 'compilation-in-progress mode-line-modes)) (apply #'propertize "⚙ " `(face compilation-mode-line-run ,@props)))) --- .emacs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.emacs b/.emacs index b851788..7027997 100644 --- a/.emacs +++ b/.emacs @@ -116,7 +116,6 @@ (delight 'auto-fill-function "⏎" t) (delight 'auto-revert-mode "⟳" 'autorevert) (delight 'auto-revert-tail-mode "⤓" 'autorevert) -(delight 'compilation-in-progress "⚙" 'compile) (delight 'eldoc-mode "📖" 'eldoc) (delight 'footnote-mode "¹" 'footnote) (delight 'flyspell-mode (propertize "🖋" 'face 'flyspell-incorrect) 'flyspell) @@ -136,6 +135,10 @@ (delight 'with-editor-mode "⸎" 'with-editor) ;; TODO: Narrow (⌖, ⛶) +(if (version< emacs-version "27") + (delight 'compilation-in-progress "⚙" 'compile) + (message "TODO: tweak compilation lighter")) + (defun my/magit-mode-hook () (when window-system (local-set-key [C-tab] 'other-window) -- cgit v1.2.3