2 * \file math_unknowninset.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 "math_unknowninset.h"
14 #include "math_support.h"
15 #include "math_atom.h"
16 #include "math_mathmlstream.h"
17 #include "math_streamstr.h"
23 MathUnknownInset::MathUnknownInset(string const & nm, bool final, bool black)
24 : name_(nm), final_(final), black_(black)
28 auto_ptr<InsetBase> MathUnknownInset::doClone() const
30 return auto_ptr<InsetBase>(new MathUnknownInset(*this));
34 string MathUnknownInset::name() const
40 void MathUnknownInset::setName(string const & name)
46 void MathUnknownInset::normalize(NormalStream & os) const
48 os << "[unknown " << name_ << ']';
52 void MathUnknownInset::metrics(MetricsInfo & mi, Dimension & dim) const
54 mathed_string_dim(mi.base.font, name_, dim);
59 void MathUnknownInset::draw(PainterInfo & pi, int x, int y) const
62 drawStrBlack(pi, x, y, name_);
64 drawStrRed(pi, x, y, name_);
65 setPosCache(pi, x, y);
69 void MathUnknownInset::finalize()
75 bool MathUnknownInset::final() const
81 void MathUnknownInset::maple(MapleStream & os) const
87 void MathUnknownInset::mathematica(MathematicaStream & os) const
93 void MathUnknownInset::mathmlize(MathMLStream & os) const
95 os << MTag("mi") << name_ << ETag("mi");
99 void MathUnknownInset::octave(OctaveStream & os) const