From 191ab165afa75fcda88ea0ebe77928ce4bd684f2 Mon Sep 17 00:00:00 2001 From: Chris Cochrun Date: Fri, 10 Dec 2021 07:12:57 -0600 Subject: [PATCH] Adding a lot of agenda and elfeed tweaks --- README.org | 35 +++++++++++++++++++++++++++++++++++ init.el | 35 +++++++++++++++++++++++++++++++++++ 2 files changed, 70 insertions(+) diff --git a/README.org b/README.org index 97ff1b02..7b394fe9 100644 --- a/README.org +++ b/README.org @@ -1085,6 +1085,16 @@ Let's start by creating a self contained function of what I'd like started on ev (variable-pitch-mode +1) (setq visual-fill-column-width 100 visual-fill-column-center-text t)) + +(defun chris/org-agenda-setup () + (interactive) + (org-indent-mode +1) + (toc-org-mode +1) + (visual-fill-column-mode +1) + (display-line-numbers-mode -1) + (variable-pitch-mode -1) + (setq visual-fill-column-width 120 + visual-fill-column-center-text t)) #+end_src This is the use-package definition with a lot of customization. Need to setup auto tangle and make sure I have some structure templates for org-mode. @@ -1164,8 +1174,18 @@ Part of this config includes some special capture templates for my work as a you "* %U %?\n %i\n %a" :heading "Changelog" :prepend t)) org-capture-use-agenda-date t org-agenda-timegrid-use-ampm t + org-agenda-show-inherited-tags nil org-agenda-tags-column -100) + (setq org-agenda-prefix-format '((agenda . " %i %?-12t% s") + (todo . " %i %-12:c") + (tags . " %i %-12:c") + (search . " %i %-12:c"))) + + (setq org-agenda-category-icon-alist + '(("todo" "~/org/icons/task.png" nil nil :ascent center) + ("lesson" "~/org/icons/book.png" nil nil :ascent center))) + (setq org-imenu-depth 4 org-odt-styles-file "/home/chris/org/style.odt" org-export-with-toc nil @@ -1204,6 +1224,7 @@ Part of this config includes some special capture templates for my work as a you (setq visual-fill-column-width 100)) (add-hook 'org-agenda-finalize-hook 'evil-normal-state) + (add-hook 'org-agenda-finalize-hook 'chris/org-agenda-setup) ;;Let's make sure org-mode faces are inheriting fixed pitch faces. (dolist (face '(org-block @@ -2080,6 +2101,20 @@ interfere with the default `bongo-playlist-buffer'." (setq elfeed-search-filter "@6-days-ago +unread") + (defun chris/elfeed-ui-setup () + (display-line-numbers-mode -1) + (toggle-truncate-lines +1)) + + (defun chris/elfeed-show-ui-setup () + (display-line-numbers-mode -1) + (setq visual-fill-column-width 130 + visual-fill-column-center-text t) + (toggle-truncate-lines -1) + (visual-fill-column-mode +1)) + + (add-hook 'elfeed-search-mode-hook 'chris/elfeed-ui-setup) + (add-hook 'elfeed-show-mode-hook 'chris/elfeed-show-ui-setup) + :general (chris/leader-keys :states 'normal diff --git a/init.el b/init.el index 12b1273a..c5119f94 100644 --- a/init.el +++ b/init.el @@ -636,6 +636,16 @@ vertically." (setq visual-fill-column-width 100 visual-fill-column-center-text t)) +(defun chris/org-agenda-setup () + (interactive) + (org-indent-mode +1) + (toc-org-mode +1) + (visual-fill-column-mode +1) + (display-line-numbers-mode -1) + (variable-pitch-mode -1) + (setq visual-fill-column-width 120 + visual-fill-column-center-text t)) + (use-package org :straight t :defer 1 @@ -709,8 +719,18 @@ vertically." "* %U %?\n %i\n %a" :heading "Changelog" :prepend t)) org-capture-use-agenda-date t org-agenda-timegrid-use-ampm t + org-agenda-show-inherited-tags nil org-agenda-tags-column -100) + (setq org-agenda-prefix-format '((agenda . " %i %?-12t% s") + (todo . " %i %-12:c") + (tags . " %i %-12:c") + (search . " %i %-12:c"))) + + (setq org-agenda-category-icon-alist + '(("todo" "~/org/icons/task.png" nil nil :ascent center) + ("lesson" "~/org/icons/book.png" nil nil :ascent center))) + (setq org-imenu-depth 4 org-odt-styles-file "/home/chris/org/style.odt" org-export-with-toc nil @@ -749,6 +769,7 @@ vertically." (setq visual-fill-column-width 100)) (add-hook 'org-agenda-finalize-hook 'evil-normal-state) + (add-hook 'org-agenda-finalize-hook 'chris/org-agenda-setup) ;;Let's make sure org-mode faces are inheriting fixed pitch faces. (dolist (face '(org-block @@ -1527,6 +1548,20 @@ interfere with the default `bongo-playlist-buffer'." (setq elfeed-search-filter "@6-days-ago +unread") + (defun chris/elfeed-ui-setup () + (display-line-numbers-mode -1) + (toggle-truncate-lines +1)) + + (defun chris/elfeed-show-ui-setup () + (display-line-numbers-mode -1) + (setq visual-fill-column-width 130 + visual-fill-column-center-text t) + (toggle-truncate-lines -1) + (visual-fill-column-mode +1)) + + (add-hook 'elfeed-search-mode-hook 'chris/elfeed-ui-setup) + (add-hook 'elfeed-show-mode-hook 'chris/elfeed-show-ui-setup) + :general (chris/leader-keys :states 'normal