]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/InsetMathEnv.cpp
listerrors.lyx : Update a link.
[lyx.git] / src / mathed / InsetMathEnv.cpp
index adbca074e8245648894925f27765ef57c58e4e4e..a7fb33c69d408ac0e7aa704b879dd3d19698f5dd 100644 (file)
@@ -3,7 +3,7 @@
  * This file is part of LyX, the document processor.
  * Licence details can be found in the file COPYING.
  *
- * \author André Pönitz
+ * \author André Pönitz
  *
  * Full author contact details are available in file CREDITS.
  */
@@ -21,8 +21,8 @@
 
 namespace lyx {
 
-InsetMathEnv::InsetMathEnv(docstring const & name)
-       : InsetMathNest(1), name_(name)
+InsetMathEnv::InsetMathEnv(Buffer * buf, docstring const & name)
+       : InsetMathNest(buf, 1), name_(name)
 {}
 
 
@@ -36,8 +36,6 @@ void InsetMathEnv::metrics(MetricsInfo & mi, Dimension & dim) const
 {
        cell(0).metrics(mi, dim);
        metricsMarkers(dim);
-       // Cache the inset dimension. 
-       setDimCache(mi, dim);
 }
 
 
@@ -50,6 +48,7 @@ void InsetMathEnv::draw(PainterInfo & pi, int x, int y) const
 
 void InsetMathEnv::write(WriteStream & os) const
 {
+       MathEnsurer ensurer(os);
        os << "\\begin{" << name_ << '}' << cell(0) << "\\end{" << name_ << '}';
 }