Commit graph

1579 commits

Author SHA1 Message Date
Henrik Lissner
037b018cdd
feat: add .doommodule files
These optional dotfiles indicate the root of a module or module
group (:lang), and will later contain module metadata. They will also
serve as an alternative to packages.el and doctor.el, and will aide the
parts of the v3.0 module API concerned with resolving the current module
from a path (`doom-module-from-path`), which currently rely too heavily
on parsing path strings.

For now, however, they're simply placeholders.
2024-09-14 20:47:39 -04:00
Ajai Nelson
c82e7d9ea2 fix(ligatures): avoid invalid prettify-symbols-alist
Otherwise, `prettify-symbols-alist` will be set to a list whose first
element is the mode name, a symbol. That makes `prettify-symbols-alist`
an invalid alist, so when `prettify-symbols-mode` is enabled, there's a
type error in `prettify-symbols--make-keywords`.

Amend: c07f359d64
2024-09-14 13:01:54 -07:00
Henrik Lissner
f452677c55
docs(ligatures): revise docstrings 2024-09-13 23:07:14 -04:00
Henrik Lissner
c07f359d64
fix(ligatures): activate prettify-symbols-mode conditionally
With +extra enabled, this module would activate `prettify-symbols-mode`
in any buffer where `prettify-symbols-alist` is non-nil, whether or not
`+ligatures-extra-alist` has an entry for the current major mode (or a
parent thereof). This behavior is poor UX, since the user may be
expecting that a empty entry for some `X-mode` in
`+ligatures-extra-alist` should mean *no` prettify-symbols-mode` at all
in `X-mode`.

With this, `+ligatures-extra-alist` is now the authority. An empty entry
for `X-mode` will result in `prettify-symbols-mode` *not* being
activated there. If that entry *isn't* empty, it will be combined only
with the global default value of `prettify-symbols-alist`, not any
pre-existing buffer-local value, to make the end result deterministic,
because some modes have their own defaults for it (like
`lisp-prettify-symbols-alist`, `js--prettify-symbols-alist`, and
`rust-prettify-symbols-alist`).

Fix: #7440
2024-09-13 23:07:14 -04:00
Henrik Lissner
bd14095516
fix(ligatures): lisp modes disobeying null +ligatures-extra-symbols
Fix: #7440
2024-09-11 19:46:16 -04:00
Henrik Lissner
771fccc52b
nit: minor reformatting & revision
Also corrects the version string of obsolete variable `+mu4e-backend`.
2024-09-11 19:46:14 -04:00
Henrik Lissner
5ad99220b8
fix(ligatures): no prettify-symbols-mode w/o +extra
Also removes unused variables and functions, and obsoletes
`+ligatures-in-modes`, since it is no longer used.

Fix: #7440
2024-09-11 03:50:57 -04:00
Henrik Lissner
28d0d4c2e9
fix(indent-guides): bars on blank lines breaking line motions
Ref: jdtsmith/indent-bars#22
2024-09-10 20:37:16 -04:00
Henrik Lissner
dd5ae257f1
nit(indent-guides): reformat config.el & proofread comments 2024-09-10 02:26:50 -04:00
Henrik Lissner
98e28d801e
fix(indent-guides): don't activate in noninteractive sessions
Such as when `doom doctor` loads Doom.

Fix: #8058
2024-09-09 20:18:13 -04:00
Henrik Lissner
bbb2cc1cb3
fix(indent-guides): disable indent-bars in tree-sitter-mode
A temporary measure, until the tree-sitter module has adopted treesit,
which indent-bars has support for.
2024-09-09 17:24:45 -04:00
Henrik Lissner
1a33838423
refactor!(cc): remove irony and rtags
BREAKING CHANGE: This removes the irony and rtags packages so we can
lean on LSP servers like clangd and ccls fully, which provide the same
features with much more consistency.

Close: #8049
2024-09-09 16:10:19 -04:00
Henrik Lissner
bcdb945465
fix(indent-guides): interop with magit-blame
Ref: af814ff86a
Ref: #8052
2024-09-09 00:35:57 -04:00
Henrik Lissner
af814ff86a
fix(indent-guides): interop with lsp-ui-peek
Ref: #8052
2024-09-08 17:54:18 -04:00
Henrik Lissner
0461c5de5f
tweak(indent-guides): subtle bars & bitmaps (almost) by default
In e0a926d, I defaulted to not using bitmaps for indent-guides, but
after some more research, I realize this slowness is more prominent on
MacOS, older PGTK builds, and (possibly) Windows, so I've opted to
re-enable bitmaps by default, unless you're on one of those
systems (except Windows; still testing that).

This change also makes the guide bars more subtle, since the default is
too distracting and colorful.

Ref: #8052
Ref: e0a926dc1e
2024-09-07 22:41:53 -04:00
Henrik Lissner
0d9e188b26
refactor!(indent-guides): use indent-bars instead
BREAKING CHANGE: This swaps out the `highlight-indent-guides` package
with the newer, and proportedly faster, `indent-bars`. Users don't have
to make any changes to their config to support this, unless they've
heavily reconfigured `highlight-indent-guides`.

Ref: https://github.com/orgs/doomemacs/projects/5/views/1?filterQuery=-status%3ARejected%2CDone+indent&pane=issue&itemId=38113671
2024-09-07 19:04:37 -04:00
gpanago
ed05e4c088 feat(nav-flash): blink on workspace change
Changing workspace is big motion so we should blink the cursor.
We can not use `+nav-flash-blink-cursor-maybe-h` as the point
is not yet in the correct buffer when the hook is triggered.
2024-09-07 12:10:41 -07:00
Henrik Lissner
e0a926dc1e
tweak(indent-guides): default to character method
The bitmap method is slower and not that different, visually, from the
character method.

Fix: #8052
Co-authored-by: nightkr <nightkr@users.noreply.github.com>
2024-09-06 16:15:57 -04:00
Henrik Lissner
52c91cc51c
fix(tabs): workspace-scoped buffer lists 2024-09-04 15:04:31 -04:00
Henrik Lissner
8083d398c5
refactor(tabs): remove unused variable
Hasn't been needed since 4f4718e.

Amend: 4f4718e6d1
2024-09-03 00:46:35 -04:00
Henrik Lissner
affaa7ec9c
docs(ligature): use correct obsoleted-in version
These should reflect the version of doomemacs/modules the symbols were
deprecated in, not the version of doomemacs/core.
2024-08-31 21:32:55 -04:00
Henrik Lissner
d1c2c8c35b
fix(popup): don't disable hide-mode-line if enabled globally
Ref: hlissner/emacs-hide-mode-line#11
2024-08-29 02:46:21 -04:00
Henrik Lissner
d6a2e24a3e
fix(dired,vc-gutter): don't inhibit diff-hl-dired-mode
Dirvish uses the fringe for its vc-state diff, which isn't available in
TTY Emacs, so we still need `diff-hl-dired-mode` there.

Revert: a8ed6c9f7d
Ref: #6760
2024-08-29 01:12:29 -04:00
Henrik Lissner
3c4921cc57
fix(popup): only remap quit-window in popup buffers 2024-08-28 23:04:21 -04:00
Henrik Lissner
14478064af
refactor(dired,vc-gutter): setup for tty frames
A recent commit (c53f63b) allows me to simplify this a bit.

Ref: c53f63b96e
Ref: #8001
2024-08-28 17:56:55 -04:00
Henrik Lissner
6077b6f0d8
fix: correct version string in obsoletion calls 2024-08-26 18:07:47 -04:00
Henrik Lissner
93c5f98ee2
fix(vc-gutter): resist errors in kill-buffer advice
A regression introduced in aa8c31c.

Fix: #8018
Ref: #8009
Amend: aa8c31cf08
2024-08-22 16:06:42 -04:00
Henrik Lissner
e59023b843
fix(vc-gutter): toggle diff-hl-margin-mode in tty frames
Fix: #8001
2024-08-22 15:50:34 -04:00
Henrik Lissner
d941078e66
tweak(ligatures): +ligatures-extra-alist: affect derived modes
Close: #7808
Co-authored-by: Dev380 <Dev380@users.noreply.github.com>
2024-08-22 12:32:14 -04:00
Chenty
b835e7b6ec
fix(workspaces): don't overwrite previously workspaces on save
Otherwise, each time `+workspace-save` is called, all prior saved
workspaces would be deleted from `+workspaces-data-file` before
inserting the new one.
2024-08-22 12:20:17 -04:00
Henrik Lissner
aa8c31cf08
fix(vc-gutter): wrong-number-of-args error
A regression introduced in ded3f5e.

Fix: #8009
Amend: ded3f5ec83
2024-08-21 12:57:28 -04:00
Henrik Lissner
ff9c59df46
tweak(vc-gutter): disable diff-hl-mode in pdf-view-mode 2024-08-21 05:04:25 -04:00
Henrik Lissner
ded3f5ec83
fix(vc-gutter): runaway diff-hl threads & immortal buffers
This was an elusive bug caused by two upstream behaviors:

1. `kill-buffer` will silently refuse to kill a buffer if there is a
   thread associated with it.
2. `global-diff-hl-mode` activates `diff-hl-mode` in *most* buffers,
   even invisible ones. This calls `diff-hl-update` each time
   it does. This isn't a problem *unless* you have `diff-hl-update-async`
   enabled, because it creates a thread every time `diff-hl-update` is
   called. That means for every buffer -- real or transient -- you have
   a new thread queued.

And this caused two main issues:

1. Temporary buffers are often opened and closed very rapidly (often
   faster than the thread can complete), so they weren't getting cleaned
   up. I hope you weren't too attached to your memory, because you'll
   have a lot of buried buffers to feed before long!
2. In cases where `diff-hl-update` simply takes a long time, multiple
   calls to it would queue more threads. When Emacs eventually yields
   the CPU to them, you'll get random,
   impossible-to-predict-or-track-down freezes. Joy!

This may very well be enough reason to disable `diff-hl-update-async` by
default, but I didn't want to give up on it *just* yet, despite how
inelegant this solution is...

Fix: #7954
Fix: #7991
2024-08-21 05:03:30 -04:00
Henrik Lissner
bf330b405d
refactor(ligatures): use (featurep 'harfbuzz)
Doom adds this feature in lisp/doom.el.
2024-08-20 00:09:55 -04:00
Henrik Lissner
0ce403d069
refactor(ligatures): set-font-ligatures!: unsetting multiple modes
This changes set-font-ligature such that unsetting multiple modes will
properly manipulate multi-mode entries in ligature-composition-table.
2024-08-20 00:03:50 -04:00
Henrik Lissner
ef142fc913
refactor(ligatures): defer ligature.el & combine variables
This combines `+ligatures-prog-mode-list` and `+ligatures-all-mode-list`
into `+ligatures-alist` (and deprecates the former).
2024-08-20 00:03:50 -04:00
Henrik Lissner
dff6c36ab5
docs(ligatures): use set-font-ligatures! 2024-08-20 00:03:49 -04:00
Henrik Lissner
a8ed6c9f7d
fix(vc-gutter): inhibit diff-hl-dired-mode in dirvish
Ref: #6760
2024-08-17 14:24:51 -04:00
Henrik Lissner
5e2e886b35
nit: comment revision & reformatting 2024-08-15 23:18:47 -04:00
Henrik Lissner
334157d741
fix(popup,org): popup management for org-mode
Adapts to changes made upstream to Org's window management logic (e.g.
Org dropped `org-switch-to-buffer-other-window` for
`switch-to-buffer-other-window`, and org-journal renamed one of its
helper functions).
2024-08-09 17:41:48 -04:00
Henrik Lissner
b3bea23331
fix(workspaces): "none" workspace
Doom removes the "none" workspace from persp-mode's default list of
perspectives, because it is a special case that doesn't behave
identically to other persps in the list, making it a pain to deal with.

This worked fine up until a change to `persp-update-names-cache` (in
Bad-ptr/persp-mode.el@0d6cacc) made it re-insert this "none" workspace
into `persp-names-cache` whenever it is called, undoing our hack; this
commit adapts to that change.

Ref: Bad-ptr/persp-mode.el@0d6caccab3
Ref: Bad-ptr/persp-mode.el@b2e68f97cb
Fix: #7986
Amend: 7f3412e317
2024-08-09 15:42:54 -04:00
Henrik Lissner
7f3412e317
bump: :ui
Alexander-Miller/treemacs@54ef590b76 -> Alexander-Miller/treemacs@202d7f01d6
Bad-ptr/persp-mode.el@345baaa520 -> Bad-ptr/persp-mode.el@40e9993a97
dgutov/diff-hl@57d9d4e3e1 -> dgutov/diff-hl@b80ff9b4a7
ema2159/centaur-tabs@d6009c295a -> ema2159/centaur-tabs@063534bd00
emacs-lsp/lsp-treemacs@1d43e9e030 -> emacs-lsp/lsp-treemacs@fb1a07ae0a
emacs-straight/minimap@4898d27768 -> emacs-straight/minimap@5aa0df40bc
seagle0128/doom-modeline@1505c13564 -> seagle0128/doom-modeline@9920ef5116
tarsius/hl-todo@dd46d426c0 -> tarsius/hl-todo@82eba6b8f7
2024-08-08 17:26:58 -04:00
Henrik Lissner
9cdcfdac36
feat(workspaces): add +workspace/delete
For deleting saved workspaces (saved with `+workspace/save` or
`+workspace-save`).

Also binds `SPC TAB D` (for evil users) and `C-c w K` (for non-evil
users) to it.

Fix: #4399
Close: #7869
Co-authored-by: sriramsk1999 <sriramsk1999@users.noreply.github.com>
2024-07-29 20:57:56 -04:00
Henrik Lissner
0f30e1eca5
bump: :ui vc-gutter :tools magit :emacs vc
dgutov/diff-hl@f66345ed1f -> dgutov/diff-hl@57d9d4e3e1
magit/forge@9edfcb2c15 -> magit/forge@21d410c810
magit/magit@9d4192b7b1 -> magit/magit@e777822720
2024-07-29 02:03:25 -04:00
Henrik Lissner
5f798cf8e7
feat(indent-guides): add +indent-guides-inhibit-functions
Also adds a fix for indent-guides breaking inline images in
ein:notebook-mode (#6438).

Fix: #6438
Ref: 29277c9b02
2024-07-29 02:03:25 -04:00
Dan McArdle
ff3fd15b02 fix(vc-gutter): check 'diff-hl-disable-on-remote is bound
This fixes the following error message on startup:

    Symbol’s value as variable is void: diff-hl-disable-on-remote
2024-07-26 16:29:34 -04:00
Henrik Lissner
dec2a387ad
fix(modeline): remove advice causing org-element cache errors in org
This advice was suppressing ws-butler's modification hooks, which had a
nasty side-effect of modifying org buffers without letting its
org-element cache know that it's stale, which resulted in errors like
this, followed by a backtrace:

  Warning (org-element): org-element--cache: Unregistered buffer modifications detected (175 != 176). Resetting.
  If this warning appears regularly, please report the warning text to Org mode mailing list (M-x org-submit-bug-report).

The advice isn't needed anymore, anyhow.
2024-07-26 04:46:54 -04:00
Henrik Lissner
7c5d8641a1
fix(vc-gutter): respect diff-hl-disable-on-remote in dired
Neither `diff-hl-dired-mode` or `diff-hl-dired-mode-unless-remote`
respect diff-hl-disable-on-remote, so added my own enabler hook.
2024-07-25 19:43:28 -04:00
Henrik Lissner
a8b836dac3
fix(vc-gutter): use global-diff-hl-mode
Our former approach would enable diff-hl unconditionally. This way, the
`diff-hl-global-modes` variable is respected.

Ref: https://discourse.doomemacs.org/t/4710/2
2024-07-25 19:43:28 -04:00
Henrik Lissner
db36c74bbb
refactor: minor refactors 2024-07-18 22:38:59 -04:00