mirror of
https://github.com/correl/doom-modeline.git
synced 2024-11-23 19:19:50 +00:00
Improve: calculate font height.
This commit is contained in:
parent
02e50cfb60
commit
ce7c1006eb
1 changed files with 3 additions and 3 deletions
|
@ -506,9 +506,9 @@ If the actual char height is larger, it respects the actual char height.")
|
||||||
(defun doom-modeline--font-height ()
|
(defun doom-modeline--font-height ()
|
||||||
"Calculate the actual char height of the mode-line."
|
"Calculate the actual char height of the mode-line."
|
||||||
(let ((height (face-attribute 'mode-line :height)))
|
(let ((height (face-attribute 'mode-line :height)))
|
||||||
(round (* 1.68 (if (number-or-marker-p height)
|
(round (* 1.68 (cond ((integerp height) (/ height 10))
|
||||||
(/ height 10)
|
((floatp height) (* height (frame-char-height)))
|
||||||
(frame-char-height))))))
|
(t (frame-char-height)))))))
|
||||||
|
|
||||||
(defun doom-modeline-icon-octicon (&rest args)
|
(defun doom-modeline-icon-octicon (&rest args)
|
||||||
"Display octicon via ARGS."
|
"Display octicon via ARGS."
|
||||||
|
|
Loading…
Reference in a new issue