]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/math_unknowninset.C
split LyXText::rowlist_ into individual Paragraph::rows_ chunks
[lyx.git] / src / mathed / math_unknowninset.C
index 6d5e446a13719f8e80fb6a7a44f01a711285a940..6a126c1c28ecc24e984f9b65dcb7f5d6a94750e6 100644 (file)
@@ -2,18 +2,21 @@
 
 #include "math_unknowninset.h"
 #include "math_support.h"
+#include "math_atom.h"
 #include "math_mathmlstream.h"
 #include "math_streamstr.h"
 
+using std::auto_ptr;
+
 
 MathUnknownInset::MathUnknownInset(string const & nm, bool final, bool black)
        : name_(nm), final_(final), black_(black)
 {}
 
 
-MathInset * MathUnknownInset::clone() const
+auto_ptr<InsetBase> MathUnknownInset::clone() const
 {
-       return new MathUnknownInset(*this);
+       return auto_ptr<InsetBase>(new MathUnknownInset(*this));
 }
 
 
@@ -42,11 +45,9 @@ void MathUnknownInset::normalize(NormalStream & os) const
 }
 
 
-Dimension MathUnknownInset::metrics(MetricsInfo & mi) const
+void MathUnknownInset::metrics(MetricsInfo & mi, Dimension & dim) const
 {
-       Dimension dim;
        mathed_string_dim(mi.base.font, name_, dim);
-       return dim;
 }