ansi-color-compilation-filter wasn't introduced until Emacs 28, so this
removal was too hasty, but should be reconsidered when we drop 27.x
support.
Fix: #6515
Revert: 2f7171bf8a
Restructures Doom's primary core files and entry points to prepare for
backports (from the new CLI) coming soon.
- Removes $EMACSDIR/init.el.
- Doom configures Emacs to ignore ~/.emacs and ~/_emacs files.
- Doom's bootstrapper for interactive sessions was moved out of core.el
and doom-initialize into doom-start.el. This change is preparation for
Doom's new profile system (coming soon™️), where this bootstrapper
will be dynamically generated.
- core.el and early-init.el have been reorganized, comment headers moved
around, and comments updated to reflect these changes.
Information is lost when converting font-spec's to xlfd strings (mainly,
DPI), in order to make them compatible with the face frame parameter. To
avoid this, we set the faces' :font attribute instead, which natively
accept font specs, xlfd strings, font objects, and xft strings; no
conversion necessary.
Fix: #6131
Fixes a regression introduced in 0bb4d4dfc, which changed how
doom-switch-buffer-hook works, but makes it fire too early during
startup, eagerly loading packages that wait for the first interactively
opened buffer. This moves doom-init-ui-h to
window-buffer-change-functions, which fires once at the end of startup,
when any buffer is displayed for the first time in the session.
Ref 0bb4d4dfcb
Emacs 27 introduced a bunch of `window-*-change-functions` hooks,
including `window-selection-change-functions` and
`window-buffer-change-functions`, which handles 98% of the use case for
Doom's `doom-switch-{buffer,window,frame}-hook` hooks, so I've rewritten
them to use them under the hood, which amounts to simpler code and fewer
hacks.
Use the new server-after-make-frame-hook, introduced in Emacs 27.1, to
clean up how we initialize fonts, themes, and the UI in general.
This may indirectly fix font issues in daemon sessions.
Emacs 27.x has been the stable version of Emacs for nearly a year, and
introduces a litany of bugfixes, performance, and quality-of-life
improvements that significantly reduce Doom's maintenance burden (like
XDG support, early-init.el, image manipulation without imagemagick, a
native JSON library, harfbuzz support, pdumper, and others).
With so many big changes on Doom's horizon, I like having one less (big)
thing to worry about.
Also reverts bb677cf7a (#5232) as it is no longer needed.
Setting a face's `:font` attribute implicitly sets a host of other faces
attributes (:family, :foundry, :width, :weight, :height, and :slant),
which is problematic in places where these faces are used in tandem with
other faces, like how EWW renders bold elements with both
variable-pitch+bold faces, with the expectation that their attributes
would cascade properly, but not so if variable-pitch sets :weight or
:slant.
custom-theme-set-faces! depends on doom-theme's previous-theme property
being non-nil to determine if the theme has been set (and if so, apply
its changes immediately), but at startup custom-enabled-themes is empty,
so it was never non-nil.
Fixes#5009Fixes#5000
Trying to get 'doom to behave like 'user is too much trouble and causes
too many problems. The magic around 'user is too deeply woven into
custom.el. The whole custom.el fiasco needs to be dealt with another
way.
Fixes#5000Fixes#5009
'doom is a pseudo theme used to store internal faces and variables, and
must have the highest precedence (like the 'user theme, but without the
risk of being written to custom-file).
doom-unicode-font, doom-variable-pitch-font, and the fontset settings
were loaded in the wrong order (before the theme, but should be after).
This means the psuedo 'doom' theme that stores these settings are being
loaded too early.
+ Adds doom-emoji-fallback-font-families
+ Adds doom-symbol-fallback-font-families
+ Gives doom-unicode-font higher precedence (and sets it to nil by
default, since Emacs defaults to symbola already).
+ Store custom face settings in psuedo theme, rather than crowding the
user theme (which may be immortalized to custom-file, which we want to
avoid).
+ Now, after-setting-font-hook is guaranteed to fire after *all* fonts
are set, giving you a more reliable interface to add your own
font(set) modifications.
More testing is needed to ensure the patched fonts our ligatures modules
don't conflict with this change.
Produces more helpful (and harder-to-miss) error messages when a hook
emits an error. Also advises run-hook when doom-debug-mode is active, so
errors in hooks (generally, major mode hooks) don't quietly go
unnoticed.
In older versions of Emacs (26.3 and below), the minibuffer would
replace the whole minibuffer's contents just to display error messages.
This was very frustrating for mundane errors, like the "text is
read-only" error you get when you press backspace at BOL.
Later versions of Emacs now display errors at the end of the minibuffer,
so this hack will no longer be needed when we drop 26.x support later
this year.