From ce1f53ebaf07e1fe4710ad1bad1d6342e849d6b5 Mon Sep 17 00:00:00 2001 From: noa@gaiwan.org Date: Fri, 14 Jun 2024 07:35:37 +0000 Subject: Add hooks to enable visual-line-fill-column-mode --- emacs/init.el | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'emacs/init.el') diff --git a/emacs/init.el b/emacs/init.el index ac0f18a..8a002f7 100644 --- a/emacs/init.el +++ b/emacs/init.el @@ -420,14 +420,17 @@ The misspelled word is taken from OVERLAY. WORD is the corrected word." (use-package visual-fill-column :ensure t) (setopt visual-fill-column-enable-sensible-window-split t) (setopt visual-fill-column-center-text t) -(add-hook 'text-mode-hook #'visual-line-fill-column-mode) (advice-add 'text-scale-adjust :after #'visual-fill-column-adjust) +(add-hook 'text-mode-hook #'visual-line-fill-column-mode) +(add-hook 'eww-after-render-hook #'visual-line-fill-column-mode) +(add-hook 'nov-post-html-render-hook #'visual-line-fill-column-mode) +(add-hook 'mu4e-view-mode-hook #'visual-line-fill-column-mode) + ;; This works... fine. However it's adapting the prefix, it doesn't indent nicely with proportional fonts, but you can't win them all. (use-package adaptive-wrap :ensure t) (add-hook 'visual-fill-column-mode-hook #'adaptive-wrap-prefix-mode) - (setopt ffap-file-name-with-spaces t) (global-set-key [remap find-file] #'find-file-at-point) (global-set-key [remap dired] #'dired-at-point) -- cgit 1.4.1-2-gfad0