]> git.eshelyaron.com Git - emacs.git/commitdiff
Declare markdown support iff gfm-view-mode installed
authorFelicián Németh <felician.nemeth@gmail.com>
Sat, 11 Jan 2020 18:08:59 +0000 (19:08 +0100)
committerJoão Távora <joaotavora@gmail.com>
Sat, 2 May 2020 23:52:59 +0000 (00:52 +0100)
* eglot.el (eglot-client-capabilities): Support markdown only when
gfm-view-mode is installed.

GitHub-reference: close https://github.com/joaotavora/eglot/issues/408

lisp/progmodes/eglot.el

index bdc4cd0aaab265e1efade37941b489aec4a523a5..596a82d6a8031fd4a2193517e0a7f62a4cfd2412 100644 (file)
@@ -527,7 +527,10 @@ treated as in `eglot-dbind'."
                                          :json-false))
                                     :contextSupport t)
              :hover              (list :dynamicRegistration :json-false
-                                       :contentFormat ["markdown" "plaintext"])
+                                       :contentFormat
+                                       (if (fboundp 'gfm-view-mode)
+                                           ["markdown" "plaintext"]
+                                         ["plaintext"]))
              :signatureHelp      (list :dynamicRegistration :json-false
                                        :signatureInformation
                                        `(:parameterInformation