]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/InsetMathSubstack.cpp
fix off-by-two drawing error
[lyx.git] / src / mathed / InsetMathSubstack.cpp
index e5abe9818afac96b6c66e86fc91b05badf8730ac..059e02955149ba69177645ecc1977db4881da83a 100644 (file)
@@ -89,17 +89,10 @@ void InsetMathSubstack::infoize(odocstream & os) const
 
 void InsetMathSubstack::write(WriteStream & os) const
 {
-       bool brace = os.pendingBrace();
-       os.pendingBrace(false);
-       if (os.latex() && os.textMode()) {
-               os << "\\ensuremath{";
-               os.textMode(false);
-               brace = true;
-       }
+       MathEnsurer ensurer(os);
        os << "\\substack{";
        InsetMathGrid::write(os);
        os << "}\n";
-       os.pendingBrace(brace);
 }