]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/InsetMathMBox.cpp
* src/frontends/GuiDocument.{cpp,h}:
[lyx.git] / src / mathed / InsetMathMBox.cpp
index e212d2f4fbc518f60c9978f779ce88a922aae36a..65c398b58e28b988e355283554987a3fd5d4f04b 100644 (file)
@@ -18,7 +18,7 @@
 #include "Buffer.h"
 #include "BufferParams.h"
 #include "Cursor.h"
-#include "debug.h"
+#include "support/debug.h"
 #include "MetricsInfo.h"
 #include "output_latex.h"
 #include "OutputParams.h"
 #include "TexRow.h"
 #include "TextMetrics.h"
 
+using namespace std;
 
 namespace lyx {
 
-using std::endl;
-
 
 InsetMathMBox::InsetMathMBox()
 {
@@ -53,15 +52,11 @@ Inset * InsetMathMBox::clone() const
 }
 
 
-bool InsetMathMBox::metrics(MetricsInfo & mi, Dimension & dim) const
+void InsetMathMBox::metrics(MetricsInfo & mi, Dimension & dim) const
 {
        TextMetrics & tm = mi.base.bv->textMetrics(&text_);
        tm.metrics(mi, dim);
        metricsMarkers2(dim);
-       if (dim_ == dim)
-               return false;
-       dim_ = dim;
-       return true;
 }
 
 
@@ -83,7 +78,7 @@ void InsetMathMBox::write(Buffer const & buf, WriteStream & ws) const
                ws << "}";
        } else {
                ws << "\\mbox{\n";
-               std::ostringstream os;
+               ostringstream os;
                text_.write(buf, os);
                ws.os() << from_utf8(os.str());
                ws << "}";
@@ -122,10 +117,4 @@ void InsetMathMBox::cursorPos(BufferView const & bv,
 }
 
 
-void InsetMathMBox::drawSelection(PainterInfo & pi, int x, int y) const
-{
-       pi.base.bv->textMetrics(&text_).drawSelection(pi, x, y);
-}
-
-
 } // namespace lyx