Fix support for fancy frame title
This commit is contained in:
parent
9b922957ef
commit
8db21403d7
|
@ -606,7 +606,6 @@ If ARG is non nil then Ask questions to the user before installing the dotfile."
|
|||
(dotspacemacs/safe-load)))))
|
||||
|
||||
(defun spacemacs/title-prepare (title-format)
|
||||
>>>>>>> ca96a88b... Add support for fancy frame title
|
||||
"A string is printed verbatim except for %-constructs.
|
||||
%a -- prints the `abbreviated-file-name', or `buffer-name'
|
||||
%t -- prints `projectile-project-name'
|
||||
|
@ -625,8 +624,11 @@ If ARG is non nil then Ask questions to the user before installing the dotfile."
|
|||
%z -- prints mnemonics of buffer, terminal, and keyboard coding systems
|
||||
%Z -- like %z, but including the end-of-line format"
|
||||
(let* ((fs (format-spec-make
|
||||
?a (abbreviate-file-name (or (buffer-file-name) (buffer-name)))
|
||||
?t (if (boundp 'projectile-mode) (projectile-project-name) "-")
|
||||
?a (abbreviate-file-name (or (buffer-file-name)
|
||||
(buffer-name)))
|
||||
?t (if (fboundp 'projectile-project-name)
|
||||
(projectile-project-name)
|
||||
"-")
|
||||
?S system-name
|
||||
?I invocation-name
|
||||
?U (or (getenv "USER") "")
|
||||
|
|
|
@ -106,15 +106,13 @@ the final step of executing code in `emacs-startup-hook'.")
|
|||
(configuration-layer/initialize)
|
||||
;; frame title init
|
||||
(when (and (display-graphic-p) dotspacemacs-frame-title-format)
|
||||
(require 'format-spec)
|
||||
(setq frame-title-format '((:eval (spacemacs/title-prepare dotspacemacs-frame-title-format))))
|
||||
(if dotspacemacs-icon-title-format
|
||||
(setq icon-title-format '((:eval (spacemacs/title-prepare dotspacemacs-icon-title-format))))
|
||||
(setq icon-title-format frame-title-format)))
|
||||
;; theme
|
||||
(spacemacs/load-default-theme spacemacs--fallback-theme)
|
||||
;; frame title init
|
||||
(when (and (display-graphic-p) dotspacemacs-frame-title-format)
|
||||
(setq frame-title-format '((:eval (spacemacs/frame-title-prepare)))))
|
||||
;; font
|
||||
(spacemacs|do-after-display-system-init
|
||||
;; If you are thinking to remove this call to `message', think twice. You'll
|
||||
|
|
Loading…
Reference in New Issue