using namespace lyx::support;
using std::ostream;
+using std::auto_ptr;
extern MathCursor * mathcursor;
}
-InsetFormulaMacro::InsetFormulaMacro(string const & name, int nargs)
+InsetFormulaMacro::InsetFormulaMacro
+ (string const & name, int nargs, string const & type)
{
setInsetName(name);
- MathMacroTable::create(MathAtom(new MathMacroTemplate(name, nargs)));
+ MathMacroTable::create(MathAtom(new MathMacroTemplate(name, nargs, type)));
}
}
-Inset * InsetFormulaMacro::clone() const
+auto_ptr<InsetBase> InsetFormulaMacro::clone() const
{
- return new InsetFormulaMacro(*this);
+ return auto_ptr<InsetBase>(new InsetFormulaMacro(*this));
}
}
-Inset::Code InsetFormulaMacro::lyxCode() const
+InsetOld::Code InsetFormulaMacro::lyxCode() const
{
- return Inset::MATHMACRO_CODE;
+ return InsetOld::MATHMACRO_CODE;
}