Commit Graph

123 Commits

Author SHA1 Message Date
00e23db0b0 Fix workspace restore/load workspace keybinds
As well as keybind on dashboard.
2018-07-04 13:40:44 +02:00
1d4a41833e Don't wrap forward/backward-button keys 2018-07-03 20:07:14 +02:00
d0eaa0af1e Redesign dashboard widgets 2018-07-03 20:07:14 +02:00
81ffed520b Rename doom-before-switch-*-hook hooks
+ doom-before-switch-buffer-hook => doom-exit-buffer-hook
+ doom-before-switch-window-hook => doom-exit-window-hook
+ doom-after-switch-buffer-hook => doom-enter-buffer-hook
+ doom-after-switch-window-hook => doom-enter-window-hook

Shorter, easier-to-type names that better describe their intended
purpose.

The old names are still usable, but deprecated.
2018-07-03 03:41:08 +02:00
15f2e21468 On second thought...
Causes char-table-p errors in some cases.

Setting hscroll-margin = 0 in dashboard accomplishes the same thing, by
preventing truncation glyphs from ever appearing anyway.
2018-06-30 02:58:01 +02:00
a4121f33c0 Revert "Require project root in dashboard buffer #733"
This reverts commit 2dac739ce7.

Causes breaking "Not in project" errors at startup in certain daemon
workflows.
2018-06-29 00:56:04 +02:00
2dac739ce7 Require project root in dashboard buffer #733
Require default-directory to be in a valid project for project commands
to work. This will prevent hangs when accidentally invoking
projectile-find-file from $HOME.
2018-06-28 20:15:50 +02:00
205cc718d2 Fix dashboard not appearing in daemon frames
Because they start in the *server* buffer, instead of the *scratch*
buffer.
2018-06-19 17:44:24 +02:00
486019d853 Remove leading space in dashboard buffer's name
The leading space indicates a temporary buffer. The dashboard is no such
thing!
2018-06-16 21:01:16 +02:00
08986d9101 Simplify dashboard initial buffer check
We only need to check if we're in the scratch buffer. doom-real-buffer-p
is overkill for that.

This also reduces file loads at startup for autoloaded functions added
to the doom-real-buffer-functions and doom-unreal-buffer-functions.
2018-06-16 21:00:37 +02:00
eaca8c58fa Move unit tests from ert to buttercup
Easier to organize and write. Now I can hopefully strive for better
coverage!
2018-06-15 03:42:01 +02:00
e71cd93488 Don't change which-key settings in doom dashboard 2018-06-03 17:22:23 +02:00
1e81a35461 Minimize dependence on map!
This is in preparation for general.el integration coming in 2.1.1. It is
very likely that map! will change (and even more, be split into several
macros). Not much, but change none-the-less. Specifically, the state
keywords (e.g. :nvi, :n, :i) will be removed in favor of a :state
property that takes a list, e.g. (normal visual insert).

In any case, both map! and general are also relatively expensive
compared to define-key and evil-define-key* (and the new define-key!
macro), so use that when we can.

This also means changes to either API won't affect Doom's modules in the
long term.
2018-06-03 15:46:00 +02:00
01b07e573e Fix visual j/k in dashboard and evil-mode
In case you've remapped j/k to gj/gk universally.
2018-06-03 12:04:42 +02:00
e66abfb9e8 Use newline-based alignment technique on dashboard
Fixes #645, because Emacs' mouse events don't appear to compensate for
variable-width whitespace.
2018-06-02 10:48:55 +02:00
2f83757018 ui/doom-dashboard: more robust feature detection
In case you aren't using those modules, but have other means of loading
those packages.
2018-05-25 00:54:07 +02:00
09cb4f6716 Major refactor & optimization of how modules load their packages
Now that we are loading package autoloads files (as part of the
generated doom-package-autoload-file when running make autoloads), many
:commands properties are redundant. In fact, many def-package! blocks
are redundant.

In some cases, we can do without a config.el file entirely, and can move
into the autoloads file or rely entirely on package autoloads.

Also, many settings have been moved in their module's autoloads files,
which makes them available ASAP; their use no longer depends on module
load order.

This gained me a modest ~10% boost in startup speed.
2018-05-25 00:46:16 +02:00
06c22a5af2 ui/doom-dashboard: add vertical centering (experimental) 2018-05-15 21:49:50 +02:00
5537f81e02 ui/doom-dashboard: doom-packages--benchmark => doom|display-benchmark 2018-05-14 20:56:17 +02:00
61865d0646 ui/doom-dashboard: don't open dashboard over files (part 2) #523 2018-04-18 19:41:50 -04:00
dbd6982e06 ui/doom-dashboard: don't open dashboard over files via emacsclient #523 2018-04-18 01:08:56 -04:00
c24c868945 ui/doom-dashboard: remove 'Edit Doom Emacs' button 2018-04-03 16:58:41 -04:00
cc13f51b7f ui/doom-dashboard: update for new doom-private-dir 2018-04-03 16:29:14 -04:00
93678494cb ui/doom-dashboard: fix wrong-type-arg error on reload 2018-03-27 19:08:46 -04:00
8604966e21 ui/doom-dashboard: add 'edit modules list' button 2018-03-24 17:53:13 -04:00
4d80c20251 Add arrow, tab/S-tab, & C-n/C-p keys for navigating dashboard 2018-03-20 17:36:23 -04:00
b68fa3b120 ui/doom-dashboard: disable visual mode in post-command-hook too 2018-03-20 00:00:21 -04:00
facd83a54b Remove redundant reload in +doom-dashboard/open 2018-03-19 02:03:42 -04:00
ff0b45299e Refactor dashboard autoload functions 2018-03-18 15:17:40 -04:00
d75df875c9 Trap cursor in buttons better in dashboard #465 2018-03-18 15:17:20 -04:00
01cb16cf42 ui/doom-dashboard: minor refactor 2018-03-18 02:36:12 -04:00
a9c8f8f41b ui/doom-dashboard: lock point in buttons #465 2018-03-18 02:35:52 -04:00
dba1f20dd3 ui/doom-dashboard: refresh dashboard on buffer switch 2018-03-14 18:51:08 -04:00
c2fd538261 Refactor doom startup benchmark 2018-02-28 17:57:29 -05:00
dd163dace0 Fix org-agenda-list showing on dashboard 2018-02-28 13:53:37 +01:00
18d0b9425d ui/doom-dashboard: add sharp quote 2018-02-18 20:50:30 -05:00
f8bf86e1a3 ui/doom-dashboard: add button to open private module 2018-02-16 21:02:46 -05:00
2b1c323dbf 💥 Redesign private sub-module system
~/.doom.d/modules is now a full module tree, like ~/.emacs.d/modules.
Symlinks are no longer involved.

Private modules can now shadow Doom modules. e.g.
~/.doom.d/modules/lang/org will take precendence over
~/.emacs.d/modules/lang/org.

Also, made doom--*-load-path variables public (e.g. doom--site-load-path
=> doom-site-load-path), and rearranged the load-path for a 10-15%
startup boost.
2018-02-16 02:11:10 -05:00
ca262f5e4e Rename doom-fallback-buffer (variable) => doom-fallback-buffer-name 2018-02-01 20:06:00 -05:00
4567054aed ui/doom-dashboard: no emacs-state in dashboard 2018-02-01 19:58:44 -05:00
2ab0072d83 ui/doom-dashboard: fix dashboard not updating pwd on kill-buffer 2018-02-01 01:24:19 -05:00
5827186123 ui/doom-dashboard: +default/find-in-emacsd => doom-project-find-file 2018-01-29 01:02:24 -05:00
8b19e35ef6 Consider dired-mode buffers real 2018-01-28 20:37:40 -05:00
086a1659b4 ui/doom-dashboard: edit emacs.d button => fuzzy find-file 2018-01-28 18:15:43 -05:00
e3040c676b ui/doom-dashboard: reload at least once on startup 2018-01-28 18:15:22 -05:00
4977d22b75 ui/doom-dashboard: don't hide dired-mode buffers on startup 2018-01-28 18:15:04 -05:00
7bfd7c1ade ui/doom-dashboard: don't change default-directory on startup 2018-01-28 18:14:41 -05:00
0d83834ac7 ui/doom-dashboard: major refactor
+ Fix default-directory not being set properly when switching
  perspectives. ie. Add persp-mode integration (#347, #360)
+ Ensure dashboard initializes properly, at the right time to ensure
  benchmark is properly reported (fix #361)
2018-01-20 15:42:13 -05:00
e6e1282346 ui/doom-dashboard: fix recentf, project & bookmark buttons
When none of these buttons' commands were remapped, you'd get a commandp
nil error.
2018-01-12 18:41:10 -05:00
637a678529 ui/doom-dashboard: fix unchanging default-directory #347 2018-01-11 12:24:38 -05:00