[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master e2ce8ae4 3/3: Improve style/fvextra.el
From: |
Arash Esbati |
Subject: |
master e2ce8ae4 3/3: Improve style/fvextra.el |
Date: |
Fri, 7 Oct 2022 08:38:04 -0400 (EDT) |
branch: master
commit e2ce8ae4db3168d46971fea55cec21f227b74f20
Author: Arash Esbati <arash@gnu.org>
Commit: Arash Esbati <arash@gnu.org>
Improve style/fvextra.el
* style/fvextra.el: Don't require cl-lib, `cl-pushnew' isn't used.
(font-latex-set-syntactic-keywords): Declare the function.
("fvextra"): Add \Verb*? and \EscVerb*? to
`LaTeX-verbatim-macros-with-braces-local'.
Update fontification rules.
---
style/fvextra.el | 22 +++++++++++-----------
1 file changed, 11 insertions(+), 11 deletions(-)
diff --git a/style/fvextra.el b/style/fvextra.el
index 31092169..3bb11e81 100644
--- a/style/fvextra.el
+++ b/style/fvextra.el
@@ -1,6 +1,6 @@
;;; fvextra.el --- AUCTeX style for `fvextra.sty' (v1.4) -*- lexical-binding:
t; -*-
-;; Copyright (C) 2017--2021 Free Software Foundation, Inc.
+;; Copyright (C) 2017--2022 Free Software Foundation, Inc.
;; Author: Arash Esbati <arash@gnu.org>
;; Maintainer: auctex-devel@gnu.org
@@ -34,14 +34,12 @@
(require 'tex)
(require 'latex)
-;; Needed for compiling `cl-pushnew':
-(eval-when-compile
- (require 'cl-lib))
-
;; Silence the compiler:
(declare-function font-latex-add-keywords
"font-latex"
(keywords class))
+(declare-function font-latex-set-syntactic-keywords
+ "font-latex")
(declare-function LaTeX-color-definecolor-list "color" ())
(declare-function LaTeX-xcolor-definecolor-list "xcolor" ())
@@ -138,11 +136,12 @@
"FancyVerbBreakBeforeBreak"
"FancyVerbBreakAfterBreak")
- ;; Add \EscVerb*? to `LaTeX-verbatim-macros-with-braces-local':
- (add-to-list 'LaTeX-verbatim-macros-with-braces-local
- "EscVerb" t)
- (add-to-list 'LaTeX-verbatim-macros-with-braces-local
- "EscVerb*" t)
+ ;; Add \Verb*? and \EscVerb*? to
+ ;; `LaTeX-verbatim-macros-with-braces-local':
+ (let ((macs '("Verb" "Verb*"
+ "EscVerb" "EscVerb*")))
+ (dolist (mac macs)
+ (add-to-list 'LaTeX-verbatim-macros-with-braces-local mac t)))
;; Fontification
(when (and (fboundp 'font-latex-add-keywords)
@@ -150,7 +149,8 @@
(font-latex-add-keywords '(("fvinlineset" "{"))
'function)
(font-latex-add-keywords '(("EscVerb" "*["))
- 'textual)))
+ 'textual)
+ (font-latex-set-syntactic-keywords)))
TeX-dialect)
(defvar LaTeX-fvextra-package-options nil
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- master e2ce8ae4 3/3: Improve style/fvextra.el,
Arash Esbati <=