]> git.lyx.org Git - lyx.git/blob - src/mathed/InsetMathEnsureMath.h
Coding style
[lyx.git] / src / mathed / InsetMathEnsureMath.h
1 // -*- C++ -*-
2 /**
3  * \file InsetMathEnsureMath.h
4  * This file is part of LyX, the document processor.
5  * Licence details can be found in the file COPYING.
6  *
7  * \author André Pönitz
8  * \author Enrico Forestieri
9  *
10  * Full author contact details are available in file CREDITS.
11  */
12
13 #ifndef MATH_ENSUREMATHINSET_H
14 #define MATH_ENSUREMATHINSET_H
15
16 #include "InsetMathNest.h"
17
18
19 namespace lyx {
20
21
22 /// Inset for ensuring math mode
23 class InsetMathEnsureMath : public InsetMathNest {
24 public:
25         InsetMathEnsureMath();
26         ///
27         mode_type currentMode() const { return MATH_MODE; }
28         ///
29         void metrics(MetricsInfo & mi, Dimension & dim) const;
30         ///
31         void draw(PainterInfo & pi, int x, int y) const;
32         ///
33         void metricsT(TextMetricsInfo const & mi, Dimension & dim) const;
34         ///
35         void drawT(TextPainter & pi, int x, int y) const;
36         ///
37         void write(WriteStream & os) const;
38         ///
39         void infoize(odocstream & os) const;
40 private:
41         virtual Inset * clone() const;
42 };
43
44
45 } // namespace lyx
46
47 #endif