3 * \file InsetMathChar.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_CHARINSET_H
13 #define MATH_CHARINSET_H
15 #include "InsetMath.h"
19 /// The base character inset.
20 class InsetMathChar : public InsetMath {
23 explicit InsetMathChar(char_type c);
25 void metrics(MetricsInfo & mi, Dimension & dim) const;
27 void draw(PainterInfo & pi, int x, int y) const;
29 void metricsT(TextMetricsInfo const & mi, Dimension & dim) const;
31 void drawT(TextPainter &, int x, int y) const;
33 int kerning(BufferView const * bv) const { return kerning_; }
36 void write(WriteStream & os) const;
38 void normalize(NormalStream & ns) const;
40 void octave(OctaveStream & os) const;
42 void mathmlize(MathStream & ms) const;
43 /// identifies Charinsets
44 InsetMathChar const * asCharInset() const { return this; }
46 char_type getChar() const { return char_; }
51 virtual Inset * clone() const;
54 /// cached kerning for superscript