Commit graph

99 commits

Author SHA1 Message Date
Henrik Lissner
659f7bfc71
refactor!: deprecate IS-* OS constants
BREAKING CHANGE: This deprecates the IS-(MAC|WINDOWS|LINUX|BSD) family
of global constants in favor of a native `featurep` check:

  IS-MAC      ->  (featurep :system 'macos)
  IS-WINDOWS  ->  (featurep :system 'windows)
  IS-LINUX    ->  (featurep :system 'linux)
  IS-BSD      ->  (featurep :system 'bsd)

The constants will stick around until the v3 release so folks can still
use it -- and there are still some modules that use it, but I'll phase
those uses out gradually.

Fix: #7479
2024-02-04 17:54:29 -05:00
Henrik Lissner
3b692e92f5
refactor(modeline): remove doom-modeline-buffer-modified shim
No longer needed.

Ref: seagle0128/doom-modeline@5c98267310
2023-09-14 03:42:14 +02:00
Ellis Kenyő
9787022b83
refactor!: replace all-the-icons with nerd-icons
BREAKING CHANGE: This commit replaces all-the-icons with nerd-fonts. Any
all-the-icons-* function calls or variable references in your private
config will break and should be replaced with their nerd-icons-*
equivalent. That said, Doom will continue to install all-the-icons for
a while, so feel free to load it if you don't want to fully commit to
the change yet.

This change is happening because nerd-icon has wider support for GUI and
TUI Emacs; has a larger, more consistent selection of symbols; plus unicode
coverage.

Fix: #7368
Close: #6675
Close: #7364
2023-09-14 01:03:55 +02:00
Henrik Lissner
67a42e8222
bump: :ui modeline
emacsorphanage/evil-anzu@d3f6ed4773 -> emacsorphanage/evil-anzu@d1e98ee697
seagle0128/doom-modeline@ce9899f00a -> seagle0128/doom-modeline@bed80b82d7

Also improves Emacs 29 compatibility (see ref).

Ref: emacs-mirror/emacs@d0a66f3e0e
2022-09-16 13:07:28 +02:00
Henrik Lissner
ad6a3d0f33
refactor: deprecate featurep! for modulep!
featurep! will be renamed modulep! in the future, so it's been
deprecated. They have identical interfaces, and can be replaced without
issue.

featurep! was never quite the right name for this macro. It implied that
it had some connection to featurep, which it doesn't (only that it was
similar in purpose; still, Doom modules are not features). To undo such
implications and be consistent with its namespace (and since we're
heading into a storm of breaking changes with the v3 release anyway),
now was the best opportunity to begin the transition.
2022-08-14 20:43:35 +02:00
Henrik Lissner
06392a723f refactor: rename orig-fn arg in advice to fn
A minor tweak to our naming conventions for the first argument of an
:around advice.
2021-08-04 01:53:12 -04:00
Henrik Lissner
05866ce30f ui/modeline: don't show encoding unless nondefault 2021-05-16 21:15:55 -04:00
Henrik Lissner
adff1aa68d
Fix #4102: wrong-type-arg plistp errors in daemon tty frames 2020-10-22 02:10:59 -04:00
Henrik Lissner
a1fc5886cc
Fix #3710: remove ineffective advice
This fix was meant to fix #2219, but didn't actually work, and was
causing odd "C-g is invalid" errors in #3710.
2020-08-20 02:30:11 -04:00
Henrik Lissner
fa55a0889a
Enable global-anzu-mode after evil-anzu loads
evil-anzu depends on anzu-mode being enabled to update its results, so
we enable global-anzu-mode when evil-search (or isearch) is first
invoked.
2020-05-27 14:06:17 -04:00
Henrik Lissner
7460e9e798
Resize modeline when resizing fonts
Possibly fixes #3040
2020-05-05 16:28:29 -04:00
Henrik Lissner
5c56c0b218
Enable {size-indicator,column-number}-mode on doom-modeline-mode 2020-04-09 17:48:47 -04:00
Henrik Lissner
28d5127793
ui/modeline: use VCS format for magit-status-mode 2020-02-28 12:20:21 -05:00
Henrik Lissner
ac52e644a8
Revert doom-modeline formats to defaults
It's not tenable for me to maintain this package more than I have to
anymore, now that I no longer use doom-modeline.

Addresses #2356, #1680
2020-02-02 03:16:53 -05:00
Henrik Lissner
0e4d25d533
ui/modeline: prevent cut-off popups #2219
By forcing resized windows to take non-standard modeline height into
account.
2019-12-20 20:37:55 -05:00
Henrik Lissner
f236d27d51
ui/modeline: add +light feature
This will one day replace the module.
2019-12-13 20:07:41 -05:00
Henrik Lissner
fbe8d9d8ac
ui/modeline: remove dangling advice
`doom-modeline-icon-material` was removed upstream and replaced with
`doom-modeline-icon`. This breaks the saved icon, again. PRs welcome.
2019-12-13 19:52:52 -05:00
Sean Farley
d5d5c08658 modeline: add irc-buffers back
Now that doom-modeline #260 is resolved, `irc-buffers' is back so let's
add it back to the `special' modeline definition.
2019-11-21 17:16:42 -08:00
Henrik Lissner
25e5c66777
Fix 'irc-buffers is not a defined segment' error
It was merged into irc segment upstream:
seagle0128/doom-modeline/dcc57fd4
2019-11-16 13:24:29 -05:00
Clement Busschaert
82ecfac39c
ui/modeline: fix ligature advice for hlissner#1216 2019-10-24 22:24:39 +02:00
Henrik Lissner
2cd06d23cd
ui/modeline: rename fancy-battery -> battery
The fancy-battery segment was removed upstream:
seagle0128/doom-modeline/commit/93135d4
2019-10-24 15:45:55 -04:00
Henrik Lissner
3f6dfe8eac
ui/modeline: fix ligature advice for #1216 2019-10-24 14:31:50 -04:00
Henrik Lissner
909c277968
ui/modeline: fix ligature/all-the-icons conflict #1216
Relevant to seagle0128/doom-modeline#69
2019-10-23 18:05:08 -04:00
Henrik Lissner
fd67534c89
Change how {size-indication,column-number}-mode are enabled
Relevant to #1817
2019-09-29 13:11:26 -04:00
Henrik Lissner
1c05773c39
General, minor refactors & comment revision 2019-09-11 23:41:08 -04:00
Henrik Lissner
19ecf8e46a
Correct last inline hook defuns
See a3e262c7 for rationale
2019-07-28 16:10:53 +02:00
Henrik Lissner
82ae3a73f3
def-advice!->defadvice! & conform to new advice conventions
This commit does two things:

- Renames def-advice! to defadvice!, in the spirit of naming convenience
  macros after the function/macro they enhance or replace.
- Correct the names of advice functions to indicate visibility and
  intent. A public advice function like doom-set-jump-a is meant to be
  used elsewhere. A private one like +dired--cleanup-header-line-a
  shouldn't -- it likely won't work anywhere but the function(s) it was
  made to advise.
2019-07-23 17:24:56 +02:00
Henrik Lissner
76cacb5bfe
💥 Rename def-package! -> use-package!
Calling this pivotal macro "def-package!" has frequently been a source
of confusion. It is a thin wrapper around use-package, and it should be
obvious that it is so. For this reason, and to match the naming
convention used with other convenience macros/wrappers, it is now
use-package!.

Also changes def-package-hook! -> use-package-hook!

The old macros are now marked obsolete and will be removed when straight
integration is merged.
2019-07-23 12:50:45 +02:00
Henrik Lissner
1c4215c187
Fix 'command not found' errors for hidden commands 2019-07-22 04:46:14 +02:00
Henrik Lissner
149b2617b0
💥 revise hook/var fns naming convention (2/2)
This is second of three big naming convention changes. In this commit,
we change the naming conventions for hook functions and variable
functions:

1. Replace the bar | to indicate a hook function with a -h suffix, e.g.

     doom|init-ui -> doom-init-ui-h
     doom|run-local-var-hooks -> doom-run-local-var-hooks-h

2. And add a -fn suffix for functions meant to be set on variables,
   e.g.

     (setq magit-display-buffer-function #'+magit-display-buffer-fn)

See ccf327f8 for the reasoning behind these changes.
2019-07-22 02:30:38 +02:00
Henrik Lissner
51d3b1b424
💥 revise advice naming convention (1/2)
This is first of three big naming convention updates that have been a
long time coming. With 2.1 on the horizon, all the breaking updates will
batched together in preparation for the long haul.

In this commit, we do away with the asterix to communicate that a
function is an advice function, and we replace it with the '-a' suffix.
e.g.

  doom*shut-up -> doom-shut-up-a
  doom*recenter -> doom-recenter-a
  +evil*static-reindent -> +evil--static-reindent-a

The rationale behind this change is:

1. Elisp's own formatting/indenting tools would occasionally struggle
   with | and * (particularly pp and cl-prettyprint). They have no
   problem with / and :, fortunately.
2. External syntax highlighters (like pygmentize, discord markdown or
   github markdown) struggle with it, sometimes refusing to highlight
   code beyond these symbols.
3. * and | are less expressive than - and -- in communicating the
   intended visibility, versatility and stability of a function.
4. It complicated the regexps we must use to search for them.
5. They were arbitrary and over-complicated to begin with, decided
   on haphazardly way back when Doom was simply "my private config".

Anyhow, like how predicate functions have the -p suffix, we'll adopt the
-a suffix for advice functions, -h for hook functions and -fn for
variable functions.

Other noteable changes:
- Replaces advice-{add,remove}! macro with new def-advice!
  macro. The old pair weren't as useful. The new def-advice! saves on a
  lot of space.
- Removed "stage" assertions to make sure you were using the right
  macros in the right place. Turned out to not be necessary, we'll
  employ better checks later.
2019-07-22 02:27:45 +02:00
Henrik Lissner
2e96fce2e0
ui/modeline: remove obsolete advice (fix #1372) 2019-06-19 11:37:27 +02:00
Andrew Whatson
9e8517c59e Add :editor objed module
Integrates `objed` with Doom Emacs to provide text-object manipulation
for non-evil users.

See https://github.com/clemera/objed
2019-05-30 22:35:27 +10:00
Henrik Lissner
0a0def6a53
ui/modeline: update README
To reflect our adoption of the doom-modeline package. Still a WIP, but
is at least more correct now.

Renders #1412 unnecessary.
2019-05-13 19:34:44 -04:00
Henrik Lissner
0f0fdbc00c
Add doom/{increase,decrease,reset}-font commands
Borrows the idea from zoom-frm (see #1389).
2019-05-12 21:56:52 -04:00
Henrik Lissner
c28a018e42
Fix void-variable mouse-wheel-{up,down}-event errors 2019-05-06 16:55:10 -04:00
Henrik Lissner
b2d49c29ca
ui/modeline: minor refactor/reformatting 2019-04-29 18:13:28 -04:00
Henrik Lissner
4aa4802885
ui/modeline: remove indent segment
It's wasted space now that dtrt-indent logs changes to indentation.

Also resolves a performance issue where the tab/space unicode character
would cause long 3-5s delays on startup or first-file load.
2019-04-29 18:03:18 -04:00
Henrik Lissner
77e4cc4d58
💥 Remove :feature category
:feature was a "catch-all" category. Many of its modules fit better in
other categories, so they've been moved:

- feature/debugger -> tools/debugger
- feature/evil -> editor/evil
- feature/eval -> tools/eval
- feature/lookup -> tools/lookup
- feature/snippets -> editor/snippets
- feature/file-templates -> editor/file-templates
- feature/workspaces -> ui/workspaces

More potential changes in the future:

- A new :term category for terminal emulation modules (eshell, term and
  vterm).
- A new :os category for modules dedicated to os-specific functionality.
  The :tools macos module would fit here, but so would modules for nixos
  and arch.
- A new :services category for web-service integration, like wakatime,
  twitter, elfeed, gist and pastebin services.
2019-04-24 18:16:04 -04:00
Henrik Lissner
37cd50ac80
Revert e9f788cf
The hook is harmless.
2019-04-19 20:57:02 -04:00
Henrik Lissner
e9f788cf67
Remove redundant project-modeline hook
Added upstream recently
2019-04-15 04:09:39 -04:00
Henrik Lissner
2c7f917691
Fix #1315: blank modeline on doom/reload
Default mode-line-format shouldn't be tampered with except at startup.
2019-04-09 14:36:21 -04:00
Henrik Lissner
379c01ba1e
ui/modeline: fix icons in daemon-spawned frames
Fix modeline icons in daemon-spawned graphical frames. We have our own
mechanism for disabling all-the-icons, so we don't need doom-modeline to
do it for us. However, this may cause unwanted padding in the modeline
in daemon-spawned terminal frames. If it bothers you, you may prefer
`doom-modeline-icon' set to `nil'.
2019-03-25 01:28:59 -04:00
Henrik Lissner
c707a96648
ui/modeline: use simple format for checker segment 2019-03-14 17:59:24 -04:00
Henrik Lissner
cd64fb27f8
Fix breaking commit 1ce2b291
Possible nil being passed into file-local-name was causing stringp
errors all over the place.
2019-03-14 00:00:22 -04:00
Henrik Lissner
1ce2b29193
ui/modeline: minor startup optimization
Prevents project.el from being eager-loaded at startup.
2019-03-13 18:46:06 -04:00
Henrik Lissner
16f7bad266
Hide magit modeline more selectively 2019-03-11 12:58:53 -04:00
Henrik Lissner
f0013083c0
Restore minimal modeline in magit
With process indicator
2019-03-11 12:54:16 -04:00
Henrik Lissner
66d75936fc
config/default: split into evil/emacs files
Done to better facilitate a non-evil config.

- Adds winum (and enables support for it in doom-modeline)
- Adds expand-region (#1231)
- Uses default smartparens config for non-evil users (WIP)
2019-03-09 03:43:14 -05:00
Henrik Lissner
748b197676
Minor, general refactors 2019-03-08 04:25:45 -05:00