[Emacs] Fix commit f5a9608
f5a9608
introduces a bug which prevents the font from being applied if
Emacs is started as a server through systemd, since it does not start
in GUI mode. This commit fixes this behavior by applying the
user-defined font when a new frame is created since the new frame
might be in GUI mode.
This commit is contained in:
parent
413ecb2d2b
commit
91b06ee7b1
@ -386,10 +386,12 @@ don’t. I prefer [[https://github.com/microsoft/cascadia-code][Cascadia Code]],
|
||||
(defvar phundrak/default-font-name "Cascadia Code"
|
||||
"Default font.")
|
||||
|
||||
(when (find-font (font-spec :name phundrak/default-font-name))
|
||||
(set-face-attribute 'default nil
|
||||
:font phundrak/default-font-name
|
||||
:height phundrak/default-font-size))
|
||||
(add-hook 'server-after-make-frame-hook
|
||||
(lambda ()
|
||||
(when (find-font (font-spec :name phundrak/default-font-name))
|
||||
(set-face-attribute 'default nil
|
||||
:font phundrak/default-font-name
|
||||
:height phundrak/default-font-size))))
|
||||
#+end_src
|
||||
|
||||
*** Frame Title
|
||||
|
Loading…
Reference in New Issue
Block a user