]> git.eshelyaron.com Git - emacs.git/commitdiff
Tweak href/superscript fix in tex-mode
authorLars Ingebrigtsen <larsi@gnus.org>
Thu, 27 Jan 2022 15:30:12 +0000 (16:30 +0100)
committerLars Ingebrigtsen <larsi@gnus.org>
Thu, 27 Jan 2022 15:30:12 +0000 (16:30 +0100)
* lisp/textmodes/tex-mode.el (tex-font-lock-keywords-1): Fix
superscripts in href in a better way.

lisp/textmodes/tex-mode.el

index f41cc2c15eda9608223840e2922f24b222af758b..ab94036d01d18b79cddf91494530fc99920f31b6 100644 (file)
@@ -505,7 +505,9 @@ An alternative value is \" . \", if you use a font with a narrow period."
                        "documentstyle" "documentclass" "verbatiminput"
                        "includegraphics" "includegraphics*")
                      t))
-           (verbish (regexp-opt '("url" "nolinkurl" "path") t))
+           (verbish (regexp-opt '("url" "nolinkurl" "path"
+                                  "href" "ProvidesFile")
+                                t))
           ;; Miscellany.
           (slash "\\\\")
           (opt " *\\(\\[[^]]*\\] *\\)*")
@@ -578,9 +580,6 @@ An alternative value is \" . \", if you use a font with a narrow period."
                          ;; "caption" "footnote" "footnotemark" "footnotetext"
                          )
                        t))
-           (file-like (regexp-opt
-                       '("href" "ProvidesFile")
-                       t))
            ;;
            ;; Names of commands that should be fontified.
            (specials-1 (regexp-opt '("\\" "\\*") t)) ;; "-"
@@ -601,8 +600,6 @@ An alternative value is \" . \", if you use a font with a narrow period."
        ;;
        ;; Citation args.
        (list (concat slash citations opt arg) 3 'font-lock-constant-face)
-       ;; File-like args.
-       (list (concat slash file-like opt arg) 3 'font-lock-constant-face)
        ;;
         ;; Text between `` quotes ''.
         (list (concat (regexp-opt '("``" "\"<" "\"`" "<<" "«") t)