/[auctex]/auctex/font-latex.el
ViewVC logotype

Diff of /auctex/font-latex.el

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 5.126 by angeli, Mon Jun 20 13:47:44 2005 UTC revision 5.127 by angeli, Wed Jun 29 17:35:11 2005 UTC
# Line 100  buffers controlled by font-latex or rest Line 100  buffers controlled by font-latex or rest
100    
101  (defcustom font-latex-quotes 'french  (defcustom font-latex-quotes 'french
102    "Whether to fontify << French quotes >> or >>German quotes<<.    "Whether to fontify << French quotes >> or >>German quotes<<.
103  Also selects \"<quote\"> versus \">quote\"<.  Also selects \"<quote\"> versus \">quote\"<."
   
 Setting this variable directly does not take effect;  
 use \\[customize]."  
104    :type '(choice (const french) (const german))    :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)))  
105    :group 'font-latex)    :group 'font-latex)
106    
107    (defvar font-latex-quotes-control font-latex-quotes
108      "Internal variable for keeping track if `font-latex-quotes' changed.")
109    
110  ;; The definitions of the title faces were originally taken from  ;; The definitions of the title faces were originally taken from
111  ;; info.el (Copyright (C) 1985, 86, 92, 93, 94, 95, 96, 97, 98, 99,  ;; info.el (Copyright (C) 1985, 86, 92, 93, 94, 95, 96, 97, 98, 99,
112  ;; 2000, 2001 Free Software Foundation, Inc.) and adapted to the needs  ;; 2000, 2001 Free Software Foundation, Inc.) and adapted to the needs
# Line 1428  Used for patterns like: Line 1417  Used for patterns like:
1417  \"< french \"> and \"`german\"' quotes.  \"< french \"> and \"`german\"' quotes.
1418  The quotes << french >> and 8-bit french are used if `font-latex-quotes' is  The quotes << french >> and 8-bit french are used if `font-latex-quotes' is
1419  set to french, and >> german << (and 8-bit) are used if set to german."  set to french, and >> german << (and 8-bit) are used if set to german."
1420      ;; Update quotes list and regexp if value of `font-latex-quotes' changed.
1421      (unless (eq font-latex-quotes-control font-latex-quotes)
1422        (setq font-latex-quotes-control font-latex-quotes)
1423        (if (eq font-latex-quotes 'french)
1424            (setq font-latex-quote-list
1425                  '(("``" . "''")  ("\"`" . "\"'")
1426                    ("\"<" . "\">") ("<<" . ">>") ("«" . "»")))
1427          (setq font-latex-quote-list
1428                '(("``" . "''") ("\"`" . "\"'")
1429                  ("\">" . "\"<") (">>" . "<<") ("»" . "«"))))
1430        (setq font-latex-quote-regexp-beg
1431              (regexp-opt (mapcar 'car font-latex-quote-list) t)))
1432      ;; Search for matches.
1433    (when (re-search-forward font-latex-quote-regexp-beg limit t)    (when (re-search-forward font-latex-quote-regexp-beg limit t)
1434      (let ((beg (match-beginning 0)))      (let ((beg (match-beginning 0)))
1435        (search-forward (cdr (assoc (match-string 0) font-latex-quote-list))        (search-forward (cdr (assoc (match-string 0) font-latex-quote-list))

Legend:
Removed from v.5.126  
changed lines
  Added in v.5.127

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26