4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
7 * \author Angus Leeming
9 * Full author contact details are available in file CREDITS.
11 * ControlMath2 is a controller class for the Math Panel dialog.
19 #include "lfuns.h" // for kb_action
24 class ControlMath : public Dialog::Controller {
26 ControlMath(Dialog &);
28 /// Nothing to initialise in this case.
29 virtual bool initialiseParams(std::string const &) { return true; }
30 virtual void clearParams() {}
31 virtual void dispatchParams() {}
32 virtual bool isBufferDependent() const { return true; }
35 void dispatchFunc(kb_action action, std::string const & arg = std::string()) const;
36 /// Insert a math symbol into the doc.
37 void dispatchInsert(std::string const & name) const;
38 /// Insert a subscript.
39 void dispatchSubscript() const;
40 /// Insert a superscript.
41 void dispatchSuperscript() const;
42 /// Insert a cube root
43 void dispatchCubeRoot() const;
45 void dispatchMatrix(std::string const & str) const;
46 /// Insert a variable size delimiter
47 void dispatchDelim(std::string const & str) const;
48 /// Insert a big delimiter
49 void dispatchBigDelim(std::string const & str) const;
50 /// Switch between display and inline
51 void dispatchToggleDisplay() const;
52 /** A request to the kernel to launch a dialog.
53 * \param name the dialog identifier.
55 void showDialog(std::string const & name) const;
59 extern char const * function_names[];
60 extern int const nr_function_names;
61 extern char const * latex_arrow[];
62 extern int const nr_latex_arrow;
63 extern char const * latex_bop[];
64 extern int const nr_latex_bop;
65 extern char const * latex_brel[];
66 extern int const nr_latex_brel;
67 extern char const * latex_dots[];
68 extern int const nr_latex_dots;
69 extern char const * latex_greek[];
70 extern int const nr_latex_greek;
71 extern char const * latex_deco[];
72 extern int const nr_latex_deco;
73 extern char const * latex_misc[];
74 extern int const nr_latex_misc;
75 extern char const * latex_varsz[];
76 extern int const nr_latex_varsz;
77 extern char const * latex_ams_misc[];
78 extern int const nr_latex_ams_misc;
79 extern char const * latex_ams_arrows[];
80 extern int const nr_latex_ams_arrows;
81 extern char const * latex_ams_rel[];
82 extern int const nr_latex_ams_rel;
83 extern char const * latex_ams_nrel[];
84 extern int const nr_latex_ams_nrel;
85 extern char const * latex_ams_ops[];
86 extern int const nr_latex_ams_ops;
89 * Return the mangled XPM filename of the given
92 std::string const find_xpm(std::string const & name);
94 } // namespace frontend
97 #endif // NOT CONTROLMATH