summaryrefslogtreecommitdiff
path: root/.emacs.d/modules
diff options
context:
space:
mode:
authorThanos Apollo <[email protected]>2023-09-09 21:00:05 +0300
committerThanos Apollo <[email protected]>2023-09-09 21:00:05 +0300
commit38c3cc67f93c9c78849bc707fa60184485c3616b (patch)
tree8266a2a561961586be90ad0c7787cb07df85333c /.emacs.d/modules
parente0f70b1254a61299b9a6546bac31282d96969150 (diff)
devtools.el: Add thanos/consult-register map
Diffstat (limited to '.emacs.d/modules')
-rw-r--r--.emacs.d/modules/thanos-devtools.el12
1 files changed, 12 insertions, 0 deletions
diff --git a/.emacs.d/modules/thanos-devtools.el b/.emacs.d/modules/thanos-devtools.el
index 111e8c7..b24e92c 100644
--- a/.emacs.d/modules/thanos-devtools.el
+++ b/.emacs.d/modules/thanos-devtools.el
@@ -62,6 +62,18 @@
(define-key global-map (kbd "C-x r .") 'consult-register)
(define-key corfu-map (kbd "RET") nil) ;; Leave my enter alone
+(define-prefix-command 'thanos/consult-register)
+(define-key global-map (kbd "C-c r") 'thanos/consult-register)
+(define-key thanos/consult-register (kbd ".") 'consult-register)
+(define-key thanos/consult-register (kbd "s") 'consult-register-store)
+
+(setf register-preview-delay 0.5
+ register-preview-function #'consult-register-format)
+
+;; xref
+(setf xref-show-xrefs-function #'consult-xref
+ xref-show-definitions-function #'consult-xref)
+
(defun insert-brackets (&optional arg)
"Insert brackets."
(interactive "P")