]> git.lyx.org Git - lyx.git/blob - src/mathed/math_spaceinset.h
Ensure all #warning statements are wrapped by #ifdef WITH_WARNINGS.
[lyx.git] / src / mathed / math_spaceinset.h
1 // -*- C++ -*-
2 /**
3  * \file math_spaceinset.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  *
9  * Full author contact details are available in file CREDITS.
10  */
11
12 #ifndef MATH_SPACEINSET_H
13 #define MATH_SPACEINSET_H
14
15 #include "math_inset.h"
16
17
18 /// Smart spaces
19 class MathSpaceInset : public MathInset {
20 public:
21         ///
22         explicit MathSpaceInset(int sp);
23         ///
24         explicit MathSpaceInset(std::string const & name);
25         ///
26         virtual std::auto_ptr<InsetBase> clone() const;
27         ///
28         MathSpaceInset const * asSpaceInset() const { return this; }
29         ///
30         MathSpaceInset * asSpaceInset() { return this; }
31         ///
32         void incSpace();
33         ///
34         int ascent() const;
35         ///
36         int descent() const;
37         ///
38         int width() const;
39         ///
40         void metrics(MetricsInfo & mi, Dimension & dim) const;
41         ///
42         void draw(PainterInfo & pi, int x, int y) const;
43
44         ///
45         void normalize(NormalStream &) const;
46         ///
47         void validate(LaTeXFeatures & features) const;
48         ///
49         void maple(MapleStream &) const;
50         ///
51         void mathematica(MathematicaStream &) const;
52         ///
53         void octave(OctaveStream &) const;
54         ///
55         void write(WriteStream & os) const;
56 private:
57         ///
58         int space_;
59 };
60 #endif