From 872de8b1de15c2b9f0e5f16f2456be615cd014d5 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Andr=C3=A9=20P=C3=B6nitz?= Date: Thu, 13 Mar 2003 11:42:12 +0000 Subject: [PATCH] read them back... git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@6484 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/factory.C | 3 +++ src/insets/insetenv.C | 4 +++- src/insets/insetminipage.h | 4 ++-- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/src/factory.C b/src/factory.C index 6fbcb377b7..3c2a1d52d9 100644 --- a/src/factory.C +++ b/src/factory.C @@ -331,6 +331,9 @@ Inset * readInset(LyXLex & lex, Buffer const & buf) } else if (tmptok == "Include") { InsetCommandParams p("Include"); inset = new InsetInclude(p, buf); + } else if (tmptok == "Environment") { + lex.next(); + inset = new InsetEnvironment(buf.params, lex.getString()); } else if (tmptok == "ERT") { inset = new InsetERT(buf.params); } else if (tmptok == "Tabular") { diff --git a/src/insets/insetenv.C b/src/insets/insetenv.C index b17fe08c2e..a81cc7d4da 100644 --- a/src/insets/insetenv.C +++ b/src/insets/insetenv.C @@ -35,6 +35,8 @@ InsetEnvironment::InsetEnvironment //LyXLayout_ptr const & layout = tc.getEnv(name); //header_ = layout->latexheader; //footer_ = layout->latexfooter; + header_ = "\\begin{" + name + "}"; + footer_ = "\\end{" + name + "}"; } @@ -51,7 +53,7 @@ Inset * InsetEnvironment::clone(Buffer const &, bool same_id) const void InsetEnvironment::write(Buffer const * buf, ostream & os) const { - os << "Environment " << getInsetName() << "\"\n"; + os << "Environment " << getInsetName() << "\n"; InsetCollapsable::write(buf, os); } diff --git a/src/insets/insetminipage.h b/src/insets/insetminipage.h index d4f544a4d5..18237157ec 100644 --- a/src/insets/insetminipage.h +++ b/src/insets/insetminipage.h @@ -10,8 +10,8 @@ * Full author contact details are available in file CREDITS */ -#ifndef InsetMinipage_H -#define InsetMinipage_H +#ifndef INSETMINIPAGE_H +#define INSETMINIPAGE_H #include "insetcollapsable.h" -- 2.39.5