]> git.lyx.org Git - lyx.git/blob - src/mathed/math_macrotemplate.h
try to fix rounding errors
[lyx.git] / src / mathed / math_macrotemplate.h
1 // -*- C++ -*-
2 #ifndef MATH_MACROTEMPLATE_H
3 #define MATH_MACROTEMPLATE_H
4
5 #include "math_nestinset.h"
6 #include "LString.h"
7
8 #ifdef __GNUG__
9 #pragma interface
10 #endif
11
12 class MathMacro;
13
14 /** This class contains the macro definition
15     \author Alejandro Aguilar Sierra
16  */
17 //class MathMacroTemplate : public MathInset, boost::noncopyable
18
19 class MathMacroTemplate : public MathNestInset {
20 public:
21         ///
22         MathMacroTemplate();
23         ///
24         MathMacroTemplate(string const & name, int nargs);
25         ///
26         MathInset * clone() const;
27         ///
28         void write(WriteStream & os) const;
29         /// Number of arguments
30         int numargs() const;
31         ///
32         void numargs(int);
33         ///
34         string const & name() const;
35         ///
36         void draw(MathPainterInfo &, int x, int y) const;
37         ///
38         void metrics(MathMetricsInfo & st) const;
39         /// identifies macro templates
40         MathMacroTemplate * asMacroTemplate() { return this; }
41 private:
42         ///
43         int numargs_;
44         ///
45         string name_;
46 };
47
48 #endif