]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/math_numberinset.C
Get rid of lyxstring, remove usage of STRCONV.
[lyx.git] / src / mathed / math_numberinset.C
index 22eb9a181215e78718899d89a7108eceac3525c6..d93cdbc3197afcc96366729db8a597d94eb7b049 100644 (file)
@@ -1,14 +1,21 @@
-#include <config.h>
+/**
+ * \file math_numberinset.C
+ * This file is part of LyX, the document processor.
+ * Licence details can be found in the file COPYING.
+ *
+ * \author André Pönitz
+ *
+ * Full author contact details are available in file CREDITS.
+ */
 
-#ifdef __GNUG__
-#pragma implementation
-#endif
+#include <config.h>
 
 #include "math_numberinset.h"
 #include "math_mathmlstream.h"
 #include "math_streamstr.h"
 #include "math_support.h"
-#include "debug.h"
+
+using std::auto_ptr;
 
 
 MathNumberInset::MathNumberInset(string const & s)
@@ -16,19 +23,19 @@ MathNumberInset::MathNumberInset(string const & s)
 {}
 
 
-MathInset * MathNumberInset::clone() const
+auto_ptr<InsetBase> MathNumberInset::clone() const
 {
-       return new MathNumberInset(*this);
+       return auto_ptr<InsetBase>(new MathNumberInset(*this));
 }
 
 
-void MathNumberInset::metrics(MathMetricsInfo & mi) const
+void MathNumberInset::metrics(MetricsInfo & mi, Dimension & dim) const
 {
-       mathed_string_dim(mi.base.font, str_, dim_);
+       mathed_string_dim(mi.base.font, str_, dim);
 }
 
 
-void MathNumberInset::draw(MathPainterInfo & pi, int x, int y) const
+void MathNumberInset::draw(PainterInfo & pi, int x, int y) const
 {
        //lyxerr << "drawing '" << str_ << "' code: " << code_ << endl;
        drawStr(pi, pi.base.font, x, y, str_);
@@ -37,17 +44,17 @@ void MathNumberInset::draw(MathPainterInfo & pi, int x, int y) const
 
 void MathNumberInset::normalize(NormalStream & os) const
 {
-       os << "[number " << str_ << "]";
+       os << "[number " << str_ << ']';
 }
 
 
-void MathNumberInset::maplize(MapleStream & os) const
+void MathNumberInset::maple(MapleStream & os) const
 {
        os << str_;
 }
 
 
-void MathNumberInset::octavize(OctaveStream & os) const
+void MathNumberInset::octave(OctaveStream & os) const
 {
        os << str_;
 }