(setq package-selected-packages
'(academic-phrases avy ace-window alert
all-the-icons all-the-icons-completion anzu
- auctex-latexmk beacon benchmark-init browse-at-remote
+ auctex-latexmk benchmark-init browse-at-remote
browse-kill-ring cape corfu command-log-mode dabbrev define-word
diff-hl diminish disable-mouse dockerfile-mode dtache elfeed
emacsql-sqlite3 embark-consult erlang exec-path-from-shell
(defun esy/setup-display ()
"Setup display-related customizations."
(require 'diff-hl)
- (require 'beacon)
(require 'paren)
(require 'lin)
(require 'which-key)
(require 'whitespace-cleanup-mode)
- (setq beacon-color "magenta"
- show-paren-context-when-offscreen t)
+ (setq show-paren-context-when-offscreen t)
(add-to-list 'lin-mode-hooks 'package-menu-mode-hook)
(add-to-list 'lin-mode-hooks 'gnus-summary-mode-hook)
(add-to-list 'lin-mode-hooks 'gnus-group-mode-hook)
(add-to-list 'lin-mode-hooks 'gnus-server-mode-hook)
(global-diff-hl-mode)
(lin-global-mode 1)
- (beacon-mode 1)
(transient-mark-mode)
(show-paren-mode))
(defun esy/org-maybe-prompt-custom-id ()
"Prompt for CUSTOM_ID if not set for the entry at POINT."
(unless (org-entry-get (point) "CUSTOM_ID")
- (beacon-blink)
+ (pulse-momentary-highlight-one-line)
(org-cycle)
(call-interactively #'esy/org-fill-custom-id)
(org-global-cycle 1)))
(widen)
(goto-char pos))
(recenter)
- (beacon-blink))))
+ (pulse-momentary-highlight-one-line))))
(defun esy/buttons (&optional buffer)
"Return an alist of buttons in BUFFER."
(while button
(setq buttons
(cons `(,(concat (truncate-string-to-width
- (string-replace "\n"
- " "
- (button-label button))
+ (esy/inline (button-label button))
64 nil ?\s t)
" "
(propertize (format "[%d]" index) 'invisible t))
(setq button (next-button (button-end button))))
(reverse buttons))))))
+ (defun esy/inline (str)
+ "Inline STR."
+ (when str
+ (string-replace "\n" " " str)))
+
(defun esy/consult-push-button ()
"Choose a button in the current buffer with `consult--read' and push it."
(interactive)
(assoc key table))))
(type (button-type button))
(action (button-get button 'action)))
- (if type
- (format "%32S #'%S" type action)
- (when action (format "#'%S" action))))))
+ (esy/inline
+ (if type
+ (format "%32S #'%S"
+ type
+ action)
+ (when action (format "#'%S" action)))))))
:sort nil)))
(user-error "No buttons found in current buffer"))))