Update org-glossary and config
This commit is contained in:
parent
e9ced0edd4
commit
0f3bfc872e
21
config.org
21
config.org
|
@ -5594,13 +5594,32 @@ to make that right again, and this package makes that even easier to do.
|
|||
|
||||
***** Glossaries and more
|
||||
|
||||
For glossary-type entries, there's a nice package for this I'm developing.
|
||||
|
||||
#+begin_src emacs-lisp
|
||||
(package! org-glossary :recipe (:local-repo "lisp/org-glossary"))
|
||||
#+end_src
|
||||
|
||||
Other than hooking this to =org-mode=, we also want to set a collection root and
|
||||
improve the LaTeX usage references with =cleveref='s ~\labelcpageref~ command.
|
||||
|
||||
#+begin_src emacs-lisp :tangle yes
|
||||
(use-package! org-glossary
|
||||
:hook (org-mode . org-glossary-mode))
|
||||
:hook (org-mode . org-glossary-mode)
|
||||
:config
|
||||
(setq org-glossary-collection-root "~/.config/doom/misc/glossaries/")
|
||||
(defun +org-glossary--latex-cdef (backend info term-entry form &optional ref-index plural-p capitalized-p extra-parameters)
|
||||
(org-glossary--export-template
|
||||
(if (plist-get term-entry :uses)
|
||||
"*%d*\\emsp{}%v\\ensp{}@@latex:\\labelcpageref{@@%b@@latex:}@@\n"
|
||||
"*%d*\\emsp{}%v\n")
|
||||
backend info term-entry ref-index
|
||||
plural-p capitalized-p extra-parameters))
|
||||
(org-glossary-set-export-spec
|
||||
'latex t
|
||||
:backref "gls-%K-use-%r"
|
||||
:backref-seperator ","
|
||||
:definition-structure #'+org-glossary--latex-cdef))
|
||||
#+end_src
|
||||
|
||||
***** Document comparison
|
||||
|
|
|
@ -1 +1 @@
|
|||
Subproject commit c520d66cd86fce4154d2dcf42c7669146425bd89
|
||||
Subproject commit b2b53e82468feda2d0b68d3b30bdbe4c06dc815d
|
Loading…
Reference in New Issue