mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-11 13:46:43 +00:00
2535ea14bd
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13265 a592a061-630c-0410-9148-cb99ea01b6c8
81 lines
1.3 KiB
C
81 lines
1.3 KiB
C
/**
|
|
* \file math_xymatrixinset.C
|
|
* This file is part of LyX, the document processor.
|
|
* Licence details can be found in the file COPYING.
|
|
*
|
|
* \author André Pönitz
|
|
*
|
|
* Full author contact details are available in file CREDITS.
|
|
*/
|
|
|
|
#include <config.h>
|
|
|
|
#include "math_xymatrixinset.h"
|
|
#include "math_mathmlstream.h"
|
|
#include "math_streamstr.h"
|
|
|
|
#include "LaTeXFeatures.h"
|
|
#include "support/std_ostream.h"
|
|
|
|
|
|
MathXYMatrixInset::MathXYMatrixInset()
|
|
: MathGridInset(1, 1)
|
|
{}
|
|
|
|
|
|
std::auto_ptr<InsetBase> MathXYMatrixInset::doClone() const
|
|
{
|
|
return std::auto_ptr<InsetBase>(new MathXYMatrixInset(*this));
|
|
}
|
|
|
|
|
|
int MathXYMatrixInset::colsep() const
|
|
{
|
|
return 40;
|
|
}
|
|
|
|
|
|
int MathXYMatrixInset::rowsep() const
|
|
{
|
|
return 40;
|
|
}
|
|
|
|
|
|
void MathXYMatrixInset::metrics(MetricsInfo & mi, Dimension & dim) const
|
|
{
|
|
if (mi.base.style == LM_ST_DISPLAY)
|
|
mi.base.style = LM_ST_TEXT;
|
|
MathGridInset::metrics(mi, dim);
|
|
}
|
|
|
|
|
|
void MathXYMatrixInset::write(WriteStream & os) const
|
|
{
|
|
os << "\\xymatrix{";
|
|
MathGridInset::write(os);
|
|
os << "}\n";
|
|
}
|
|
|
|
|
|
void MathXYMatrixInset::infoize(std::ostream & os) const
|
|
{
|
|
os << "xymatrix ";
|
|
MathGridInset::infoize(os);
|
|
}
|
|
|
|
|
|
void MathXYMatrixInset::normalize(NormalStream & os) const
|
|
{
|
|
os << "[xymatrix ";
|
|
MathGridInset::normalize(os);
|
|
os << ']';
|
|
}
|
|
|
|
|
|
void MathXYMatrixInset::maple(MapleStream & os) const
|
|
{
|
|
os << "xymatrix(";
|
|
MathGridInset::maple(os);
|
|
os << ')';
|
|
}
|