]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/math_xarrowinset.C
split LyXText::rowlist_ into individual Paragraph::rows_ chunks
[lyx.git] / src / mathed / math_xarrowinset.C
index 8bbf0497e20c4eae435ff7450bd611f9e5320726..df92ac6159a74d5582a7080e6c65967a59350369 100644 (file)
@@ -6,19 +6,21 @@
 #include "math_mathmlstream.h"
 #include "math_streamstr.h"
 
+using std::auto_ptr;
+
 
 MathXArrowInset::MathXArrowInset(string const & name)
        : MathFracbaseInset(), name_(name)
 {}
 
 
-MathInset * MathXArrowInset::clone() const
+auto_ptr<InsetBase> MathXArrowInset::clone() const
 {
-       return new MathXArrowInset(*this);
+       return auto_ptr<InsetBase>(new MathXArrowInset(*this));
 }
 
 
-Dimension MathXArrowInset::metrics(MetricsInfo & mi) const
+void MathXArrowInset::metrics(MetricsInfo & mi, Dimension & dim) const
 {
        ScriptChanger dummy(mi.base);
        cell(0).metrics(mi);
@@ -26,7 +28,7 @@ Dimension MathXArrowInset::metrics(MetricsInfo & mi) const
        dim_.wid = std::max(cell(0).width(), cell(1).width()) + 10;
        dim_.asc = cell(0).height() + 10;
        dim_.des = cell(1).height();
-       return dim_;
+       dim = dim_;
 }