]> git.lyx.org Git - lyx.git/blob - src/frontends/controllers/ControlMath.C
fix rbearing
[lyx.git] / src / frontends / controllers / ControlMath.C
1 /**
2  * \file ControlMath.C
3  * This file is part of LyX, the document processor.
4  * Licence details can be found in the file COPYING.
5  *
6  * \author Alejandro Aguilar Sierra
7  * \author John Levon
8  *
9  * Full author contact details are available in file CREDITS
10  */
11
12 #include "ControlMath.h"
13
14 char const * function_names[] = {
15         "arccos", "arcsin", "arctan", "arg", "bmod",
16         "cos", "cosh", "cot", "coth", "csc", "deg",
17         "det", "dim", "exp", "gcd", "hom", "inf", "ker",
18         "lg", "lim", "liminf", "limsup", "ln", "log",
19         "max", "min", "sec", "sin", "sinh", "sup",
20         "tan", "tanh", ""
21 };
22
23 int const nr_function_names = sizeof(function_names) / sizeof(char const *) - 1;
24
25 char const * latex_dots[] = {
26         "ldots", "cdots", "vdots", "ddots", ""
27 };
28
29 int const nr_latex_dots = sizeof(latex_dots) / sizeof(char const *) - 1;
30
31 char const * latex_deco[] = {
32         "widehat", "widetilde", "overbrace", "overleftarrow", "overrightarrow",
33         "overline", "underbrace", "underline", "underleftarrow", "underrightarrow",
34         "underleftrightarrow", "overleftrightarrow",
35         "hat", "acute", "bar", "dot",
36         "check", "grave", "vec", "ddot",
37         "breve", "tilde", ""
38 };
39
40 int const nr_latex_deco = sizeof(latex_deco) / sizeof(char const *) - 1;
41
42 char const * latex_arrow[] = {
43         "downarrow", "leftarrow", "Downarrow", "Leftarrow",
44         "hookleftarrow", "rightarrow", "uparrow", "Rightarrow", "Uparrow",
45         "hookrightarrow", "updownarrow", "Leftrightarrow", "leftharpoonup",
46         "rightharpoonup", "rightleftharpoons", "leftrightarrow", "Updownarrow",
47         "leftharpoondown", "rightharpoondown", "mapsto",
48         "Longleftarrow", "Longrightarrow", "Longleftrightarrow",
49         "longleftrightarrow", "longleftarrow", "longrightarrow", "longmapsto",
50         "nwarrow", "nearrow", "swarrow", "searrow",  "",
51 };
52
53 int const nr_latex_arrow = sizeof(latex_arrow) / sizeof(char const *);
54
55 char const * latex_bop[] = {
56         "pm", "cap", "diamond", "oplus",
57         "mp", "cup", "bigtriangleup", "ominus",
58         "times", "uplus", "bigtriangledown", "otimes",
59         "div", "sqcap", "triangleright", "oslash",
60         "cdot", "sqcup", "triangleleft", "odot",
61         "star", "vee", "amalg", "bigcirc",
62         "setminus", "wedge", "dagger", "circ",
63         "bullet", "wr", "ddagger", ""
64 };
65
66 int const nr_latex_bop = sizeof(latex_bop) / sizeof(char const *);
67
68 char const * latex_brel[] = {
69         "leq", "geq", "equiv", "models",
70         "prec", "succ", "sim", "perp",
71         "preceq", "succeq", "simeq", "mid",
72         "ll", "gg", "asymp", "parallel",
73         "subset", "supset", "approx", "smile",
74         "subseteq", "supseteq", "cong", "frown",
75         "sqsubseteq", "sqsupseteq", "doteq", "neq",
76         "in", "ni", "propto", "notin",
77         "vdash", "dashv", "bowtie", ""
78 };
79
80 int const nr_latex_brel = sizeof(latex_brel) / sizeof(char const *);
81
82 char const * latex_greek[] = {
83         "Gamma", "Delta", "Theta", "Lambda", "Xi", "Pi",
84         "Sigma", "Upsilon", "Phi", "Psi", "Omega",
85         "alpha", "beta", "gamma", "delta", "epsilon", "varepsilon", "zeta",
86         "eta", "theta", "vartheta", "iota", "kappa", "lambda", "mu",
87         "nu", "xi", "pi", "varpi", "rho", "sigma", "varsigma",
88         "tau", "upsilon", "phi", "varphi", "chi", "psi", "omega", ""
89 };
90
91 int const nr_latex_greek = sizeof(latex_greek) / sizeof(char const *);
92
93 char const * latex_misc[] = {
94         "nabla", "partial", "infty", "prime", "ell",
95         "emptyset", "exists", "forall", "imath",  "jmath",
96         "Re", "Im", "aleph", "wp", "hbar",
97         "angle", "top", "bot", "Vert", "neg",
98         "flat", "natural", "sharp", "surd", "triangle",
99         "diamondsuit", "heartsuit", "clubsuit", "spadesuit",
100         "textrm Å", "textrm Ø", "mathcircumflex", "_",
101         "mathrm T",
102         "mathbb N", "mathbb Z", "mathbb Q",
103         "mathbb R", "mathbb C", "mathbb H",
104         "mathcal F", "mathcal L",
105         "mathcal H", "mathcal O", ""
106 };
107
108 int const nr_latex_misc = sizeof(latex_misc) / sizeof(char const *);
109
110 char const * latex_varsz[] = {
111         "sum", "int", "oint",
112         "prod", "coprod", "bigsqcup",
113         "bigotimes", "bigodot", "bigoplus",
114         "bigcap", "bigcup", "biguplus",
115         "bigvee", "bigwedge", ""
116 };
117
118 int const nr_latex_varsz = sizeof(latex_varsz) / sizeof(char const *);
119
120 char const * latex_ams_misc[] = {
121         "digamma", "varkappa", "beth", "daleth", "gimel",
122         "ulcorner", "urcorner", "llcorner", "lrcorner",
123         "hbar", "hslash", "vartriangle",
124         "triangledown", "square", "lozenge",
125         "circledS", "angle", "measuredangle",
126         "nexists", "mho", "Finv",
127         "Game", "Bbbk", "backprime",
128         "varnothing", "blacktriangle", "blacktriangledown",
129         "blacksquare", "blacklozenge", "bigstar",
130         "sphericalangle", "complement", "eth",
131         "diagup", "diagdown", ""
132 };
133
134 int const nr_latex_ams_misc = sizeof(latex_ams_misc) / sizeof(char const *);
135
136 char const * latex_ams_arrows[] = {
137         "dashrightarrow", "dashleftarrow", "leftleftarrows",
138         "leftrightarrows", "Lleftarrow", "twoheadleftarrow",
139         "leftarrowtail", "looparrowleft", "leftrightharpoons",
140         "curvearrowleft", "circlearrowleft", "Lsh",
141         "upuparrows", "upharpoonleft", "downharpoonleft",
142         "multimap", "leftrightsquigarrow", "rightrightarrows",
143         "rightleftarrows", "rightrightarrows", "rightleftarrows",
144         "twoheadrightarrow", "rightarrowtail", "looparrowright",
145         "rightleftharpoons", "curvearrowright", "circlearrowright",
146         "Rsh", "downdownarrows", "upharpoonright",
147         "downharpoonright", "rightsquigarrow",
148         "nleftarrow", "nrightarrow", "nLeftarrow",
149         "nRightarrow", "nleftrightarrow", "nLeftrightarrow", ""
150 };
151
152 int const nr_latex_ams_arrows = sizeof(latex_ams_arrows) / sizeof(char const *);
153
154 char const * latex_ams_rel[] = {
155         "leqq", "leqslant", "eqslantless", "eqslantgtr", "gtrsim", "gtrapprox",
156         "lesssim", "lessapprox", "approxeq", "gtrdot", "ggg", "gtrless",
157         "lessdot", "lll", "lessgtr", "gtreqless", "gtreqqless", "eqcirc",
158         "lesseqgtr", "lesseqqgtr", "doteqdot", "circeq", "triangleq", "thicksim",
159         "risingdotseq", "fallingdotseq", "backsim", "thickapprox", "supseteqq", "Supset",
160         "backsimeq", "subseteqq", "Subset","sqsupset", "succcurlyeq", "curlyeqsucc",
161         "sqsubset", "preccurlyeq", "curlyeqprec", "succsim", "succapprox", "vartriangleright",
162         "precsim", "precapprox", "vartriangleleft", "trianglerighteq", "Vdash", "shortmid",
163         "trianglelefteq", "vDash", "Vvdash", "shortparallel", "between", "pitchfork",
164         "smallsmile", "smallfrown", "bumpeq", "varpropto", "blacktriangleleft", "therefore",
165         "Bumpeq", "geqq", "geqslant", "backepsilon", "blacktriangleright", "because", ""
166 };
167
168 int const nr_latex_ams_rel = sizeof(latex_ams_rel) / sizeof(char const *);
169
170 char const * latex_ams_nrel[] = {
171         "nless", "nleq", "nleqslant", "ngeqslant", "ngeqq", "gneq",
172         "nleqq", "lneq", "lneqq","gneqq", "gvertneqq", "gnsim",
173         "lvertneqq", "lnsim", "lnapprox", "gnapprox", "nsucc", "nsucceq",
174         "nprec", "npreceq", "precnsim","succnsim", "succnapprox", "ncong",
175         "precnapprox", "nsim", "nshortmid", "nshortparallel", "nparallel", "nvDash",
176
177         "nmid", "nvdash", "nvDash","nVDash", "ntriangleright", "ntrianglerighteq",
178         "ntriangleleft", "ntrianglelefteq", "nsubseteq", "nsupseteq", "nsupseteqq", "supsetneq",
179         "subsetneq", "varsubsetneq", "subsetneqq", "varsupsetneq", "supsetneqq", "varsupsetneqq",
180         "varsubsetneqq", "ngtr", "ngeq","", "", ""
181 };
182
183 int const nr_latex_ams_nrel = sizeof(latex_ams_nrel) / sizeof(char const *);
184
185
186 char const * latex_ams_ops[] = {
187         "dotplus", "smallsetminus", "Cap",
188         "Cup", "barwedge", "veebar",
189         "doublebarwedge", "boxminus", "boxtimes",
190         "boxdot", "boxplus", "divideontimes",
191         "ltimes", "rtimes", "leftthreetimes",
192         "rightthreetimes", "curlywedge", "curlyvee",
193         "circleddash", "circledast", "circledcirc",
194         "centerdot", "intercal", ""
195 };
196
197 int const nr_latex_ams_ops = sizeof(latex_ams_ops) / sizeof(char const *);