branch: main commit d8bc65b5222a36c4e0d30a3a36db6ae58bc04231 Author: Arash Esbati <ar...@gnu.org> Commit: Arash Esbati <ar...@gnu.org>
Trim spaces around environment names * latex.el (LaTeX-auto-regexp-list): Ignore spaces around new environment names defined/modified with \NewDocumentEnvironment et al. --- latex.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/latex.el b/latex.el index f03dc1dc..bc5893e5 100644 --- a/latex.el +++ b/latex.el @@ -1833,7 +1833,7 @@ This is necessary since index entries may contain commands and stuff.") "\\\\\\(New\\|Renew\\|Provide\\|Declare\\)" "DocumentEnvironment" "[ \t\n\r]*" - "{\\([^}]+\\)}" + "{[ \t]*\\([^}]+?\\)[ \t]*}" "[ \t\n\r]*" "{\\([^}{]*\\(?:{[^}{]*\\(?:{[^}{]*\\(?:{[^}{]*}[^}{]*\\)*}[^}{]*\\)*}[^}{]*\\)*\\)}") (0 2 3 1) LaTeX-auto-xparse-environment)