Initial Commit
[packages] / xemacs-packages / auctex / style / frenchb.el
1 ;;; frenchb.el --- AUCTeX style for the `frenchb' babel option.
2
3 ;; Copyright (C) 2005 Free Software Foundation, Inc.
4
5 ;; Author: Ralf Angeli <angeli@iwi.uni-sb.de>
6 ;; Maintainer: auctex-devel@gnu.org
7 ;; Created: 2005-10-28
8 ;; Keywords: tex
9
10 ;; This file is part of AUCTeX.
11
12 ;; AUCTeX is free software; you can redistribute it and/or modify it
13 ;; under the terms of the GNU General Public License as published by
14 ;; the Free Software Foundation; either version 3, or (at your option)
15 ;; any later version.
16
17 ;; AUCTeX is distributed in the hope that it will be useful, but
18 ;; WITHOUT ANY WARRANTY; without even the implied warranty of
19 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
20 ;; General Public License for more details.
21
22 ;; You should have received a copy of the GNU General Public License
23 ;; along with AUCTeX; see the file COPYING.  If not, write to the Free
24 ;; Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
25 ;; 02110-1301, USA.
26
27 ;;; Commentary:
28
29 ;; Set up AUCTeX for editing French text.  In particular for commands
30 ;; provided by the `frenchb' option of the `babel' LaTeX package.  The
31 ;; `frenchb' option is equivalent to the `francais' option and since
32 ;; babel version 3.7j with the `french' option.  `french', however, is
33 ;; ambiguous because another package by that name made by Bernard
34 ;; Gaulle could be loaded.  In order to avoid this, either `frenchb'
35 ;; (or `francais') or `frenchle' (or `frenchPRO') should be used.  See
36 ;; the documentation of `frenchb' at
37 ;; <URL:http://daniel.flipo.free.fr/frenchb/frenchb-doc.pdf>.
38
39 ;;; Code:
40
41 (TeX-add-style-hook
42  "frenchb"
43  (lambda ()
44    (TeX-add-symbols
45     "og"
46     "fg"
47     "up"
48     "ier"
49     "iere"
50     "iers"
51     "ieres"
52     "ieme"
53     "iemes"
54     '("bsc" t)
55      "primo"
56      "secundo"
57      "tertio"
58      "quarto"
59      "No"
60      "no"
61      "degre"
62      "degres"
63      "DecimalMathComma"
64      "StandardMathComma"
65      '("nombre" "Nombre")
66      "ThinSpaceInFrenchNumbers"
67      "FrenchLayout"
68      "StandardLayout")
69    (unless (eq (car TeX-quote-language) 'override)
70      (setq TeX-quote-language
71            `("french" "\\og "
72              (lambda ()
73                (concat "\\fg"
74                        (unless (member "xspace" TeX-active-styles) "{}")))
75              ,TeX-quote-after-quote)))
76    (run-hooks 'TeX-language-fr-hook))
77  LaTeX-dialect)
78
79 ;;; frenchb.el ends here