Configure lexic

This commit is contained in:
Gerard Vermeulen 2022-05-22 14:54:12 +02:00
parent ca620eb080
commit b1be7a4ed9
1 changed files with 29 additions and 0 deletions

View File

@ -2643,6 +2643,35 @@ non-interactive =org-element= functions to an =Emacs-lisp= buffer.
:CUSTOM_ID: sec:writing-tools
:END:
*** [[https://github.com/tecosaur/lexic#readme][Emacs LEXICal information viewer]]
:PROPERTIES:
:CUSTOM_ID: sec:writing-lexic
:END:
The [[https://github.com/tecosaur/lexic#readme][Emacs LEXICal information viewer]] is a front-end for offline dictionary,
etymology, or thesaurus back-ends (current limited to [[https://en.wikipedia.org/wiki/Sdcv][sdcv]]). Listing
[[lst:configure-lexic]] configures [[https://github.com/tecosaur/lexic#readme][lexic]].
#+caption[Configure =lexic=]:
#+caption: Configure =lexic=.
#+name: lst:configure-lexic
#+begin_src emacs-lisp
(when (ensure-package-installation 'lexic)
;; http://download.huzheng.org/dict.org/stardict-dictd-web1913-2.4.2.tar.bz2
;; http://download.huzheng.org/dict.org/stardict-dictd_www.dict.org_gcide-2.4.2.tar.bz2
(with-eval-after-load 'lexic
(if-let ((lpp (executable-find "sdcv")))
(custom-set-variables
'(lexic-program-path lpp)
'(lexic-dictionary-alist '(("full" . t)))
;; sdcv --data-dir .local/share -l
'(lexic-dictionary-list
'("Webster's Revised Unabridged Dictionary (1913)"
"dictd_www.dict.org_gcide"))
'(lexic-dictionary-path "~/.local/share"))
(message "`lexic' fails to find the `sdcv' executable"))))
#+end_src
*** [[https://wordnet.princeton.edu/][Wordnet]]
:PROPERTIES:
:CUSTOM_ID: sec:writing-wordnet