[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Help using the right hook for loading theme on emacs daemon GUI

From: Phil Sainty
Subject: Re: Help using the right hook for loading theme on emacs daemon GUI
Date: Fri, 25 Jan 2019 10:16:58 +1300
User-agent: Orcon Webmail

On 2019-01-25 08:44, Eli Zaretskii wrote:
It's not entirely a no-op, since there's early-init-file and
package-initialize, both of which are called before this hook.

Ah, interesting.  So this subtlety is new as of Emacs 27.

I was already thinking that the `after-make-frame-functions' docstring
could use some additional information (it seems to be a common point
of confusion when people start using --daemon); and even more so given
this new wrinkle.

(info "(elisp) Creating Frames") does already say:

Note that any functions added to these hooks by your initial file are
usually not run for the initial frame, since Emacs reads the initial
file only after creating that frame.  However, if the initial frame is
specified to use a separate minibuffer frame (*note Minibuffers and
Frames::), the functions will be run for both, the minibuffer-less and
the minibuffer frame.

(As a tangent, the terminology "initial file" instead of the more
common "init file" is a little jarring.  It crops up in that context
in a couple of other places in the manual, I see, and I'm unsure
whether it's a typo or intended, but I would be inclined to replace
them with "init file" in all cases.)

The info node should be updated to cover the new behaviour in 27, and
I suggest that the docstrings ought to provide a clear pointer to the
info node as being very important reading regarding when the hooks do
and do not run.  I think the docstrings should possibly also replicate
or summarise some of that information; but just ensuring that readers
know there are additional subtleties to understand, and where to read
about them, would be good enough.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]