[Emacs] Better LangTool configuration

This commit is contained in:
Lucien Cartier-Tilet 2022-04-06 19:44:02 +02:00
parent 67bbce62d9
commit e2a19dec6e
Signed by: phundrak
GPG Key ID: BD7789E705CB8DCA

View File

@ -5801,6 +5801,8 @@ to anything user-defined. Lets all-the-iconify this!
:PROPERTIES: :PROPERTIES:
:CUSTOM_ID: Packages-Configuration-Programming-languages-Tools-Langtool-sjr1oox0y9j0 :CUSTOM_ID: Packages-Configuration-Programming-languages-Tools-Langtool-sjr1oox0y9j0
:END: :END:
LanguageTool is a great tool for catching typos and grammatical errors
in quite a few languages.
#+begin_src emacs-lisp #+begin_src emacs-lisp
(use-package langtool (use-package langtool
:defer t :defer t
@ -5809,10 +5811,24 @@ to anything user-defined. Lets all-the-iconify this!
langtool-check-done langtool-check-done
langtool-show-message-at-point langtool-show-message-at-point
langtool-correct-buffer) langtool-correct-buffer)
:init :custom
(setq langtool-default-language "en-US") (langtool-default-language "en-US")
(langtool-mother-tongue "fr")
:config :config
(setq langtool-java-classpath "/usr/share/languagetool:/usr/share/java/languagetool/*")) (setq langtool-java-classpath (string-join '("/usr/share/languagetool"
"/usr/share/java/languagetool/*")
":"))
:general
(phundrak/leader-key
:packages 'langtool
:infix "l"
"" '(:ignore t :which-key "LangTool")
"B" #'langtool-correct-buffer
"b" #'langtool-check-buffer
"c" #'langtool-check
"d" #'langtool-check-done
"l" #'langtool-switch-default-language
"p" #'langtool-show-message-at-point))
#+end_src #+end_src
#+begin_src emacs-lisp #+begin_src emacs-lisp