reddit / emacs

Splash image not visible initially

kolerezooi · 2022-05-22 20:22
My splash image and icons of the splash screen are not visible when I start Doom Emacs, and this is what I get every time Emacs is started: ​ https://preview.redd.it/f0axxzbzz2191.jpg?width=798&format=pjpg&auto=webp&s=4b3c803be4fd863d864cbfcaf2c8b2e2ca3c3c50 When I go into the menu and exit out immediately (select "Recently opened files" Esc) then the splash image and icons are loaded: ​ https://preview.redd.it/5mbi9ih203191.jpg?width=626&format=pjpg&auto=webp&s=d03932f27e7eebb71ab601607aa49b7d8fb5db7e I start Doom Emacs by `emacsclient -c -a 'emacs'` and the daemon is already running (`/usr/bin/emacs --daemon`) When I open Emacs in a window(no splash image) and open Emacs separately in a new window (again: `emacsclient -c -a 'emacs')` then the second window also does not show the splash image. When I close the second window then the first window magically shows the splash image. When I open Emacs in a window(no splash image) and then go into the menu and exit out immediately (select "Recently opened files" Esc) then the splash image and icons are loaded as already described. If I then open Emacs separately in a new window ( `emacsclient -c -a 'emacs')` then the second window does show the splash image and icons. The behavior described above is not always the same. Sometimes the splash screen becomes visible when the second window is opened and sometimes not. This is not reproducible. The only reproducible part is that the first screen never shows the splash screen. Hopefully my description makes sense. Is there a trick to get the splash screen working immediately? First lines of init.el: (setq fancy-splash-image "~/.doom.d/doom-emacs.png") (set-frame-font "Hack 12" t t) (setq default-frame-alist '((font . "Hack 13"))) ;; Set relative numbering. 'SPC' 't' 'l' (global-display-line-numbers-mode) (setq display-line-numbers-type 'relative) ... My config can be found here: [https://github.com/Prutserdt/dotfiles/tree/master/.doom.d](https://github.com/Prutserdt/dotfiles/tree/master/.doom.d) My system is Arch linux, qtile, alacritty terminal
BettaGeorge · 2022-05-22 20:58
Do you *need* the splash screen? It's like the first thing I disable in any program.
Kefim_Wod · 2022-05-23 00:52
There have been longstanding issues with fonts, themes, and the dashboard loading correctly when using emacsclient and doom. I haven't been using emacs --daemon so I didn't notice until your post that I shared the same issue. Here is a solution that I tested that seems to be working. Add this to your config.el: (defun load-[your-theme-here]-theme (frame) (select-frame frame) (load-theme '[your-theme-here] t)) (if (daemonp) (add-hook 'after-make-frame-functions #'load-[your-theme-here]-theme) (load-theme '[your-theme-here] t)) Source: https://github.com/doomemacs/doomemacs/issues/6221#issuecomment-1098560921
deaddyfreddy · 2022-05-23 14:26
> `emacsclient -c -a 'emacs'` it doesn't start the daemon, use an empty string instead
kolerezooi · 2022-05-23 15:23
Yeah, you're right, no, not at all. I'm a new emacs user and I will change it one day for sure
kolerezooi · 2022-05-23 15:55
Thanks! I did not get it to work yet, probably because of my unfamiliarity with Lisp. I will try it later when i have more time.