fix(unicode): unicode-fonts remapping for daemon
The unicode remappings were done too early, prior to this change, making them ineffective for later daemon frames. Fix: #5486 Fix: #7160
This commit is contained in:
parent
1d7dd915ab
commit
09f602b342
1 changed files with 3 additions and 5 deletions
|
@ -1,21 +1,19 @@
|
||||||
;;; ui/unicode/autoload.el -*- lexical-binding: t; -*-
|
;;; ui/unicode/autoload.el -*- lexical-binding: t; -*-
|
||||||
|
|
||||||
;;;###autoload
|
;;;###autoload
|
||||||
(add-hook! 'doom-init-ui-hook
|
(add-hook! 'after-setting-font-hook :depth -90
|
||||||
(defun +unicode-init-fonts-h ()
|
(defun +unicode-init-fonts-h ()
|
||||||
"Set up `unicode-fonts' to eventually run; accommodating the daemon, if
|
"Set up `unicode-fonts' to eventually run; accommodating the daemon, if
|
||||||
necessary."
|
necessary."
|
||||||
(setq-default bidi-display-reordering t)
|
(setq-default bidi-display-reordering t)
|
||||||
(if (display-graphic-p)
|
(+unicode-setup-fonts-h (selected-frame))))
|
||||||
(+unicode-setup-fonts-h (selected-frame))
|
|
||||||
(add-hook 'after-make-frame-functions #'+unicode-setup-fonts-h))))
|
|
||||||
|
|
||||||
;;;###autoload
|
;;;###autoload
|
||||||
(defun +unicode-setup-fonts-h (&optional frame)
|
(defun +unicode-setup-fonts-h (&optional frame)
|
||||||
"Initialize `unicode-fonts', if in a GUI session.
|
"Initialize `unicode-fonts', if in a GUI session.
|
||||||
|
|
||||||
If doom-unicode-font is set, add it as preferred font for all unicode blocks."
|
If doom-unicode-font is set, add it as preferred font for all unicode blocks."
|
||||||
(when (and frame (display-graphic-p frame))
|
(when (and frame (display-multi-font-p frame))
|
||||||
(with-selected-frame frame
|
(with-selected-frame frame
|
||||||
(require 'unicode-fonts)
|
(require 'unicode-fonts)
|
||||||
(when doom-unicode-font
|
(when doom-unicode-font
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue