3 * \file InsetMathSpace.h
4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
9 * Full author contact details are available in file CREDITS.
12 #ifndef MATH_SPACEINSET_H
13 #define MATH_SPACEINSET_H
15 #include "InsetMath.h"
17 #include "support/Length.h"
22 struct InsetSpaceParams;
25 class InsetMathSpace : public InsetMath {
28 explicit InsetMathSpace();
30 explicit InsetMathSpace(std::string const & name, std::string const & length);
32 explicit InsetMathSpace(Length const & length, bool const prot = false);
34 InsetMathSpace const * asSpaceInset() const { return this; }
36 InsetMathSpace * asSpaceInset() { return this; }
40 void metrics(MetricsInfo & mi, Dimension & dim) const;
42 void draw(PainterInfo & pi, int x, int y) const;
45 void normalize(NormalStream &) const;
47 void validate(LaTeXFeatures & features) const;
49 void maple(MapleStream &) const;
51 void mathematica(MathematicaStream &) const;
53 void octave(OctaveStream &) const;
55 void mathmlize(MathStream & ms) const;
57 void htmlize(HtmlStream & ms) const;
59 void write(WriteStream & os) const;
60 /// generate something that will be understood by the Dialogs.
61 InsetSpaceParams params() const;
63 bool hasSettings() const { return true; }
65 std::string contextMenuName() const;
67 bool getStatus(Cursor &, FuncRequest const &, FuncStatus &) const;
69 InsetCode lyxCode() const { return MATH_SPACE_CODE; }
73 virtual void doDispatch(Cursor & cur, FuncRequest & cmd);
75 virtual Inset * clone() const;
77 bool isNegative() const;
80 /// amount of space for \\hspace