Function: markdown-ts--fontify-latex-block
markdown-ts--fontify-latex-block is a byte-compiled function defined
in markdown-ts-mode.el.gz.
Signature
(markdown-ts--fontify-latex-block NODE OVERRIDE START END &rest _)
Documentation
Fontify latex block NODE and hide its delimiters when markup is hidden.
Skip fontification for false matches that span across paragraph boundaries.
OVERRIDE, START, and END are passed through to
treesit-fontify-with-override.
Source Code
;; Defined in /usr/src/emacs/lisp/textmodes/markdown-ts-mode.el.gz
(defun markdown-ts--fontify-latex-block (node override start end &rest _)
"Fontify latex block NODE and hide its delimiters when markup is hidden.
Skip fontification for false matches that span across paragraph boundaries.
OVERRIDE, START, and END are passed through to
`treesit-fontify-with-override'."
(when (markdown-ts--latex-block-valid-p node)
(treesit-fontify-with-override
(treesit-node-start node) (treesit-node-end node)
'markdown-ts-latex override start end)
(when markdown-ts-hide-markup
(dotimes (i (treesit-node-child-count node))
(let ((child (treesit-node-child node i)))
(when (equal (treesit-node-type child) "latex_span_delimiter")
(put-text-property (treesit-node-start child)
(treesit-node-end child)
'invisible 'markdown-ts--markup)))))))