branch: externals/elpa
commit a2fa9ab17bd6db709bf7feb071912144eede3949
Author: João Távora <[email protected]>
Commit: João Távora <[email protected]>
Per #408: fontify markdown source code blocks by default
* eglot.el (eglot--format-markup): Set
markdown-fontify-code-blocks-natively to t locally.
---
eglot.el | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/eglot.el b/eglot.el
index 596a82d..22a8aef 100644
--- a/eglot.el
+++ b/eglot.el
@@ -72,7 +72,9 @@
(require 'filenotify)
(require 'ert)
(require 'array)
-(defvar company-backends) ; forward-declare, but don't require company
+;; forward-declare, but don't require (Emacs 28 doesn't seem to care)
+(defvar markdown-fontify-code-blocks-natively)
+(defvar company-backends)
(defvar company-tooltip-align-annotations)
@@ -1149,6 +1151,7 @@ Doubles as an indicator of snippet support."
("plaintext" 'text-mode)
(_ major-mode))))))
(with-temp-buffer
+ (setq-local markdown-fontify-code-blocks-natively t)
(insert (string-trim string))
(ignore-errors (delay-mode-hooks (funcall mode)))
(font-lock-ensure)