]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/math_unknowninset.C
revert Buffer LyxText->InsetText commit
[lyx.git] / src / mathed / math_unknowninset.C
index 2e9f6bde2e0fbe57d28935938f6de9aaf783f411..dd1284027fecb92811963f7bf72b9bec715c5470 100644 (file)
@@ -16,6 +16,7 @@
 #include "math_mathmlstream.h"
 #include "math_streamstr.h"
 
+using std::string;
 using std::auto_ptr;
 
 
@@ -42,13 +43,6 @@ void MathUnknownInset::setName(string const & name)
 }
 
 
-bool MathUnknownInset::match(MathAtom const & at) const
-{
-       MathUnknownInset const * q = at->asUnknownInset();
-       return q && name_ == q->name_;
-}
-
-
 void MathUnknownInset::normalize(NormalStream & os) const
 {
        os << "[unknown " << name_ << ']';
@@ -58,6 +52,7 @@ void MathUnknownInset::normalize(NormalStream & os) const
 void MathUnknownInset::metrics(MetricsInfo & mi, Dimension & dim) const
 {
        mathed_string_dim(mi.base.font, name_, dim);
+       dim_ = dim;
 }
 
 
@@ -67,6 +62,8 @@ void MathUnknownInset::draw(PainterInfo & pi, int x, int y) const
                drawStrBlack(pi, x, y, name_);
        else
                drawStrRed(pi, x, y, name_);
+       xo_ = x;
+       yo_ = y;
 }