mirror of
https://github.com/correl/doom-modeline.git
synced 2024-11-23 19:19:50 +00:00
Fix #160: Remove unnecessary eldoc-eval package.
This commit is contained in:
parent
2140ded3de
commit
8e30b0b06b
2 changed files with 1 additions and 34 deletions
|
@ -29,7 +29,6 @@
|
||||||
;;; Code:
|
;;; Code:
|
||||||
|
|
||||||
(require 'all-the-icons)
|
(require 'all-the-icons)
|
||||||
(require 'eldoc-eval)
|
|
||||||
(require 'shrink-path)
|
(require 'shrink-path)
|
||||||
(require 'subr-x)
|
(require 'subr-x)
|
||||||
|
|
||||||
|
@ -236,9 +235,6 @@ Given ~/Projects/FOSS/emacs/lisp/comint.el
|
||||||
(defface doom-modeline-bar '((t (:inherit highlight)))
|
(defface doom-modeline-bar '((t (:inherit highlight)))
|
||||||
"The face used for the left-most bar on the mode-line of an active window.")
|
"The face used for the left-most bar on the mode-line of an active window.")
|
||||||
|
|
||||||
(defface doom-modeline-eldoc-bar `((t (:background ,(face-foreground 'default))))
|
|
||||||
"The face used for the left-most bar on the mode-line when eldoc-eval is active.")
|
|
||||||
|
|
||||||
(defface doom-modeline-inactive-bar `((t (:background ,(face-foreground 'mode-line-inactive))))
|
(defface doom-modeline-inactive-bar `((t (:background ,(face-foreground 'mode-line-inactive))))
|
||||||
"The face used for the left-most bar on the mode-line of an inactive window.")
|
"The face used for the left-most bar on the mode-line of an inactive window.")
|
||||||
|
|
||||||
|
@ -373,35 +369,6 @@ Given ~/Projects/FOSS/emacs/lisp/comint.el
|
||||||
;; Plugins
|
;; Plugins
|
||||||
;;
|
;;
|
||||||
|
|
||||||
(defun doom-modeline-eldoc (text)
|
|
||||||
"Get eldoc TEXT for mode-line."
|
|
||||||
(concat (doom-modeline--make-xpm 'doom-modeline-eldoc-bar
|
|
||||||
doom-modeline-bar-width
|
|
||||||
doom-modeline-height)
|
|
||||||
" "
|
|
||||||
text))
|
|
||||||
|
|
||||||
;; Show eldoc in the mode-line with `eval-expression'
|
|
||||||
(defun doom-modeline--show-eldoc (input)
|
|
||||||
"Display string INPUT in the mode-line next to minibuffer."
|
|
||||||
(with-current-buffer (eldoc-current-buffer)
|
|
||||||
(let* ((str (and (stringp input) input))
|
|
||||||
(mode-line-format (or (and str (or (doom-modeline-eldoc str) str))
|
|
||||||
mode-line-format))
|
|
||||||
mode-line-in-non-selected-windows)
|
|
||||||
(force-mode-line-update)
|
|
||||||
(sit-for eldoc-show-in-mode-line-delay))))
|
|
||||||
|
|
||||||
(add-hook 'doom-modeline-mode-hook
|
|
||||||
(lambda ()
|
|
||||||
(if (bound-and-true-p doom-modeline-mode)
|
|
||||||
(progn
|
|
||||||
(eldoc-in-minibuffer-mode 1)
|
|
||||||
(setq eldoc-in-minibuffer-show-fn #'doom-modeline--show-eldoc))
|
|
||||||
(progn
|
|
||||||
(eldoc-in-minibuffer-mode -1)
|
|
||||||
(setq eldoc-in-minibuffer-show-fn #'eldoc-show-in-mode-line)))))
|
|
||||||
|
|
||||||
;; Keep `doom-modeline-current-window' up-to-date
|
;; Keep `doom-modeline-current-window' up-to-date
|
||||||
(defun doom-modeline--get-current-window ()
|
(defun doom-modeline--get-current-window ()
|
||||||
"Get the current window but should exclude the child windows."
|
"Get the current window but should exclude the child windows."
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
;; Author: Vincent Zhang <seagle0128@gmail.com>
|
;; Author: Vincent Zhang <seagle0128@gmail.com>
|
||||||
;; Homepage: https://github.com/seagle0128/doom-modeline
|
;; Homepage: https://github.com/seagle0128/doom-modeline
|
||||||
;; Version: 2.0.0
|
;; Version: 2.0.0
|
||||||
;; Package-Requires: ((emacs "25.1") (all-the-icons "1.0.0") (shrink-path "0.2.0") (eldoc-eval "0.1") (dash "2.11.0"))
|
;; Package-Requires: ((emacs "25.1") (all-the-icons "1.0.0") (shrink-path "0.2.0") (dash "2.11.0"))
|
||||||
;; Keywords: faces mode-line
|
;; Keywords: faces mode-line
|
||||||
|
|
||||||
;; This file is not part of GNU Emacs.
|
;; This file is not part of GNU Emacs.
|
||||||
|
|
Loading…
Reference in a new issue