[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[AUCTeX-diffs] Changes to auctex/font-latex.el
From: |
Ralf Angeli |
Subject: |
[AUCTeX-diffs] Changes to auctex/font-latex.el |
Date: |
Wed, 29 Jun 2005 13:35:12 -0400 |
Index: auctex/font-latex.el
diff -u auctex/font-latex.el:5.126 auctex/font-latex.el:5.127
--- auctex/font-latex.el:5.126 Mon Jun 20 13:47:44 2005
+++ auctex/font-latex.el Wed Jun 29 17:35:11 2005
@@ -100,24 +100,13 @@
(defcustom font-latex-quotes 'french
"Whether to fontify << French quotes >> or >>German quotes<<.
-Also selects \"<quote\"> versus \">quote\"<.
-
-Setting this variable directly does not take effect;
-use \\[customize]."
+Also selects \"<quote\"> versus \">quote\"<."
:type '(choice (const french) (const german))
- :set (lambda (symbol value)
- (set-default symbol value)
- (if (equal value 'french)
- (setq font-latex-quote-list
- '(("``" . "''") ("\"`" . "\"'")
- ("\"<" . "\">") ("<<" . ">>") ("«" . "»")))
- (setq font-latex-quote-list
- '(("``" . "''") ("\"`" . "\"'")
- ("\">" . "\"<") (">>" . "<<") ("»" . "«"))))
- (setq font-latex-quote-regexp-beg
- (regexp-opt (mapcar 'car font-latex-quote-list) t)))
:group 'font-latex)
+(defvar font-latex-quotes-control font-latex-quotes
+ "Internal variable for keeping track if `font-latex-quotes' changed.")
+
;; The definitions of the title faces were originally taken from
;; info.el (Copyright (C) 1985, 86, 92, 93, 94, 95, 96, 97, 98, 99,
;; 2000, 2001 Free Software Foundation, Inc.) and adapted to the needs
@@ -1428,6 +1417,19 @@
\"< french \"> and \"`german\"' quotes.
The quotes << french >> and 8-bit french are used if `font-latex-quotes' is
set to french, and >> german << (and 8-bit) are used if set to german."
+ ;; Update quotes list and regexp if value of `font-latex-quotes' changed.
+ (unless (eq font-latex-quotes-control font-latex-quotes)
+ (setq font-latex-quotes-control font-latex-quotes)
+ (if (eq font-latex-quotes 'french)
+ (setq font-latex-quote-list
+ '(("``" . "''") ("\"`" . "\"'")
+ ("\"<" . "\">") ("<<" . ">>") ("«" . "»")))
+ (setq font-latex-quote-list
+ '(("``" . "''") ("\"`" . "\"'")
+ ("\">" . "\"<") (">>" . "<<") ("»" . "«"))))
+ (setq font-latex-quote-regexp-beg
+ (regexp-opt (mapcar 'car font-latex-quote-list) t)))
+ ;; Search for matches.
(when (re-search-forward font-latex-quote-regexp-beg limit t)
(let ((beg (match-beginning 0)))
(search-forward (cdr (assoc (match-string 0) font-latex-quote-list))
- [AUCTeX-diffs] Changes to auctex/font-latex.el, Ralf Angeli, 2005/06/05
- [AUCTeX-diffs] Changes to auctex/font-latex.el, Ralf Angeli, 2005/06/05
- [AUCTeX-diffs] Changes to auctex/font-latex.el, Ralf Angeli, 2005/06/05
- [AUCTeX-diffs] Changes to auctex/font-latex.el, Ralf Angeli, 2005/06/07
- [AUCTeX-diffs] Changes to auctex/font-latex.el, Ralf Angeli, 2005/06/20
- [AUCTeX-diffs] Changes to auctex/font-latex.el, Ralf Angeli, 2005/06/20
- [AUCTeX-diffs] Changes to auctex/font-latex.el,
Ralf Angeli <=
- [AUCTeX-diffs] Changes to auctex/font-latex.el, Ralf Angeli, 2005/06/29