From 3481584b4e93687349924b537c89275da8c4b888 Mon Sep 17 00:00:00 2001 From: larstvei Date: Mon, 12 Jun 2023 02:42:32 +0200 Subject: [PATCH] use-package focus --- init.org | 27 +++++++++++++++++++-------- 1 file changed, 19 insertions(+), 8 deletions(-) diff --git a/init.org b/init.org index 1993cdc..6993d44 100644 --- a/init.org +++ b/init.org @@ -207,8 +207,7 @@ (let* ((package--builtins nil) (packages - '(focus ; Dim color of text in surrounding sections - go-mode ; Major mode for the Go programming language + '(go-mode ; Major mode for the Go programming language haskell-mode ; A Haskell editing mode lua-mode ; a major-mode for editing Lua scripts markdown-mode ; Emacs Major mode for Markdown-formatted files @@ -555,6 +554,24 @@ #+end_src +** Focusing with focus + + [[https://github.com/larstvei/Focus][Focus]] is my own package. It looks pretty nice, especially in combination + with Olivetti! + + #+begin_src emacs-lisp + + ;; Dim color of text in surrounding sections + (use-package focus + :defer t + :bind ("C-c q" . + (lambda () + (interactive) + (focus-mode 1) + (focus-read-only-mode 1)))) + + #+end_src + * Version control Magit is the best. @@ -1739,12 +1756,6 @@ (define-key custom-bindings-map (kbd key) (lambda () (interactive) (switch-vterm n))))) - (define-key custom-bindings-map (kbd "C-c C-q") - '(lambda () - (interactive) - (focus-mode 1) - (focus-read-only-mode 1))) - (with-eval-after-load 'org (define-key org-mode-map (kbd "C-'") 'org-sync-pdf))