]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/InsetMathXYMatrix.cpp
InsetMathHull.cpp: whitespace
[lyx.git] / src / mathed / InsetMathXYMatrix.cpp
index 9be4e2efa6c67e3ad63bb8ec2f6976e3c6972632..79a5a76551049673f4284ee85ca50e173b1a98d6 100644 (file)
@@ -53,13 +53,7 @@ void InsetMathXYMatrix::metrics(MetricsInfo & mi, Dimension & dim) const
 
 void InsetMathXYMatrix::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 << "\\xymatrix";
        switch (spacing_code_) {
        case 'R':
@@ -78,7 +72,6 @@ void InsetMathXYMatrix::write(WriteStream & os) const
        os << '{';
        InsetMathGrid::write(os);
        os << "}\n";
-       os.pendingBrace(brace);
 }