2 * \file InsetMathKern.C
3 * This file is part of LyX, the document processor.
4 * Licence details can be found in the file COPYING.
8 * Full author contact details are available in file CREDITS.
13 #include "InsetMathKern.h"
14 #include "MathMLStream.h"
15 #include "MathStream.h"
16 #include "MathSupport.h"
17 #include "dimension.h"
23 InsetMathKern::InsetMathKern()
27 InsetMathKern::InsetMathKern(LyXLength const & w)
32 InsetMathKern::InsetMathKern(string const & s)
37 auto_ptr<InsetBase> InsetMathKern::doClone() const
39 return auto_ptr<InsetBase>(new InsetMathKern(*this));
43 void InsetMathKern::metrics(MetricsInfo & mi, Dimension & dim) const
45 wid_pix_ = wid_.inPixels(0, mathed_char_width(mi.base.font, 'M'));
52 int InsetMathKern::width() const
58 void InsetMathKern::draw(PainterInfo &, int, int) const
62 void InsetMathKern::write(WriteStream & os) const
64 os << "\\kern" << wid_.asLatexString() << ' ';
68 void InsetMathKern::normalize(NormalStream & os) const
70 os << "[kern " << wid_.asLatexString() << ']';