about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--config.org27
1 files changed, 27 insertions, 0 deletions
diff --git a/config.org b/config.org index 9abef66..3d83c54 100644 --- a/config.org +++ b/config.org
@@ -1828,6 +1828,33 @@ I want to use the newest version of Org that I can.
1828 (add-hook 'org-mode-hook #'acdw/org-mode-prettify) 1828 (add-hook 'org-mode-hook #'acdw/org-mode-prettify)
1829#+end_src 1829#+end_src
1830 1830
1831*** Prettify lists and checkboxes using font-lock
1832
1833from [[https://github.com/KaratasFurkan/.emacs.d#org-1][Furkan Karataş]].
1834
1835#+begin_src emacs-lisp :noweb-ref modes
1836 (with-eval-after-load 'org
1837 (font-lock-add-keywords 'org-mode
1838 '(("^ *\\([-]\\) "
1839 (0 (prog1 ()
1840 (compose-region (match-beginning 1) (match-end 1) "•"))))))
1841 (font-lock-add-keywords 'org-mode
1842 '(("^ *\\([+]\\) "
1843 (0 (prog1 ()
1844 (compose-region (match-beginning 1) (match-end 1) "◦"))))))
1845
1846 (defface org-checkbox-done-text
1847 '((t (:inherit 'font-lock-comment-face :slant normal)))
1848 "Face for the text part of a checked org-mode checkbox."
1849 :group 'org)
1850
1851 (font-lock-add-keywords
1852 'org-mode
1853 `(("^[ \t]*\\(?:[-+*]\\|[0-9]+[).]\\)[ \t]+\\(\\(?:\\[@\\(?:start:\\)?[0-9]+\\][ \t]*\\)?\\[\\(?:X\\|\\([0-9]+\\)/\\2\\)\\][^\n]*\n\\)"
1854 1 'org-checkbox-done-text prepend))
1855 'append))
1856#+end_src
1857
1831** Org templates 1858** Org templates
1832 1859
1833#+begin_src emacs-lisp :noweb-ref settings 1860#+begin_src emacs-lisp :noweb-ref settings