From: André Pönitz Date: Mon, 8 Jul 2002 13:35:26 +0000 (+0000) Subject: move code from nestinset X-Git-Tag: 1.6.10~18950 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=f68213134ccaaf8f76f60d3e9990db72b8025868;p=features.git move code from nestinset git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@4551 a592a061-630c-0410-9148-cb99ea01b6c8 --- diff --git a/src/mathed/math_parinset.C b/src/mathed/math_parinset.C new file mode 100644 index 0000000000..28af5f9ccb --- /dev/null +++ b/src/mathed/math_parinset.C @@ -0,0 +1,38 @@ + +#include "math_parinset.h" +#include "math_mathmlstream.h" +#include "debug.h" + + +MathParInset::MathParInset() +{ + lyxerr << "constructing MathParInset\n"; +} + + +void MathParInset::metrics(MathMetricsInfo & mi) const +{ + MathFontSetChanger dummy1(mi.base, "textnormal"); + MathGridInset::metrics(mi); +} + + +void MathParInset::draw(MathPainterInfo & pi, int x, int y) const +{ + MathFontSetChanger dummy1(pi.base, "textnormal"); + MathGridInset::draw(pi, x, y); +} + + +void MathParInset::write(WriteStream & os) const +{ + for (idx_type i = 0; i < nargs(); ++i) + os << cell(i) << "\n"; +} + + +void MathParInset::infoize(std::ostream & os) const +{ + os << "Type: Paragraph "; +} + diff --git a/src/mathed/math_parinset.h b/src/mathed/math_parinset.h new file mode 100644 index 0000000000..17b6e0bd06 --- /dev/null +++ b/src/mathed/math_parinset.h @@ -0,0 +1,22 @@ +#ifndef MATH_PARINSET_H +#define MATH_PARINSET_H + +#include "math_hullinset.h" + +class MathParInset : public MathHullInset { +public: + /// + MathParInset(); + /// + MathParInset * asParInset() { return this; } + /// + void metrics(MathMetricsInfo & mi) const; + /// + void draw(MathPainterInfo &, int x, int y) const; + /// + void infoize(std::ostream & os) const; + /// + void write(WriteStream & os) const; +}; + +#endif