7 #include "math_kerninset.h"
8 #include "math_mathmlstream.h"
9 #include "math_streamstr.h"
10 #include "math_support.h"
13 MathKernInset::MathKernInset()
17 MathKernInset::MathKernInset(LyXLength const & w)
22 MathKernInset::MathKernInset(string const & s)
27 MathInset * MathKernInset::clone() const
29 return new MathKernInset(*this);
33 void MathKernInset::draw(Painter &, int, int) const
37 void MathKernInset::metrics(MathMetricsInfo const &) const
42 #warning fix this once the interface to LyXLength has improved
44 // this uses the numerical valu in pixels, even if the unit is cm or ex!
45 width_ = static_cast<int>(wid_.value());
46 width_ = (width_*static_cast<int>(lyxrc.zoom))/150;
47 //cerr << "handling kern of width " << wid_.value() << "\n";
51 void MathKernInset::write(WriteStream & os) const
53 os << "\\kern" << wid_.asLatexString() << " ";
57 void MathKernInset::normalize(NormalStream & os) const
59 os << "[kern " << wid_.asLatexString() << "]";