diff options
| author | David Aspinall | 2002-10-29 15:50:32 +0000 |
|---|---|---|
| committer | David Aspinall | 2002-10-29 15:50:32 +0000 |
| commit | 3aa60f89a4512fd93d1ffd3564ce0b1ac0b69c42 (patch) | |
| tree | 749396214e4782d156ee7e12f2bb5280afb4f8c6 | |
| parent | 7cf9d0449961c0fbfee33757c0865047bb813047 (diff) | |
| parent | 5b39c4d1312f4c37203ed2e83324f61115f64196 (diff) | |
This commit was generated by cvs2git to track changes on a CVS vendor
branch.
| -rw-r--r-- | x-symbol/lisp/x-symbol-texi.el | 338 |
1 files changed, 338 insertions, 0 deletions
diff --git a/x-symbol/lisp/x-symbol-texi.el b/x-symbol/lisp/x-symbol-texi.el new file mode 100644 index 00000000..aab3e35e --- /dev/null +++ b/x-symbol/lisp/x-symbol-texi.el @@ -0,0 +1,338 @@ +;;; x-symbol-texi.el --- token language "TeXinfo command" for package x-symbol + +;; Copyright (C) 2000, 2002 Free Software Foundation, Inc. +;; +;; Author: Christoph Wedler <wedler@users.sourceforge.net> +;; Maintainer: (Please use `M-x x-symbol-package-bug' to contact the maintainer) +;; Version: 4.4.X +;; Keywords: WYSIWYG, TeXinfo, wp, internationalization +;; X-URL: http://x-symbol.sourceforge.net/ + +;; This program is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 2, or (at your option) +;; any later version. +;; +;; This program is distributed in the hope that it will be useful, +;; but WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;; GNU General Public License for more details. +;; +;; You should have received a copy of the GNU General Public License +;; along with this program; if not, write to the Free Software +;; Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + +;;; Commentary: + +;; If you want to use package x-symbol, please visit the URL (use +;; \\[x-symbol-package-web]) and read the info (use \\[x-symbol-package-info]). + +;; Token language tex is registered in x-symbol-hooks. + +;;; Code: + +(provide 'x-symbol-texi) + + +;;;=========================================================================== +;;; General language accesses, see `x-symbol-language-access-alist' +;;;=========================================================================== + +(defcustom x-symbol-texi-auto-style '(t nil nil nil nil nil) + "TODO" + :group 'x-symbol-texi + :group 'x-symbol-mode + :type 'x-symbol-auto-style) + +(defcustom x-symbol-texi-modeline-name "texi" + "*String naming the language TeXinfo in the modeline." + :group 'x-symbol-texi + :type 'string) + +(defcustom x-symbol-texi-header-groups-alist + '(("Symbol" bigop operator line relation arrow triangle shape white dots + punctuation quote parenthesis symbol currency mathletter setsymbol) + ("Misc. Letter" greek greek1 letter slash cedilla ogonek) + ("Dotaccent, Ring" dotaccent ring) + ("Tilde, Breve" tilde breve) + ("Circumflex, Caron" circumflex caron) + ("Diaeresis, Umlaut" diaeresis hungarumlaut) + ("Acute, Grave" acute grave)) + "*If non-nil, used in TeXinfo specific grid/menu. +See `x-symbol-header-groups-alist'." + :group 'x-symbol-texi + :group 'x-symbol-input-init + :type 'x-symbol-headers) + +(defcustom x-symbol-texi-electric-ignore nil + "*Additional TeXinfo version of `x-symbol-electric-ignore'." + :group 'x-symbol-texi + :group 'x-symbol-input-control + :type 'x-symbol-function-or-regexp) + +(defcustom x-symbol-texi-class-alist + '((aletter "acc.letter" (x-symbol-info-face)) + (symbol "symbol" (x-symbol-info-face)) + (bullet "bullet" (x-symbol-info-face)) + (no-code "not as code" (x-symbol-emph-info-face)) + (VALID "unknown TeXinfo command" (x-symbol-emph-info-face)) + (INVALID "no TeXinfo command" (x-symbol-emph-info-face))) + "Alist for TeXinfo's token classes displayed by info in echo area. +See `x-symbol-language-access-alist' for details." + :group 'x-symbol-texi + :group 'x-symbol-info-strings + :type 'x-symbol-class-info) + +(defcustom x-symbol-texi-class-face-alist nil + "Alist for TeXinfo's color scheme in TeXinfo's grid and info. +See `x-symbol-language-access-alist' for details." + :group 'x-symbol-texi + :group 'x-symbol-input-init + :group 'x-symbol-info-general + :type 'x-symbol-class-faces) + + +(defvar x-symbol-texi-token-grammar + '(x-symbol-make-grammar + :encode-spec (?@) + :decode-regexp + "@\\(?:[A-Za-z]+{[A-Za-z]?}\\|[{}]\\|[~^\"'`][A-Za-z]\\|,{[A-Za-z]}\\)" + :decode-spec (?@)) + "Token grammar for language `texi'.") + +(defvar x-symbol-texi-input-token-grammar + '("@\\(?:[A-Za-z]+{[A-Za-z]?}\\|[{}]\\|[~^\"'`][A-Za-z]\\|,{[A-Za-z]}\\)\\'" + ?@) + "Grammar of input method Token for language `texi'.") + +(defvar x-symbol-texi-user-table nil + "User table defining TeXinfo commands, used in `x-symbol-texi-table'.") + +(defvar x-symbol-texi-generated-data nil + "Internal.") + + +;;;=========================================================================== +;;; The tables +;;;=========================================================================== + +(defvar x-symbol-texi-latin1-table + '(;;(nobreakspace () "\\nobreakspace") + (exclamdown (symbol) "@exclamdown{}") + ;;(cent () "\\textcent") + (sterling (symbol) "@pounds{}") + ;;(currency () "\\textcurrency") + ;;(yen () "\\textyen") + ;;(brokenbar () "\\textbrokenbar") + ;;(section () "\\S") + ;;(diaeresis () "@\"{}") + (copyright (symbol) "@copyright{}") + ;;(ordfeminine () "\\textordfeminine") + ;;(guillemotleft () "\\guillemotleft") + ;;(notsign () "\\lnot" "\\neg") + ;;(hyphen () "\\-") + ;;(registered () "\\textregistered") + ;;(macron () "\\={}") + ;;(degree () "\\textdegree") + ;;(plusminus () "\\pm") + ;;(twosuperior () "\\mathtwosuperior") + ;;(threesuperior () "\\maththreesuperior") + ;;(acute () "@'{}") + ;;(mu1 () "\\mathmicro") + ;;(paragraph () "\\P") + ;;(periodcentered () "\\textperiodcentered") + ;;(cedilla () "@,\\ ") + ;;(onesuperior () "\\mathonesuperior") + ;;(masculine () "\\textordmasculine") + ;;(guillemotright () "\\guillemotright") + ;;(onequarter () "\\textonequarter") + ;;(onehalf () "\\textonehalf") + ;;(threequarters () "\\textthreequarters") + (questiondown (symbol) "@questiondown{}") + (Agrave (aletter) "@`A") + (Aacute (aletter) "@'A") + (Acircumflex (aletter) "@^A") + (Atilde (aletter) "@~A") + (Adiaeresis (aletter) "@\"A") + (Aring (aletter) "@AA{}") + (AE (aletter) "@AE{}") + (Ccedilla (aletter) "@,{C}") + (Egrave (aletter) "@`E") + (Eacute (aletter) "@'E") + (Ecircumflex (aletter) "@^E") + (Ediaeresis (aletter) "@\"E") + (Igrave (aletter) "@`I") + (Iacute (aletter) "@'I") + (Icircumflex (aletter) "@^I") + (Idiaeresis (aletter) "@\"I") + ;;(ETH () "\\DH") + (Ntilde (aletter) "@~N") + (Ograve (aletter) "@`O") + (Oacute (aletter) "@'O") + (Ocircumflex (aletter) "@^O") + (Otilde (aletter) "@~O") + (Odiaeresis (aletter) "@\"O") + ;;(multiply () "\\times") + (Ooblique (aletter) "@O{}") + (Ugrave (aletter) "@`U") + (Uacute (aletter) "@'U") + (Ucircumflex (aletter) "@^U") + (Udiaeresis (aletter) "@\"U") + (Yacute (aletter) "@'Y") + ;;(THORN () "\\TH") + (ssharp (aletter) "@ss{}") + (agrave (aletter) "@`a") + (aacute (aletter) "@'a") + (acircumflex (aletter) "@^a") + (atilde (aletter) "@~a") + (adiaeresis (aletter) "@\"a") + (aring (aletter) "@aa{}") + (ae (aletter) "@ae{}") + (ccedilla (aletter) "@,{c}") + (egrave (aletter) "@`e") + (eacute (aletter) "@'e") + (ecircumflex (aletter) "@^e") + (ediaeresis (aletter) "@\"e") + (igrave (aletter) "@`i") + (iacute (aletter) "@'i") + (icircumflex (aletter) "@^i") + (idiaeresis (aletter) "@\"i") ; TeX should used dotless-i + ;;(eth () "\\dh") + (ntilde (aletter) "@~n") + (ograve (aletter) "@`o") + (oacute (aletter) "@'o") + (ocircumflex (aletter) "@^o") + (otilde (aletter) "@~o") + (odiaeresis (aletter) "@\"o") + ;;(division () "\\div") + (oslash (aletter) "@o{}") + (ugrave (aletter) "@`u") + (uacute (aletter) "@'u") + (ucircumflex (aletter) "@^u") + (udiaeresis (aletter) "@\"u") + (yacute (aletter) "@'y") + ;;(thorn () "\\th") + (ydiaeresis (aletter) "@\"y")) + "Table defining TeXinfo commands, see `x-symbol-texi-table'.") + +(defvar x-symbol-texi-latinN-table + '(;;(Aogonek () "\\k A") + ;;(breve () "@u{}") + (Lslash (aletter) "@L{}") + (Lcaron (aletter) "@v{L}") ; TeX should use T1 fontenc + (Sacute (aletter) "@'S") + (Scaron (aletter) "@v{S}") + (Scedilla (aletter) "@,{S}") + (Tcaron (aletter) "@v{T}") + (Zacute (aletter) "@'Z") + (Zcaron (aletter) "@v{Z}") + (Zdotaccent (aletter) "@dotaccent{Z}") + ;;(aogonek () "\\k a") + ;;(ogonek () "\\k\\ ") + (lslash (aletter) "@l{}") + (lcaron (aletter) "@v{l}") ; TeX should use T1 fontenc + (sacute (aletter) "@'s") + ;;(caron () "\\v{}") + (scaron (aletter) "@v{s}") + (scedilla (aletter) "@,{s}") + (tcaron (aletter) "@v{t}") ; TeX should use T1 fontenc + (zacute (aletter) "@'z") + ;;(hungarumlaut () "@H{}") + (zcaron (aletter) "@v{z}") + (zdotaccent (aletter) "@dotaccent{z}") + (Racute (aletter) "@'R") + (Abreve (aletter) "@u{A}") + (Lacute (aletter) "@'L") + (Cacute (aletter) "@'C") + (Ccaron (aletter) "@v{C}") + ;;(Eogonek () "\\k E") + (Ecaron (aletter) "@v{E}") + (Dcaron (aletter) "@v{D}") + ;;(Dbar () "\\DJ") + (Nacute (aletter) "@'N") + (Ncaron (aletter) "@v{N}") + (Ohungarumlaut (aletter) "@H{O}") + (Rcaron (aletter) "@v{R}") + (Uring (aletter) "@ringaccent{U}") + (Uhungarumlaut (aletter) "@H{U}") + (Tcedilla (aletter) "@,{T}") + (racute (aletter) "@'r") + (abreve (aletter) "@u{a}") + (lacute (aletter) "@'l") + (cacute (aletter) "@'c") + (ccaron (aletter) "@v{c}") + ;;(eogonek () "\\k e") + (ecaron (aletter) "@v{e}") + (dcaron (aletter) "@v{d}") ; TeX should use T1 fontenc + ;;(dbar () "\\dj") + (nacute (aletter) "@'n") + (ncaron (aletter) "@v{n}") + (ohungarumlaut (aletter) "@H{o}") + (rcaron (aletter) "@v{r}") + (uring (aletter) "@ringaccent{u}") + (uhungarumlaut (aletter) "@H{u}") + (tcedilla (aletter) "@,{t}") + ;;(dotaccent () "@dotaccent{}") + ;;(Hbar () "\\textmalteseH") + (Hcircumflex (aletter) "@^H") + (Idotaccent (aletter) "@dotaccent{I}") + (Gbreve (aletter) "@u{G}") + (Jcircumflex (aletter) "@^J") + ;;(hbar () "\\textmalteseh") + (hcircumflex (aletter) "@^h") + (dotlessi (aletter) "@dotless{i}") + (gbreve (aletter) "@u{g}") + (jcircumflex (aletter) "@^j") + (Cdotaccent (aletter) "@dotaccent{C}") + (Ccircumflex (aletter) "@^C") + (Gdotaccent (aletter) "@dotaccent{G}") + (Gcircumflex (aletter) "@^G") + (Ubreve (aletter) "@u{U}") + (Scircumflex (aletter) "@^S") + (cdotaccent (aletter) "@dotaccent{c}") + (ccircumflex (aletter) "@^c") + (gdotaccent (aletter) "@dotaccent{g}") + (gcircumflex (aletter) "@^g") + (ubreve (aletter) "@u{u}") + (scircumflex (aletter) "@^s") + (OE (aletter) "@OE{}") + (oe (aletter) "@oe{}") + (Ydiaeresis (aletter) "@\"Y")) + "Table defining TeXinfo commands, see `x-symbol-texi-table'.") + +(defvar x-symbol-texi-xsymbX-table + '((bullet (bullet) "@bullet{}") + (equivalence (symbol) "@equiv{}") + (ellipsis (symbol) "@dots{}") + (arrowdblright (symbol) "@result{}") + ;;(NG () "\\NG") + (dotlessj (aletter) "@dotless{j}") + ;;(ng () "\\ng") + (star (symbol) "@point{}") + (braceleft2 (symbol) "@{") + (braceright2 (symbol) "@}") + (mapsto (symbol) "@expansion{}") + (dashbar (symbol) "@print{}") + ;;(grave () "@`{}") + ;;(circumflex () "@^{}") + ;;(tilde () "@~{}") + (endash (bullet no-code) "@minus{}") + ;;(emdash () "\\textemdash") + ;;(at2 () "@@") + ;;(endellipsis () "enddots{}") + ;;(error () "error{}") + ) + "Table defining TeXinfo commands, see `x-symbol-texi-table'.") + +(defvar x-symbol-texi-table + (append x-symbol-texi-user-table + '(nil) + x-symbol-texi-latin1-table + x-symbol-texi-latinN-table + x-symbol-texi-xsymbX-table) + "Complete table defining TeXinfo commands. +Use `x-symbol-texi-user-table' to define/shadow private TeXinfo commands. +See `x-symbol-init-language' and `x-symbol-texi-token-list'.") + +;;; Local IspellPersDict: .ispell_xsymb +;;; x-symbol-texi.el ends here |
