1 #include "math_splitinset.h"
2 #include "math_mathmlstream.h"
3 #include "math_streamstr.h"
8 MathSplitInset::MathSplitInset(string const & name)
9 : MathGridInset(1, 1), name_(name)
15 auto_ptr<InsetBase> MathSplitInset::clone() const
17 return auto_ptr<InsetBase>(new MathSplitInset(*this));
21 char MathSplitInset::defaultColAlign(col_type col)
25 if (name_ == "gathered")
27 if (name_ == "aligned")
28 return (col & 1) ? 'l' : 'r';
33 void MathSplitInset::write(WriteStream & ws) const
37 ws << "\\begin{" << name_ << '}';
38 MathGridInset::write(ws);
41 ws << "\\end{" << name_ << "}\n";